cachix/devenv-nixpkgs
{ "createdAt": "2024-03-03T11:51:40Z", "defaultBranch": "main", "description": "Tested nixpkgs pins that work with devenv", "fullName": "cachix/devenv-nixpkgs", "homepage": null, "language": "Python", "name": "devenv-nixpkgs", "pushedAt": "2026-03-16T23:43:39Z", "stargazersCount": 24, "topics": [], "updatedAt": "2026-03-16T16:18:39Z", "url": "https://github.com/cachix/devenv-nixpkgs"}devenv-nixpkgs
Section titled “devenv-nixpkgs”Battle-tested nixpkgs using devenv’s extensive testing infrastructure.
Currently, the only supported release is rolling.
Rolling is based on nixpkgs-unstable plus any patches that improve the integrations and services offered by devenv.
In your devenv.yaml:
inputs: nixpkgs: url: github:cachix/devenv-nixpkgs/rolling flake: falsePatches
Section titled “Patches”Patches are defined in [patches/default.nix]!(./patches/default.nix) with two categories:
- upstream: Patches from nixpkgs PRs or unreleased fixes
- local: Patches not yet submitted upstream
Adding an Upstream Patch
Section titled “Adding an Upstream Patch”Download the PR patch and commit it as a local file:
curl -L https://github.com/NixOS/nixpkgs/pull/12345.patch -o patches/fix-python-darwin.patchThen add it to patches/default.nix:
upstream = [ ./fix-python-darwin.patch];Note: Avoid using
fetchpatchfor unmerged PRs — a force-push to the PR branch changes the content at that URL.fetchpatchis fine for merged commits whose content is immutable (e.g. unreleased fixes not yet in nixpkgs-unstable):(fetchpatch {name = "fix-python-darwin.patch";url = "https://github.com/NixOS/nixpkgs/commit/abc123.patch";sha256 = "sha256-AAAA...";})
Adding a Local Patch
Section titled “Adding a Local Patch”For patches not yet submitted upstream:
-
Create your patch in a nixpkgs checkout:
Terminal window git format-patch -1 HEAD -o /path/to/devenv-nixpkgs/patches/ -
Add it to
patches/default.nix:local = [./001-fix-something.patch];
Testing Locally
Section titled “Testing Locally”Test patches before pushing:
# Build a package with patches appliednix build .#legacyPackages.x86_64-linux.hello
# Or enter a shellnix developOverlays
Section titled “Overlays”For package-level fixes that don’t require source patches, use [overlays/default.nix]!(./overlays/default.nix):
[ (final: prev: { somePackage = prev.somePackage.overrideAttrs (old: { patches = old.patches or [] ++ [ ./fix.patch ]; }); })]Overlays are more resilient to upstream changes than source patches.
Test Results
Section titled “Test Results”Latest test results from devenv’s comprehensive test suite:
Status: ❌ Some tests failing
Nixpkgs revision: 70a799e
Test run: View detailed results
Last updated: 2026-03-16 16:18:33 UTC
Platform Results
Section titled “Platform Results”| Platform | Tests Failed/Total | Success Rate |
|---|---|---|
| aarch64-linux | 4/70 | 94.2% |
| x86_64-linux | 5/71 | 92.9% |
| aarch64-darwin | 14/71 | 80.2% |
| x86_64-darwin | 12/71 | 83.0% |
Summary
Section titled “Summary”- Total test jobs: 284
- Successful: 248 ✅
- Failed: 35 ❌
- Success rate: 87%
Deployment
Section titled “Deployment”How It Works
Section titled “How It Works”flake.niximports nixpkgs-unstable and applies patches at evaluation timeflake.lockpins the exact nixpkgs revision- CI runs weekly to update, test, and create release PRs
Branches
Section titled “Branches”main: development branch, receives weekly nixpkgs updatesrolling: stable release, promoted from main via PR
CI Workflow
Section titled “CI Workflow”Every Monday at 9:00 UTC (or manually triggered):
- Update:
nix flake updatepulls latest nixpkgs-unstable - Validate: Build a test package to verify patches apply
- Push: Commit updated
flake.locktomain - Test: Run devenv test suite across all platforms
- Summary: Update README with test results
- Release PR: Create PR to promote
main→rolling
Manual Updates
Section titled “Manual Updates”Test locally:
nix flake updatenix build .#legacyPackages.x86_64-linux.helloTrigger CI manually:
gh workflow run "Update and test"Release Process
Section titled “Release Process”After tests complete, a PR is automatically created to promote main → rolling with the test results summary.
Merge the PR to release.