mirror of
https://github.com/daylinmorgan/oizys.git
synced 2024-12-22 06:00:45 -06:00
add version to roc
This commit is contained in:
parent
435d63b188
commit
d49e0b044d
2 changed files with 19 additions and 4 deletions
|
@ -63,6 +63,11 @@ let
|
|||
(substring 6 2 longDate)
|
||||
]);
|
||||
|
||||
flakeVer =
|
||||
flake:
|
||||
"${flake.shortRev or flake.dirtyShortRev}-${mkDate (toString flake.lastModifiedDate)}";
|
||||
|
||||
|
||||
isNixFile = p: hasSuffix ".nix" p;
|
||||
isDefaultNixFile = p: hasSuffix "default.nix" p;
|
||||
filterNotDefaultNixFile = paths: filter (p: !(isDefaultNixFile p) && (isNixFile p)) paths;
|
||||
|
@ -81,5 +86,6 @@ in
|
|||
mkIfIn
|
||||
isNixFile
|
||||
listNixFilesRecursive
|
||||
flakeVer
|
||||
;
|
||||
}
|
||||
|
|
|
@ -6,14 +6,23 @@
|
|||
...
|
||||
}:
|
||||
let
|
||||
inherit (lib) mkIfIn;
|
||||
inherit (lib) mkIfIn flakeVer;
|
||||
|
||||
version = flakeVer inputs.roc;
|
||||
cfg = config.oizys.languages;
|
||||
rocPkgs = inputs.roc.packages.${pkgs.system};
|
||||
# I'm setting the versions so the changes are more apparent as flake is updated
|
||||
roc = rocPkgs.cli.overrideAttrs {
|
||||
inherit version;
|
||||
|
||||
};
|
||||
lang-server = rocPkgs.lang-server.overrideAttrs {
|
||||
inherit version;
|
||||
};
|
||||
|
||||
in
|
||||
{
|
||||
config = mkIfIn "roc" cfg {
|
||||
environment.systemPackages = with rocPkgs; [
|
||||
full # cli + lang_server
|
||||
];
|
||||
environment.systemPackages = [roc lang-server];
|
||||
};
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue