1
1
mirror of https://github.com/nmattia/niv.git synced 2024-11-29 00:42:04 +03:00
Commit Graph

69 Commits

Author SHA1 Message Date
Nicolas Mattia
de5a4e7d01
Update devshell (#367)
* Update devshell

Update nixpkgs and simplify devshell

* Run ormolu

* Fixups

* Format nix files

* Update sources
2023-03-11 22:16:53 +01:00
Nicolas Mattia
6b6fffd73e Update nixpkgs 2022-12-20 11:39:08 +01:00
Jacek Galowicz
945aa20cd0 Fetch submodules if supported, and warn if submodules are used but not supported 2022-04-27 22:27:24 +02:00
Troels Henriksen
533d1ba912 Fix Nix setup to use aeson 2.
This also bumps the Nixpkgs snapshot.

Hopefully all the gross overrides will go away once aeson 2 becomes
the default in Nixpkgs.
2022-03-29 13:05:18 +02:00
Nikola Knezevic
788289706e fix: formatting error in sources.nix
This change fixes the issue with sources.nix file that's been failing in
CI. The format was fixed by running `nixpkgs-fmt .` inside of the
nix-shell.
2022-03-21 12:59:38 +01:00
George Shammas
9cb7ef336b Add the ability to pass submodules to builtins.fetchGit 2022-02-07 18:58:44 +01:00
Nicolas Mattia
a751be0775 Workaround nix-shell silliness 2021-11-08 12:58:57 +01:00
Nicolas Mattia
19545d3926 Bump nixpkgs 2021-11-08 12:58:57 +01:00
Nicolas Mattia
1819632b58 Update nixpkgs 2021-05-28 14:48:33 +02:00
Nicolas Mattia
94080ae828 Update to latest optparse-applicative 2021-05-11 14:36:18 +02:00
Nicolas Mattia
9d35b9e483 Turn NIV_OVERRIDE values into paths
Otherwise they're not accessible from the sandbox.
2020-10-05 11:39:37 +02:00
zimbatm
de84001689 sources.nix: bootstrap with a custom system
When combining Nix Flakes with niv, `builtins.currentSystem` is
disabled. This allows to bootstrap nixpkgs by passing the system from
the flake evaluation.
2020-08-21 15:22:14 +02:00
Nicolas Mattia
1294b321c8 Stop using ref in builtins.fetchGit fetcher
Instead, sources now record either `branch` or `tag`. The fetcher
specifies the correct ref (`/refs/heads/...` or `/refs/tags/...`) which
works in the newest version of Nix. The `ref` attribute can still be set
to override the logic.
2020-08-20 16:54:40 +02:00
Nicolas Mattia
f0be4cea7d Steal sanitizeDrvName 2020-08-20 11:31:41 +02:00
Nicolas Mattia
5c966856bc Sanitize source name
The `type` sources didn't get their name sanitized. This also fixes a
bug where builtins_fetchTarball would fail if because no name was given.
2020-08-20 11:31:41 +02:00
Nicolas Mattia
84827485e2 Make sources.nix remote friendly
The file can now be imported even if there is no sources.json in the
same directory.
2020-08-13 21:06:40 +02:00
Nicolas Mattia
38a536e59e Add NIV_OVERRIDE_{...}
This updates the sources.nix to replace the `outPath` field of package
`foo` with the content of envionment variable `NIV_OVERRIDE_foo`. In the
environment variable name, all characters outside of `[a-zA-Z0-9_]` are
escaped to `_`.
2020-08-13 16:26:28 +02:00
Nicolas Mattia
fc2cd34b83 Use ormolu from nixpkgs 2020-07-23 16:34:50 +02:00
Ben Sima
6bb2a97db7 Add ormolu to dev environment
Closes #221
2020-07-23 16:34:50 +02:00
Nicolas Mattia
fb1716a9c8 Update to nixpkgs 20.03 2020-07-07 17:07:02 +02:00
Nicolas Mattia
f73bf8d584 Add niv add local for local sources 2020-03-31 19:58:43 +02:00
Nicolas Mattia
372f96bff2 Prettify the derivation name in tarballs
The derivation name for package `foo` of type `tarball` is now `foo-src`
as opposed to `source`.
2020-03-27 12:03:14 +01:00
Nicolas Mattia
89e6f36b6f Retire builtin-tarball and builtin-url 2020-03-26 18:08:44 +01:00
Nicolas Mattia
13598ef956 Don't needlessly evaluate <nixpkgs>
This changes the logic to make sure the first `if` branch -- which pulls nixpkgs from sources.json -- is evaluated first. Moreover the `<nixpkgs>` check is changed to avoid actually evaluating `<nixpkgs>`.
2020-01-17 11:33:07 +01:00
Nicolas Mattia
0e460c49de Allow setting custom pkgs 2020-01-07 15:17:37 +01:00
zimbatm
2f2ee45a08
nixpkgs-fmt 2020-01-03 10:41:22 +01:00
zimbatm
f555c9cc5f
ci: add nixpkgs-fmt check 2020-01-02 19:29:38 +01:00
Nicolas Mattia
66a28898b0 Update nixpkgs 2019-12-16 14:58:18 +01:00
Christian Kampka
ec254c6853
init at 19.09 2019-12-16 14:44:29 +01:00
Nicolas Mattia
0d10454ebb Cleanup sources.nix 2019-12-08 20:39:45 +01:00
Nicolas Mattia
3e1d44bbfa Allow specifying custom sources.json
This turns `sources.nix` into a functor that acceps an argument:

``` nix
{ sourcesJson = <path/to/sources.json> ; }
```

The `sourcesJson` will be used instead of `./sources.json`.
2019-12-08 20:29:15 +01:00
Nicolas Mattia
dfc838aba2 Parse ref and rev in git 2019-11-30 12:36:23 +01:00
Nicolas Mattia
45a6020028 Add experimental (working) implementation of git specs 2019-11-30 12:22:27 +01:00
Nicolas Mattia
3ecde0148f Fix error message in sources.nix 2019-11-30 12:15:09 +01:00
Nicolas Mattia
e4ea8de1c5 Fix wording in comment 2019-11-28 09:56:41 +01:00
Nicolas Mattia
2e2e9eae97 Fix typo in error message 2019-11-28 09:56:41 +01:00
Nicolas Mattia
5271115a45 Remove TODOs 2019-11-28 09:56:41 +01:00
Nicolas Mattia
d9e35d67d8 Refactor fetchers 2019-11-28 09:56:41 +01:00
Nicolas Mattia
bd1aeb0a9c sources.nix: with -> let 2019-11-28 09:56:41 +01:00
zimbatm
1cb695fe7e
format with nixpkgs-fmt
I also couldn't help myself to change the `with { ... }` blocks
 to `let ... in` blocks.
2019-11-16 16:08:44 +00:00
Nicolas Mattia
a014fb3630 Fix functionArgs issue on recent nixpkgs 2019-09-23 13:42:58 +02:00
Nicolas Mattia
5111f83ed3 Add update script 2019-09-09 20:35:49 +02:00
Nicolas Mattia
c95078ee41 Upgrade termtosvg 2019-07-01 16:01:33 +02:00
Nicolas Mattia
3afc53fd0d nixpkgs: 18.09 -> 19.03 2019-06-26 11:27:13 +02:00
Domen Kožar
89cef63076
Use gitignore instead of duplicating it's logic 2019-06-15 16:55:58 +02:00
Michael Peyton Jones
96afc24d7e Make builtin-tarball the default 2019-06-01 13:04:16 +02:00
Michael Peyton Jones
0c48736b06 Support more types, including builtins 2019-06-01 13:04:16 +02:00
Nicolas Mattia
71000dc8b9 Drop unused file 2019-05-09 12:52:55 +02:00
Nicolas Mattia
9703f53e81 Add SVG to README 2019-04-14 21:11:18 +02:00
Nicolas Mattia
b638632993 Improve error message when no nixpkgs 2019-04-10 23:10:46 +02:00