Repository navigation
Conversation
nix-run is a convenience script that builds an expression with nix-build and then automatically executes the build result. If the result is not an executable file, nix-run outputs an error message.
Member
|
Hm, not sure if this is very useful... I mean, this is just "nix-build ... && ./result" right? (And how often is $out itself a script?) |
Member
Author
|
@edolstra Yes, this is basically just a way of running Then simply do this to activate a specific environment: Each time you run Of course, this is a very simple tool, and it doesn't have to be put in the Nix distribution. I can submit it to nixpkgs if you think it is a better idea. |
zolodev
pushed a commit
to zolodev/nix
that referenced
this pull request
Jan 1, 2024
ConnorBaker
pushed a commit
to ConnorBaker/nix
that referenced
this pull request
Jul 25, 2025
…94fb5ba-acbd-46c2-b441-796aa671a07b Release v3.8.3
ConnorBaker
added a commit
to ConnorBaker/nix
that referenced
this pull request
May 24, 2026
Landed 18 commits across 6 shards covering 20 candidates: - libstore +8 (NixOS#1+NixOS#3, NixOS#7, NixOS#11, NixOS#55, NixOS#59, NixOS#101, NixOS#153, NixOS#185) - libexpr +3 covering 4 (NixOS#192, NixOS#202+NixOS#203 folded, NixOS#204) - libutil +4 (NixOS#97, NixOS#124, NixOS#167, NixOS#224) - libfetchers +1 (NixOS#53) - libflake +1 (NixOS#133, rename only — deviation documented) - libmain +1 (NixOS#223; NixOS#222 already on branch) Skipped: NixOS#76 (libc++ in dev shell lacks <generator>) and several RED-bucket items. 4-pass review chain: Pass A (parallel adversarial) caught 2 BLOCKERS — libstore NixOS#153 over-broad rename corrupted the external-builders JSON wire-key, and libutil NixOS#97 dropped the inline allowed-name list breaking eval-fail-hashString-2.err.exp. Both fixed via amend; parseEnumOrThrow extended to render 'a', 'b', or 'c' with Oxford comma + suggestions. Pass B (/code-review) found no blockers; substantive amends include libexpr's callFunction hot-path now reading a ctor-frozen profilerHooks snapshot, libstore's tryUpperFallLower returning std::pair<R, bool>, libutil completing three migration gaps. Pass C found one real clang-tidy error (parse-enum.hh missing configuration.hh include); other shards only show the 5 known pre-existing master errors. Pass D nix build -L . green on all six shards. New catalog candidates surfaced by review: NixOS#225 (libfetchers getUserRegistry/getSystemRegistry/getGlobalRegistry share NixOS#53's first-call-wins shape on the hot path), NixOS#226 (showCompressionAlgo vs printHashAlgo enum-rendering inconsistency). Catalog total: 226 + 44. Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
ConnorBaker
added a commit
to ConnorBaker/nix
that referenced
this pull request
May 24, 2026
`class DerivationBuilderImpl : public DerivationBuilder, public DerivationBuilderParams`
inherited from `DerivationBuilderParams` purely to make the params
fields visible to member-name lookup inside the class body. The params
provide no virtual surface — they are a data bag — so the inheritance
just leaked the param fields (`drv`, `drvPath`, `drvOptions`,
`inputPaths`, `initialOutputs`, `buildMode`, `defaultPathsInChroot`,
`systemFeatures`, `desugaredEnv`, `buildResult`) into the class's
public/protected name-lookup. Hold a `DerivationBuilderParams params`
member instead and rewrite every member-name access to `params.X`.
Six subclasses are defined across `chroot-/linux-/freebsd-/darwin-/
external-derivation-builder.cc` (each `#include`d into
derivation-builder.cc), counting `ChrootLinuxDerivationBuilder` as a
distinct subclass: their bodies that reference these fields are
rewritten the same way. `freebsd-derivation-builder.cc` accesses none
of the renamed fields and is unchanged. `chroot-derivation-builder.cc::
prepareSandbox` declared a local `BuildChrootParams params{...}` that
would now shadow the class member; renamed it to `chrootParams` to
keep the class member visible after the local's declarator.
Refs candidate NixOS#153.
Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
ConnorBaker
added a commit
to ConnorBaker/nix
that referenced
this pull request
May 25, 2026
`class DerivationBuilderImpl : public DerivationBuilder, public DerivationBuilderParams`
inherited from `DerivationBuilderParams` purely to make the params
fields visible to member-name lookup inside the class body. The params
provide no virtual surface — they are a data bag — so the inheritance
just leaked the param fields (`drv`, `drvPath`, `drvOptions`,
`inputPaths`, `initialOutputs`, `buildMode`, `defaultPathsInChroot`,
`systemFeatures`, `desugaredEnv`, `buildResult`) into the class's
public/protected name-lookup. Hold a `DerivationBuilderParams params`
member instead and rewrite every member-name access to `params.X`.
Six subclasses are defined across `chroot-/linux-/freebsd-/darwin-/
external-derivation-builder.cc` (each `#include`d into
derivation-builder.cc), counting `ChrootLinuxDerivationBuilder` as a
distinct subclass: their bodies that reference these fields are
rewritten the same way. `freebsd-derivation-builder.cc` accesses none
of the renamed fields and is unchanged. `chroot-derivation-builder.cc::
prepareSandbox` declared a local `BuildChrootParams params{...}` that
would now shadow the class member; renamed it to `chrootParams` to
keep the class member visible after the local's declarator.
Refs candidate NixOS#153.
Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
angerman
added a commit
to angerman/nix
that referenced
this pull request
Aug 5, 2026
… executable form Build plan for Change 4 (the second surviving lever; NixOS#137 RCA'd it: narrows the warm gap 2.49x ff/1.83x M5 to ~1.5-2.2x, doesn't beat TW alone -> sequenced AFTER HAMT). Foundations J0-J3 proven standalone (research/jit_*.cc). De-risking insight (same shape as the HAMT GC plan): the J3 crux — JIT'd native code must spill live v3 pointers at allocation safepoints so the moving scavenger finds/updates them — maps onto the PROVEN GcRoot/walkAllV3Roots mechanism (precise_root.cc:196 already scans Values registered via GcRoot from C++ frames). A JIT'd frame maintains a shadow live-Value list enumerated by walkAllV3Roots; no new GC-root theory, mirror GcRoot. Steps: NixOS#152 real-scavenger safepoint spill (shadow frame + register with walkAllV3Roots); NixOS#153 value-stack ABI trampoline + hot-callCount compile trigger + deopt/bail (small opcode subset first, grow behind byte-id); NixOS#154 validate (byte-id + --brute under 1MB-nursery moving-GC stress with ALLOCATING JIT'd bodies = exercises the spill crux) + darwin-4 measure + ship behind NIX_V3_JIT. Must cover allocating bodies (pure-arith = gaming, forbidden). Both real levers (HAMT NixOS#1, JIT NixOS#2) now blueprinted to executable form; both multi-week, gated. lode/C4_JIT_BUILD_PLAN_2026-06-23.md. Copyright (c) 2026 Moritz Angermann <[email protected]>, Input Output Group. SPDX-License-Identifier: Apache-2.0
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
nix-run is a convenience script that builds an expression with nix-build
and then automatically executes the build result. If the result is not an
executable file, nix-run outputs an error message.