+21
LICENSE
+21
LICENSE
···
···
1
+
MIT License
2
+
3
+
Copyright (c) 2025 Peter Rice
4
+
5
+
Permission is hereby granted, free of charge, to any person obtaining a copy
6
+
of this software and associated documentation files (the "Software"), to deal
7
+
in the Software without restriction, including without limitation the rights
8
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+
copies of the Software, and to permit persons to whom the Software is
10
+
furnished to do so, subject to the following conditions:
11
+
12
+
The above copyright notice and this permission notice shall be included in all
13
+
copies or substantial portions of the Software.
14
+
15
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+
SOFTWARE.
+144
flake.lock
+144
flake.lock
···
···
1
+
{
2
+
"nodes": {
3
+
"flake-utils": {
4
+
"inputs": {
5
+
"systems": "systems"
6
+
},
7
+
"locked": {
8
+
"lastModified": 1731533236,
9
+
"narHash": "sha256-l0KFg5HjrsfsO/JpG+r7fRrqm12kzFHyUHqHCVpMMbI=",
10
+
"owner": "numtide",
11
+
"repo": "flake-utils",
12
+
"rev": "11707dc2f618dd54ca8739b309ec4fc024de578b",
13
+
"type": "github"
14
+
},
15
+
"original": {
16
+
"owner": "numtide",
17
+
"repo": "flake-utils",
18
+
"type": "github"
19
+
}
20
+
},
21
+
"helix": {
22
+
"inputs": {
23
+
"nixpkgs": [
24
+
"nixpkgs"
25
+
],
26
+
"rust-overlay": [
27
+
"jj",
28
+
"rust-overlay"
29
+
]
30
+
},
31
+
"locked": {
32
+
"lastModified": 1757688164,
33
+
"narHash": "sha256-IfSIZM7/4MwzxF769jVSBeB8JF4fHjYqaoan58HHw1E=",
34
+
"owner": "helix-editor",
35
+
"repo": "helix",
36
+
"rev": "c531b7a4faffe727adf78e1d3c2a54c0d85d0c0c",
37
+
"type": "github"
38
+
},
39
+
"original": {
40
+
"owner": "helix-editor",
41
+
"repo": "helix",
42
+
"type": "github"
43
+
}
44
+
},
45
+
"janet": {
46
+
"flake": false,
47
+
"locked": {
48
+
"lastModified": 1756559478,
49
+
"narHash": "sha256-Hd8DueT9f7vmK0QFJdRx7FgZ8BYh5prQyM++5Yb6tg4=",
50
+
"owner": "janet-lang",
51
+
"repo": "janet",
52
+
"rev": "e9c6678614ef731d5c4e9bf7915c48224eb0aeb1",
53
+
"type": "github"
54
+
},
55
+
"original": {
56
+
"owner": "janet-lang",
57
+
"ref": "v1.39.1",
58
+
"repo": "janet",
59
+
"type": "github"
60
+
}
61
+
},
62
+
"jj": {
63
+
"inputs": {
64
+
"flake-utils": "flake-utils",
65
+
"nixpkgs": [
66
+
"nixpkgs"
67
+
],
68
+
"rust-overlay": "rust-overlay"
69
+
},
70
+
"locked": {
71
+
"lastModified": 1756954389,
72
+
"narHash": "sha256-EKYM18UavIbZeI5/F5OKUzyjQip0yb6WPt6BZ2YpYww=",
73
+
"owner": "jj-vcs",
74
+
"repo": "jj",
75
+
"rev": "24f4e1083e8bcd6e5b8aaee3fa86e08cb7081d13",
76
+
"type": "github"
77
+
},
78
+
"original": {
79
+
"owner": "jj-vcs",
80
+
"ref": "v0.33.0",
81
+
"repo": "jj",
82
+
"type": "github"
83
+
}
84
+
},
85
+
"nixpkgs": {
86
+
"locked": {
87
+
"lastModified": 0,
88
+
"narHash": "sha256-z4n3ILedWTBVYvWgyR22rdVexTxXawGOANDF3czPTz4=",
89
+
"path": "/nix/store/hrc8ca75kaa5x6bzfka560ymd8gx07cj-source",
90
+
"type": "path"
91
+
},
92
+
"original": {
93
+
"id": "nixpkgs",
94
+
"type": "indirect"
95
+
}
96
+
},
97
+
"root": {
98
+
"inputs": {
99
+
"helix": "helix",
100
+
"janet": "janet",
101
+
"jj": "jj",
102
+
"nixpkgs": "nixpkgs"
103
+
}
104
+
},
105
+
"rust-overlay": {
106
+
"inputs": {
107
+
"nixpkgs": [
108
+
"jj",
109
+
"nixpkgs"
110
+
]
111
+
},
112
+
"locked": {
113
+
"lastModified": 1755139244,
114
+
"narHash": "sha256-SN1BFA00m+siVAQiGLtTwjv9LV9TH5n8tQcSziV6Nv4=",
115
+
"owner": "oxalica",
116
+
"repo": "rust-overlay",
117
+
"rev": "aeae248beb2a419e39d483dd9b7fec924aba8d4d",
118
+
"type": "github"
119
+
},
120
+
"original": {
121
+
"owner": "oxalica",
122
+
"repo": "rust-overlay",
123
+
"type": "github"
124
+
}
125
+
},
126
+
"systems": {
127
+
"locked": {
128
+
"lastModified": 1681028828,
129
+
"narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
130
+
"owner": "nix-systems",
131
+
"repo": "default",
132
+
"rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e",
133
+
"type": "github"
134
+
},
135
+
"original": {
136
+
"owner": "nix-systems",
137
+
"repo": "default",
138
+
"type": "github"
139
+
}
140
+
}
141
+
},
142
+
"root": "root",
143
+
"version": 7
144
+
}
+39
flake.nix
+39
flake.nix
···
···
1
+
{
2
+
description = "Various dev tools I often want to install from source";
3
+
4
+
inputs = {
5
+
jj.url = "github:jj-vcs/jj/v0.33.0";
6
+
jj.inputs.nixpkgs.follows = "nixpkgs";
7
+
helix.url = "github:helix-editor/helix";
8
+
helix.inputs.nixpkgs.follows = "nixpkgs";
9
+
helix.inputs.rust-overlay.follows = "jj/rust-overlay";
10
+
janet.url = "github:janet-lang/janet/v1.39.1";
11
+
janet.flake = false;
12
+
};
13
+
14
+
outputs =
15
+
{ nixpkgs, ... }@inputs:
16
+
let
17
+
inherit (builtins) attrValues removeAttrs;
18
+
forAllSystems = nixpkgs.lib.genAttrs [
19
+
"aarch64-linux"
20
+
"aarch64-darwin"
21
+
"x86_64-darwin"
22
+
"x86_64-linux"
23
+
];
24
+
in
25
+
{
26
+
packages = forAllSystems (system: {
27
+
jj = inputs.jj.packages.${system}.default;
28
+
helix = inputs.helix.packages.${system}.default;
29
+
janet = nixpkgs.legacyPackages.${system}.janet.overrideAttrs {
30
+
src = inputs.janet;
31
+
version = inputs.janet.shortRev;
32
+
};
33
+
default = nixpkgs.legacyPackages.${system}.buildEnv {
34
+
name = "src-apps";
35
+
paths = attrValues (removeAttrs inputs.self.packages.${system} [ "default" ]);
36
+
};
37
+
});
38
+
};
39
+
}
+19
readme.md
+19
readme.md
···
···
1
+
This is a nix flake wrapping programs that I often want to build from source, for easy use with `nix profile install`.
2
+
I used to include some of these directly in my [system flake](https://github.com/pvsr/nixfiles),
3
+
but rebuilding a ton of rust code every time I upgraded nixpkgs got old.
4
+
5
+
## Usage
6
+
7
+
```
8
+
# install all
9
+
nix profile install github:pvsr/apps-flake
10
+
11
+
# install all, building with the system nixpkgs
12
+
nix profile install --override-input nixpkgs nixpkgs github:pvsr/apps-flake
13
+
14
+
# ad-hoc upgrade
15
+
nix profile upgrade --override-input github:helix-editor/helix/some-branch apps-flake
16
+
17
+
# run a specific version of an app
18
+
nix run --override-input github:janet-lang/janet/v1.39.1 github:pvsr/apps-flake#janet
19
+
```