depot/nix, branch refs/r/2767 monorepo for the virus lounge http://code.tvl.fyi/depot/atom?h=refs%2Fr%2F2767 2021-08-24T22:00:15+00:00 refactor(nix/buildLisp): prepare multi implementation support 2021-08-24T22:00:15+00:00 sterni sternenseemann@systemli.org 2021-08-07T22:36:21+00:00 urn:sha1:d344637fe29d039f1046b6ebbbc4b649d61bf0b7 Concept is roughly: * receive extra argument `implementation` that refers to the name of an implementation or rather an attribute in an internal attribute set telling buildLisp how to do certain build steps. * We assume an implementation can execute lisp files as scripts and that we can implement the following main tasks in lisp: - Building a library (`genCompileLisp`) - Building an executable (`genDumpLisp`) - Loading a library dynamically (`genLoadLisp`) Based on that we can implement: - Running a test suite (`genTestLisp`) - A REPL preloaded with a libraries and their dependencies (`lispWith`) Additional attributes for implementing these parts genericly are added as needed (`faslExt` and `runScript`). * `genCompileLisp` no longer prints a shell script which concatenates the individual FASLs. Instead it does the step previously done by the shell script itself. In essence `genCompileLisp` now writes a lisp script which compiles and installs the library to build. This will allow us extra freedom for different implementations, e. g. for ECL we'll want to build a object file archive additionally to fasl files in order to be able to link proper executables. * `genLoadLisp` and `genTestLisp` are almost generic (the former just sometimes would need to use different file extensions), but we integrate them into the implementation “API” to facilitate minor tweaks we need to do like the `fasc` extension for ECL's native FASL files. Change-Id: I1b8ccc0063159638ec7af534e9a6b5384e750193 Reviewed-on: https://cl.tvl.fyi/c/depot/+/3292 Tested-by: BuildkiteCI Reviewed-by: tazjin <mail@tazj.in> refactor(users/grfn/gws.fyi): implement isDirectory in pure nix 2021-08-24T12:13:06+00:00 sterni sternenseemann@systemli.org 2021-08-18T09:38:59+00:00 urn:sha1:32de4cbd934894e7be3dcb2c695229f8056f28cf Another day, another import from derivation avoided by builtins.unsafeDiscardStringContext! Change-Id: I67274b1ba13ba980bb3346b22f2955c702aa3151 Reviewed-on: https://cl.tvl.fyi/c/depot/+/3372 Tested-by: BuildkiteCI Reviewed-by: grfn <grfn@gws.fyi> Reviewed-by: tazjin <mail@tazj.in> docs(nix/buildLisp): mention drawback of non-parallel compilation 2021-08-12T15:08:15+00:00 sterni sternenseemann@systemli.org 2021-08-12T14:01:11+00:00 urn:sha1:59195e76fafbf2206f335379455ea61d204f3b21 To be fair this hardly matters since SBCL is quite fast, but compiling ironclad with ECL is quite the experience… Change-Id: Ib89cc50e5d557acec51fdb085bcbdfc99736221e Reviewed-on: https://cl.tvl.fyi/c/depot/+/3342 Tested-by: BuildkiteCI Reviewed-by: tazjin <mail@tazj.in> fix(nix/buildLisp): remove misplaced `makeOverridable`s 2021-08-10T14:31:52+00:00 sterni sternenseemann@systemli.org 2021-08-08T16:02:33+00:00 urn:sha1:0298ec862e4b5af7f23cae58693d6abca534deaf `makeOverriddable` doesn't work for bundled sbclWith as is because it uses the `//` operator internally which doesn't work with the types `bundled` and `sbclWith` accept as arguments (string and list respectively). What's more, `bundled` already uses `makeOverridable` and allows to override the internal call to `library` via `overrideLisp`. For `sbclWith` no such mechanism exists, but this seems to be no concern for now: Using `overrideLisp` for this hasn't worked so far (and failed with a _hideous_ evaluation error), so there doesn't seem to be any real demand for this feature. Maybe a feature for another CL. Change-Id: I0b2f34c00a2143cd66dd43a6b1b2880af997ee50 Reviewed-on: https://cl.tvl.fyi/c/depot/+/3296 Tested-by: BuildkiteCI Reviewed-by: tazjin <mail@tazj.in> refactor(nix/buildLisp): use passthru for extra attributes 2021-08-01T23:37:03+00:00 sterni sternenseemann@systemli.org 2021-07-27T19:48:11+00:00 urn:sha1:c8f521e96a2d2b127ad4e6b6785b25f906c01ddf Using passthru and appending the attributes via `//` have the same effect with a subtle difference: In the latter case re-evaluating the derivation when using the underlying `mkDerivation`'s `overrideAttrs` will delete all appended attributes. Using passthru at least preserves the attributes although the self reference to the derivation in `passthru.sbcl` will become outdated (unless updated manually). Change-Id: I8b85009f386b9375b86a23fd50c4ec8c6a9dea7f Reviewed-on: https://cl.tvl.fyi/c/depot/+/3257 Tested-by: BuildkiteCI Reviewed-by: tazjin <mail@tazj.in> Reviewed-by: grfn <grfn@gws.fyi> fix(nix/writers/rust): remove args override 2021-05-17T23:00:57+00:00 Profpatsch mail@profpatsch.de 2021-04-24T11:32:52+00:00 urn:sha1:72924facaebb9cf37d9cfd1da43335d5fe51fb6e We can be closed world, so let’s restrict the arguments to the subset we need for now. The existing override was wrong, in that `// args` would use the arguments we already added, again. So instead of deliberating about how to make this work right in all cases, we don’t need it, we trim it. Change-Id: I6443a0808b8bfd5e4db939b669c6afc741954db8 Reviewed-on: https://cl.tvl.fyi/c/depot/+/3057 Tested-by: BuildkiteCI Reviewed-by: sterni <sternenseemann@systemli.org> feat(users/Profpatsch/blog): implement blog engine lol 2021-04-30T21:47:42+00:00 Profpatsch mail@profpatsch.de 2021-01-29T14:58:33+00:00 urn:sha1:713f06629757c507607cf5dc88399a84d54f2469 My horrible blog engine v0.0.0.0.1. Don’t judge. Change-Id: I427b4e84d67aa49793cb7625e4d8ca2824f00943 Reviewed-on: https://cl.tvl.fyi/c/depot/+/2456 Tested-by: BuildkiteCI Reviewed-by: Profpatsch <mail@profpatsch.de> chore(nix): move rustSimple from users.Profpatsch.writers 2021-04-24T10:23:55+00:00 Profpatsch mail@profpatsch.de 2021-04-23T20:04:42+00:00 urn:sha1:eb41eef6127216543d8b28c9c423ac1be0a4ee24 I think it’s solid enough to use in a wider context. Change-Id: If53e8bbb6b90fa88d73fb42730db470e822ea182 Reviewed-on: https://cl.tvl.fyi/c/depot/+/3055 Tested-by: BuildkiteCI Reviewed-by: sterni <sternenseemann@systemli.org> Reviewed-by: lukegb <lukegb@tvl.fyi> feat(nix): add basic netstring nix generation functions 2021-04-24T09:54:34+00:00 Profpatsch mail@profpatsch.de 2021-04-23T17:05:59+00:00 urn:sha1:7e888c3c7bb36f6ab6e83d4a6f6a755ff4156791 Moving to toplevel so I can use them with `runExecline`. They should be pretty atomic, and are proven to work (tests are still in my user dir, since they test the producers indirectly via the python parser and I don’t want to pull it out right now). Change-Id: Id0baa3adcb2ec646458a104c7868c2889b8c64f5 Reviewed-on: https://cl.tvl.fyi/c/depot/+/3054 Reviewed-by: Profpatsch <mail@profpatsch.de> Tested-by: BuildkiteCI feat(nix/buildGo): add the import position to errmsg 2021-04-23T16:35:57+00:00 Profpatsch mail@profpatsch.de 2021-04-05T09:41:37+00:00 urn:sha1:2224731e0d007fbff27f31f4e1771aad723b603f When a foreign dep is missing a dependency, it is good to have a context. e.g. the `github.com/charmbracelet/bubblegum` package has a lot of dependencies that are only used in its `examples/` dir; this is not obvious, unless we also print where the imports come from. New error message: ``` error: missing foreign dependency 'github.com/containerd/console' in 'github.com/charmbracelet/bubbletea, imported at /nix/store/0cry4sg6bzxqwk5zl2nxhas6k5663svg-source/tea.go:22:2' ``` Change-Id: If34a3c62b9d77d4aea108b5e011e16fbd03e8554 Reviewed-on: https://cl.tvl.fyi/c/depot/+/2852 Tested-by: BuildkiteCI Reviewed-by: tazjin <mail@tazj.in>
This XML file does not appear to have any style information associated with it. The document tree is shown below.
<feed xmlns="http://www.w3.org/2005/Atom">
<title>depot/nix, branch refs/r/2767</title>
<subtitle>monorepo for the virus lounge</subtitle>
<id>http://code.tvl.fyi/depot/atom?h=refs%2Fr%2F2767</id>
<link rel="self" href="http://code.tvl.fyi/depot/atom?h=refs%2Fr%2F2767"/>
<link rel="alternate" type="text/html" href="http://code.tvl.fyi/"/>
<updated>2021-08-24T22:00:15+00:00</updated>
<entry>
<title>refactor(nix/buildLisp): prepare multi implementation support</title>
<updated>2021-08-24T22:00:15+00:00</updated>
<author>
<name>sterni</name>
<email>sternenseemann@systemli.org</email>
</author>
<published>2021-08-07T22:36:21+00:00</published>
<link rel="alternate" type="text/html" href="http://code.tvl.fyi/commit/?id=d344637fe29d039f1046b6ebbbc4b649d61bf0b7"/>
<id>urn:sha1:d344637fe29d039f1046b6ebbbc4b649d61bf0b7</id>
<content type="text"> Concept is roughly: * receive extra argument `implementation` that refers to the name of an implementation or rather an attribute in an internal attribute set telling buildLisp how to do certain build steps. * We assume an implementation can execute lisp files as scripts and that we can implement the following main tasks in lisp: - Building a library (`genCompileLisp`) - Building an executable (`genDumpLisp`) - Loading a library dynamically (`genLoadLisp`) Based on that we can implement: - Running a test suite (`genTestLisp`) - A REPL preloaded with a libraries and their dependencies (`lispWith`) Additional attributes for implementing these parts genericly are added as needed (`faslExt` and `runScript`). * `genCompileLisp` no longer prints a shell script which concatenates the individual FASLs. Instead it does the step previously done by the shell script itself. In essence `genCompileLisp` now writes a lisp script which compiles and installs the library to build. This will allow us extra freedom for different implementations, e. g. for ECL we'll want to build a object file archive additionally to fasl files in order to be able to link proper executables. * `genLoadLisp` and `genTestLisp` are almost generic (the former just sometimes would need to use different file extensions), but we integrate them into the implementation “API” to facilitate minor tweaks we need to do like the `fasc` extension for ECL's native FASL files. Change-Id: I1b8ccc0063159638ec7af534e9a6b5384e750193 Reviewed-on: https://cl.tvl.fyi/c/depot/+/3292 Tested-by: BuildkiteCI Reviewed-by: tazjin <mail@tazj.in> </content>
</entry>
<entry>
<title>refactor(users/grfn/gws.fyi): implement isDirectory in pure nix</title>
<updated>2021-08-24T12:13:06+00:00</updated>
<author>
<name>sterni</name>
<email>sternenseemann@systemli.org</email>
</author>
<published>2021-08-18T09:38:59+00:00</published>
<link rel="alternate" type="text/html" href="http://code.tvl.fyi/commit/?id=32de4cbd934894e7be3dcb2c695229f8056f28cf"/>
<id>urn:sha1:32de4cbd934894e7be3dcb2c695229f8056f28cf</id>
<content type="text"> Another day, another import from derivation avoided by builtins.unsafeDiscardStringContext! Change-Id: I67274b1ba13ba980bb3346b22f2955c702aa3151 Reviewed-on: https://cl.tvl.fyi/c/depot/+/3372 Tested-by: BuildkiteCI Reviewed-by: grfn <grfn@gws.fyi> Reviewed-by: tazjin <mail@tazj.in> </content>
</entry>
<entry>
<title>docs(nix/buildLisp): mention drawback of non-parallel compilation</title>
<updated>2021-08-12T15:08:15+00:00</updated>
<author>
<name>sterni</name>
<email>sternenseemann@systemli.org</email>
</author>
<published>2021-08-12T14:01:11+00:00</published>
<link rel="alternate" type="text/html" href="http://code.tvl.fyi/commit/?id=59195e76fafbf2206f335379455ea61d204f3b21"/>
<id>urn:sha1:59195e76fafbf2206f335379455ea61d204f3b21</id>
<content type="text"> To be fair this hardly matters since SBCL is quite fast, but compiling ironclad with ECL is quite the experience… Change-Id: Ib89cc50e5d557acec51fdb085bcbdfc99736221e Reviewed-on: https://cl.tvl.fyi/c/depot/+/3342 Tested-by: BuildkiteCI Reviewed-by: tazjin <mail@tazj.in> </content>
</entry>
<entry>
<title>fix(nix/buildLisp): remove misplaced `makeOverridable`s</title>
<updated>2021-08-10T14:31:52+00:00</updated>
<author>
<name>sterni</name>
<email>sternenseemann@systemli.org</email>
</author>
<published>2021-08-08T16:02:33+00:00</published>
<link rel="alternate" type="text/html" href="http://code.tvl.fyi/commit/?id=0298ec862e4b5af7f23cae58693d6abca534deaf"/>
<id>urn:sha1:0298ec862e4b5af7f23cae58693d6abca534deaf</id>
<content type="text"> `makeOverriddable` doesn't work for bundled sbclWith as is because it uses the `//` operator internally which doesn't work with the types `bundled` and `sbclWith` accept as arguments (string and list respectively). What's more, `bundled` already uses `makeOverridable` and allows to override the internal call to `library` via `overrideLisp`. For `sbclWith` no such mechanism exists, but this seems to be no concern for now: Using `overrideLisp` for this hasn't worked so far (and failed with a _hideous_ evaluation error), so there doesn't seem to be any real demand for this feature. Maybe a feature for another CL. Change-Id: I0b2f34c00a2143cd66dd43a6b1b2880af997ee50 Reviewed-on: https://cl.tvl.fyi/c/depot/+/3296 Tested-by: BuildkiteCI Reviewed-by: tazjin <mail@tazj.in> </content>
</entry>
<entry>
<title>refactor(nix/buildLisp): use passthru for extra attributes</title>
<updated>2021-08-01T23:37:03+00:00</updated>
<author>
<name>sterni</name>
<email>sternenseemann@systemli.org</email>
</author>
<published>2021-07-27T19:48:11+00:00</published>
<link rel="alternate" type="text/html" href="http://code.tvl.fyi/commit/?id=c8f521e96a2d2b127ad4e6b6785b25f906c01ddf"/>
<id>urn:sha1:c8f521e96a2d2b127ad4e6b6785b25f906c01ddf</id>
<content type="text"> Using passthru and appending the attributes via `//` have the same effect with a subtle difference: In the latter case re-evaluating the derivation when using the underlying `mkDerivation`'s `overrideAttrs` will delete all appended attributes. Using passthru at least preserves the attributes although the self reference to the derivation in `passthru.sbcl` will become outdated (unless updated manually). Change-Id: I8b85009f386b9375b86a23fd50c4ec8c6a9dea7f Reviewed-on: https://cl.tvl.fyi/c/depot/+/3257 Tested-by: BuildkiteCI Reviewed-by: tazjin <mail@tazj.in> Reviewed-by: grfn <grfn@gws.fyi> </content>
</entry>
<entry>
<title>fix(nix/writers/rust): remove args override</title>
<updated>2021-05-17T23:00:57+00:00</updated>
<author>
<name>Profpatsch</name>
<email>mail@profpatsch.de</email>
</author>
<published>2021-04-24T11:32:52+00:00</published>
<link rel="alternate" type="text/html" href="http://code.tvl.fyi/commit/?id=72924facaebb9cf37d9cfd1da43335d5fe51fb6e"/>
<id>urn:sha1:72924facaebb9cf37d9cfd1da43335d5fe51fb6e</id>
<content type="text"> We can be closed world, so let’s restrict the arguments to the subset we need for now. The existing override was wrong, in that `// args` would use the arguments we already added, again. So instead of deliberating about how to make this work right in all cases, we don’t need it, we trim it. Change-Id: I6443a0808b8bfd5e4db939b669c6afc741954db8 Reviewed-on: https://cl.tvl.fyi/c/depot/+/3057 Tested-by: BuildkiteCI Reviewed-by: sterni <sternenseemann@systemli.org> </content>
</entry>
<entry>
<title>feat(users/Profpatsch/blog): implement blog engine lol</title>
<updated>2021-04-30T21:47:42+00:00</updated>
<author>
<name>Profpatsch</name>
<email>mail@profpatsch.de</email>
</author>
<published>2021-01-29T14:58:33+00:00</published>
<link rel="alternate" type="text/html" href="http://code.tvl.fyi/commit/?id=713f06629757c507607cf5dc88399a84d54f2469"/>
<id>urn:sha1:713f06629757c507607cf5dc88399a84d54f2469</id>
<content type="text"> My horrible blog engine v0.0.0.0.1. Don’t judge. Change-Id: I427b4e84d67aa49793cb7625e4d8ca2824f00943 Reviewed-on: https://cl.tvl.fyi/c/depot/+/2456 Tested-by: BuildkiteCI Reviewed-by: Profpatsch <mail@profpatsch.de> </content>
</entry>
<entry>
<title>chore(nix): move rustSimple from users.Profpatsch.writers</title>
<updated>2021-04-24T10:23:55+00:00</updated>
<author>
<name>Profpatsch</name>
<email>mail@profpatsch.de</email>
</author>
<published>2021-04-23T20:04:42+00:00</published>
<link rel="alternate" type="text/html" href="http://code.tvl.fyi/commit/?id=eb41eef6127216543d8b28c9c423ac1be0a4ee24"/>
<id>urn:sha1:eb41eef6127216543d8b28c9c423ac1be0a4ee24</id>
<content type="text"> I think it’s solid enough to use in a wider context. Change-Id: If53e8bbb6b90fa88d73fb42730db470e822ea182 Reviewed-on: https://cl.tvl.fyi/c/depot/+/3055 Tested-by: BuildkiteCI Reviewed-by: sterni <sternenseemann@systemli.org> Reviewed-by: lukegb <lukegb@tvl.fyi> </content>
</entry>
<entry>
<title>feat(nix): add basic netstring nix generation functions</title>
<updated>2021-04-24T09:54:34+00:00</updated>
<author>
<name>Profpatsch</name>
<email>mail@profpatsch.de</email>
</author>
<published>2021-04-23T17:05:59+00:00</published>
<link rel="alternate" type="text/html" href="http://code.tvl.fyi/commit/?id=7e888c3c7bb36f6ab6e83d4a6f6a755ff4156791"/>
<id>urn:sha1:7e888c3c7bb36f6ab6e83d4a6f6a755ff4156791</id>
<content type="text"> Moving to toplevel so I can use them with `runExecline`. They should be pretty atomic, and are proven to work (tests are still in my user dir, since they test the producers indirectly via the python parser and I don’t want to pull it out right now). Change-Id: Id0baa3adcb2ec646458a104c7868c2889b8c64f5 Reviewed-on: https://cl.tvl.fyi/c/depot/+/3054 Reviewed-by: Profpatsch <mail@profpatsch.de> Tested-by: BuildkiteCI </content>
</entry>
<entry>
<title>feat(nix/buildGo): add the import position to errmsg</title>
<updated>2021-04-23T16:35:57+00:00</updated>
<author>
<name>Profpatsch</name>
<email>mail@profpatsch.de</email>
</author>
<published>2021-04-05T09:41:37+00:00</published>
<link rel="alternate" type="text/html" href="http://code.tvl.fyi/commit/?id=2224731e0d007fbff27f31f4e1771aad723b603f"/>
<id>urn:sha1:2224731e0d007fbff27f31f4e1771aad723b603f</id>
<content type="text"> When a foreign dep is missing a dependency, it is good to have a context. e.g. the `github.com/charmbracelet/bubblegum` package has a lot of dependencies that are only used in its `examples/` dir; this is not obvious, unless we also print where the imports come from. New error message: ``` error: missing foreign dependency 'github.com/containerd/console' in 'github.com/charmbracelet/bubbletea, imported at /nix/store/0cry4sg6bzxqwk5zl2nxhas6k5663svg-source/tea.go:22:2' ``` Change-Id: If34a3c62b9d77d4aea108b5e011e16fbd03e8554 Reviewed-on: https://cl.tvl.fyi/c/depot/+/2852 Tested-by: BuildkiteCI Reviewed-by: tazjin <mail@tazj.in> </content>
</entry>
</feed>