1
0
mirror of https://github.com/helix-editor/helix synced 2024-11-10 10:34:45 +01:00
Commit Graph

4 Commits

Author SHA1 Message Date
Max
4eed4c26e9
Use fromTOML on Nix >= 2.6.0 (#1892) 2022-03-30 11:28:05 -05:00
Max
b63b37d5a0
grammars.nix: use github type for fetchTree where possible (#1872) 2022-03-28 16:50:18 -05:00
Michael Davis
e01c53551d flake: use builtins.fetchTree to shallow-clone grammar repos
Here we perform a shallow fetch using builtins.fetchTree. In order
to make this work, we need to specify the `ref' for any repository
that doesn't have `master' as its default branch (I'm not sure why
this limitation exists since we don't need this when performing
the shallow fetch in `--grammar build')

This `ref' field is ignored by helix, so I have left it undocumented
for now, but I could be open to documenting it.
2022-03-10 17:31:57 +09:00
Michael Davis
37520f46ae fetch and build grammars with nix in flake
This commit replaces the out-of-date builder in the flake which relied
on submodules for fetching and the compiler for building. Now we
disable fetching and building explicitly with the environment variable
and then use builtins.fetchGit and a derivation mostly derived from
upstream to compile the grammars.

Anecdotally, this is still quite slow as builtins.fetchGit does not
seem to do shallow clones. I'm not sure I see a way around it though
without recording sha256s, which seems cumbersome.
2022-03-10 17:31:57 +09:00