depot/nix/sparseTree/default.nix, branch refs/r/6613 monorepo for the virus lounge http://code.tvl.fyi/depot/atom?h=refs%2Fr%2F6613 2023-08-08T20:11:56+00:00 feat(nix/sparseTree): add optional `name` argument 2023-08-08T20:11:56+00:00 Vincent Ambo mail@tazj.in 2023-07-13T21:12:01+00:00 urn:sha1:fcda0682357f1ec531c494dac5aa49ba8ae8851a This allows pinning the name of the sparse tree derivation, which stops the continous rebuilding of tvix-store-proto dependents. I've opted to let the function take an attribute set instead and refactored the call sites appropriately. Change-Id: I3e57785094b1adbfffa24caf9f1c3384844fa200 Reviewed-on: https://cl.tvl.fyi/c/depot/+/8965 Reviewed-by: grfn <grfn@gws.fyi> Tested-by: BuildkiteCI Reviewed-by: sterni <sternenseemann@systemli.org> chore: remove comments formerly meant for alignment 2023-05-31T10:55:07+00:00 sterni sternenseemann@systemli.org 2023-05-31T10:48:04+00:00 urn:sha1:830bc9961af0947a5e14948808f19145afa7ddc7 /**/ is a nice way to align if statements which doesn't work with nixpkgs-fmt, since it'll reflow the comment to the line preceding the if. Consequently, we can delete these comments now. Change-Id: Ifa5327f846a903e07607b21f8eedbc32fc36f758 Reviewed-on: https://cl.tvl.fyi/c/depot/+/8689 Reviewed-by: sterni <sternenseemann@systemli.org> Autosubmit: sterni <sternenseemann@systemli.org> Tested-by: BuildkiteCI chore(3p/sources): Bump channels & overlays 2022-09-28T08:02:31+00:00 sterni sternenseemann@systemli.org 2022-09-26T17:33:05+00:00 urn:sha1:0c178a0ef61d2f5f4d6169c7a951663c62509cd7 Upstream nixpkgs removed a lot of aliases this time, so we needed to do the following transformations. It's a real shame that aliases only really become discoverable easily when they are removed. * runCommandNoCC -> runCommand * gmailieer -> lieer We also need to work around the fact that home-manager hasn't catched on to this rename. * mysql -> mariadb * pkgconfig -> pkg-config This also affects our Nix fork which needs to be bumped. * prometheus_client -> prometheus-client * rxvt_unicode -> rxvt-unicode-unwrapped * nix-review -> nixpkgs-review * oauth2_proxy -> oauth2-proxy Additionally, some Go-related builders decided to drop support for passing the sha256 hash in directly, so we need to use the generic hash arguments. Change-Id: I84aaa225ef18962937f8616a9ff064822f0d5dc3 Reviewed-on: https://cl.tvl.fyi/c/depot/+/6792 Autosubmit: sterni <sternenseemann@systemli.org> Tested-by: BuildkiteCI Reviewed-by: grfn <grfn@gws.fyi> Reviewed-by: flokli <flokli@flokli.de> Reviewed-by: tazjin <tazjin@tvl.su> Reviewed-by: wpcarro <wpcarro@gmail.com> style: format entire depot with nixpkgs-fmt 2022-01-31T16:11:53+00:00 Vincent Ambo mail@tazj.in 2022-01-30T16:06:58+00:00 urn:sha1:aa122cbae78ce97d60c0c98ba14df753d97e40b1 This CL can be used to compare the style of nixpkgs-fmt against other formatters (nixpkgs, alejandra). Change-Id: I87c6abff6bcb546b02ead15ad0405f81e01b6d9e Reviewed-on: https://cl.tvl.fyi/c/depot/+/4397 Tested-by: BuildkiteCI Reviewed-by: sterni <sternenseemann@systemli.org> Reviewed-by: lukegb <lukegb@tvl.fyi> Reviewed-by: wpcarro <wpcarro@gmail.com> Reviewed-by: Profpatsch <mail@profpatsch.de> Reviewed-by: kanepyork <rikingcoding@gmail.com> Reviewed-by: tazjin <tazjin@tvl.su> Reviewed-by: cynthia <cynthia@tvl.fyi> Reviewed-by: edef <edef@edef.eu> Reviewed-by: eta <tvl@eta.st> Reviewed-by: grfn <grfn@gws.fyi> feat(nix/sparseTree): allow specifying subtrees as relative paths 2021-10-10T10:03:03+00:00 sterni sternenseemann@systemli.org 2021-10-09T14:48:14+00:00 urn:sha1:2397fd8d569c5006b52a6afe677e0a597599c909 Passed strings will be treated as a relative path below the given root, which is quite convenient when using depot.path by eliminating a lot of repetition. Change-Id: I3da6058094484f4a6ffbb84f89ad4472b502a00c Reviewed-on: https://cl.tvl.fyi/c/depot/+/3704 Tested-by: BuildkiteCI Reviewed-by: tazjin <mail@tazj.in> feat(nix/sparseTree): get a directory with only selected children 2021-09-09T15:57:58+00:00 sterni sternenseemann@systemli.org 2021-09-08T22:04:55+00:00 urn:sha1:23dd8067c534d97bbd1820377998379beac1b205 Given a path (which points to a directory and a list of paths which are below that path, build a “sparse” version of that directory, so that it only contains the listed paths (and their children): $ nix-build -E 'with import ./. {}; nix.sparseTree ./. [ ./default.nix ./nix/readTree ./nix/buildLisp ./third_party/nixpkgs ./third_party/overlays ]' /nix/store/0ynj0gc613fs6mfp9snqcvdj5gfxbdzg-sparse-depot $ lr -t 'type == d' result/ result/ result/nix result/nix/buildLisp result/nix/buildLisp/example result/nix/readTree result/nix/readTree/tests […] result/third_party result/third_party/nixpkgs result/third_party/overlays result/third_party/overlays/haskell result/third_party/overlays/haskell/patches result/third_party/overlays/patches This is useful if a derivation depends on depot.path (e. g. if it wants to import depot at runtime). Usually this means that on every depot commit (or even worse, every change of .git on a local machine), this derivation has to be rebuild. By using sparseTree you can instead depend on a stripped down version of depot which only contains the bits you actually depend on, avoiding unrelated rebuilds. Change-Id: I127b108c8b177c657fb46786d0a6256516fd2c52 Reviewed-on: https://cl.tvl.fyi/c/depot/+/3503 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/sparseTree/default.nix, branch refs/r/6613</title>
<subtitle>monorepo for the virus lounge</subtitle>
<id>http://code.tvl.fyi/depot/atom?h=refs%2Fr%2F6613</id>
<link rel="self" href="http://code.tvl.fyi/depot/atom?h=refs%2Fr%2F6613"/>
<link rel="alternate" type="text/html" href="http://code.tvl.fyi/"/>
<updated>2023-08-08T20:11:56+00:00</updated>
<entry>
<title>feat(nix/sparseTree): add optional `name` argument</title>
<updated>2023-08-08T20:11:56+00:00</updated>
<author>
<name>Vincent Ambo</name>
<email>mail@tazj.in</email>
</author>
<published>2023-07-13T21:12:01+00:00</published>
<link rel="alternate" type="text/html" href="http://code.tvl.fyi/commit/?id=fcda0682357f1ec531c494dac5aa49ba8ae8851a"/>
<id>urn:sha1:fcda0682357f1ec531c494dac5aa49ba8ae8851a</id>
<content type="text"> This allows pinning the name of the sparse tree derivation, which stops the continous rebuilding of tvix-store-proto dependents. I've opted to let the function take an attribute set instead and refactored the call sites appropriately. Change-Id: I3e57785094b1adbfffa24caf9f1c3384844fa200 Reviewed-on: https://cl.tvl.fyi/c/depot/+/8965 Reviewed-by: grfn <grfn@gws.fyi> Tested-by: BuildkiteCI Reviewed-by: sterni <sternenseemann@systemli.org> </content>
</entry>
<entry>
<title>chore: remove comments formerly meant for alignment</title>
<updated>2023-05-31T10:55:07+00:00</updated>
<author>
<name>sterni</name>
<email>sternenseemann@systemli.org</email>
</author>
<published>2023-05-31T10:48:04+00:00</published>
<link rel="alternate" type="text/html" href="http://code.tvl.fyi/commit/?id=830bc9961af0947a5e14948808f19145afa7ddc7"/>
<id>urn:sha1:830bc9961af0947a5e14948808f19145afa7ddc7</id>
<content type="text"> /**/ is a nice way to align if statements which doesn't work with nixpkgs-fmt, since it'll reflow the comment to the line preceding the if. Consequently, we can delete these comments now. Change-Id: Ifa5327f846a903e07607b21f8eedbc32fc36f758 Reviewed-on: https://cl.tvl.fyi/c/depot/+/8689 Reviewed-by: sterni <sternenseemann@systemli.org> Autosubmit: sterni <sternenseemann@systemli.org> Tested-by: BuildkiteCI </content>
</entry>
<entry>
<title>chore(3p/sources): Bump channels & overlays</title>
<updated>2022-09-28T08:02:31+00:00</updated>
<author>
<name>sterni</name>
<email>sternenseemann@systemli.org</email>
</author>
<published>2022-09-26T17:33:05+00:00</published>
<link rel="alternate" type="text/html" href="http://code.tvl.fyi/commit/?id=0c178a0ef61d2f5f4d6169c7a951663c62509cd7"/>
<id>urn:sha1:0c178a0ef61d2f5f4d6169c7a951663c62509cd7</id>
<content type="text"> Upstream nixpkgs removed a lot of aliases this time, so we needed to do the following transformations. It's a real shame that aliases only really become discoverable easily when they are removed. * runCommandNoCC -> runCommand * gmailieer -> lieer We also need to work around the fact that home-manager hasn't catched on to this rename. * mysql -> mariadb * pkgconfig -> pkg-config This also affects our Nix fork which needs to be bumped. * prometheus_client -> prometheus-client * rxvt_unicode -> rxvt-unicode-unwrapped * nix-review -> nixpkgs-review * oauth2_proxy -> oauth2-proxy Additionally, some Go-related builders decided to drop support for passing the sha256 hash in directly, so we need to use the generic hash arguments. Change-Id: I84aaa225ef18962937f8616a9ff064822f0d5dc3 Reviewed-on: https://cl.tvl.fyi/c/depot/+/6792 Autosubmit: sterni <sternenseemann@systemli.org> Tested-by: BuildkiteCI Reviewed-by: grfn <grfn@gws.fyi> Reviewed-by: flokli <flokli@flokli.de> Reviewed-by: tazjin <tazjin@tvl.su> Reviewed-by: wpcarro <wpcarro@gmail.com> </content>
</entry>
<entry>
<title>style: format entire depot with nixpkgs-fmt</title>
<updated>2022-01-31T16:11:53+00:00</updated>
<author>
<name>Vincent Ambo</name>
<email>mail@tazj.in</email>
</author>
<published>2022-01-30T16:06:58+00:00</published>
<link rel="alternate" type="text/html" href="http://code.tvl.fyi/commit/?id=aa122cbae78ce97d60c0c98ba14df753d97e40b1"/>
<id>urn:sha1:aa122cbae78ce97d60c0c98ba14df753d97e40b1</id>
<content type="text"> This CL can be used to compare the style of nixpkgs-fmt against other formatters (nixpkgs, alejandra). Change-Id: I87c6abff6bcb546b02ead15ad0405f81e01b6d9e Reviewed-on: https://cl.tvl.fyi/c/depot/+/4397 Tested-by: BuildkiteCI Reviewed-by: sterni <sternenseemann@systemli.org> Reviewed-by: lukegb <lukegb@tvl.fyi> Reviewed-by: wpcarro <wpcarro@gmail.com> Reviewed-by: Profpatsch <mail@profpatsch.de> Reviewed-by: kanepyork <rikingcoding@gmail.com> Reviewed-by: tazjin <tazjin@tvl.su> Reviewed-by: cynthia <cynthia@tvl.fyi> Reviewed-by: edef <edef@edef.eu> Reviewed-by: eta <tvl@eta.st> Reviewed-by: grfn <grfn@gws.fyi> </content>
</entry>
<entry>
<title>feat(nix/sparseTree): allow specifying subtrees as relative paths</title>
<updated>2021-10-10T10:03:03+00:00</updated>
<author>
<name>sterni</name>
<email>sternenseemann@systemli.org</email>
</author>
<published>2021-10-09T14:48:14+00:00</published>
<link rel="alternate" type="text/html" href="http://code.tvl.fyi/commit/?id=2397fd8d569c5006b52a6afe677e0a597599c909"/>
<id>urn:sha1:2397fd8d569c5006b52a6afe677e0a597599c909</id>
<content type="text"> Passed strings will be treated as a relative path below the given root, which is quite convenient when using depot.path by eliminating a lot of repetition. Change-Id: I3da6058094484f4a6ffbb84f89ad4472b502a00c Reviewed-on: https://cl.tvl.fyi/c/depot/+/3704 Tested-by: BuildkiteCI Reviewed-by: tazjin <mail@tazj.in> </content>
</entry>
<entry>
<title>feat(nix/sparseTree): get a directory with only selected children</title>
<updated>2021-09-09T15:57:58+00:00</updated>
<author>
<name>sterni</name>
<email>sternenseemann@systemli.org</email>
</author>
<published>2021-09-08T22:04:55+00:00</published>
<link rel="alternate" type="text/html" href="http://code.tvl.fyi/commit/?id=23dd8067c534d97bbd1820377998379beac1b205"/>
<id>urn:sha1:23dd8067c534d97bbd1820377998379beac1b205</id>
<content type="text"> Given a path (which points to a directory and a list of paths which are below that path, build a “sparse” version of that directory, so that it only contains the listed paths (and their children): $ nix-build -E 'with import ./. {}; nix.sparseTree ./. [ ./default.nix ./nix/readTree ./nix/buildLisp ./third_party/nixpkgs ./third_party/overlays ]' /nix/store/0ynj0gc613fs6mfp9snqcvdj5gfxbdzg-sparse-depot $ lr -t 'type == d' result/ result/ result/nix result/nix/buildLisp result/nix/buildLisp/example result/nix/readTree result/nix/readTree/tests […] result/third_party result/third_party/nixpkgs result/third_party/overlays result/third_party/overlays/haskell result/third_party/overlays/haskell/patches result/third_party/overlays/patches This is useful if a derivation depends on depot.path (e. g. if it wants to import depot at runtime). Usually this means that on every depot commit (or even worse, every change of .git on a local machine), this derivation has to be rebuild. By using sparseTree you can instead depend on a stripped down version of depot which only contains the bits you actually depend on, avoiding unrelated rebuilds. Change-Id: I127b108c8b177c657fb46786d0a6256516fd2c52 Reviewed-on: https://cl.tvl.fyi/c/depot/+/3503 Tested-by: BuildkiteCI Reviewed-by: tazjin <mail@tazj.in> </content>
</entry>
</feed>