Skip to content

Commit

Permalink
feat(build): fluidattacks#1202 update nixpkgs
Browse files Browse the repository at this point in the history
- Update nixpkgs to last version

Signed-off-by: Robin Quintero <rohaquinlop301@gmail.com>
  • Loading branch information
rohaquinlop committed Dec 14, 2023
1 parent fc1be2e commit cd42f30
Show file tree
Hide file tree
Showing 5 changed files with 23 additions and 17 deletions.
10 changes: 5 additions & 5 deletions makes/utils/makeNodeJsLock/entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -9,11 +9,11 @@ function main {
)

: && case "${node_js_version}" in
14) npm=__argNode14__/bin/npm ;;
16) npm=__argNode16__/bin/npm ;;
18) npm=__argNode18__/bin/npm ;;
*) critical NodeJs version not supported: "${node_js_version}" ;;
esac \
18) npm=__argNode18__/bin/npm ;;
20) npm=__argNode20__/bin/npm ;;
21) npm=__argNode21__/bin/npm ;;
*) critical NodeJs version not supported: "${node_js_version}" ;;
esac \
&& pushd "${package_json_dir}" \
&& "${npm}" install "${npm_install_args[@]}" \
&& popd || return 1
Expand Down
4 changes: 2 additions & 2 deletions makes/utils/makeNodeJsLock/main.nix
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@ makeScript {
entrypoint = ./entrypoint.sh;
name = "make-node-js-lock";
replace = {
__argNode14__ = makeNodeJsVersion "14";
__argNode16__ = makeNodeJsVersion "16";
__argNode18__ = makeNodeJsVersion "18";
__argNode20__ = makeNodeJsVersion "20";
__argNode21__ = makeNodeJsVersion "21";
};
}
8 changes: 7 additions & 1 deletion src/args/agnostic.nix
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,13 @@
fix' = __unfix__: let x = __unfix__ x // {inherit __unfix__;}; in x;
sources = import ../nix/sources.nix;
args = fix' (self: let
__nixpkgs__ = import sources.nixpkgs {inherit system;};
__nixpkgs__ = import sources.nixpkgs {
inherit system;
config = {
allowUnfree = true;
permittedInsecurePackages = ["ruby-2.7.8" "openssl-1.1.1w"];
};
};
in {
inherit __nixpkgs__;
__nixpkgsSrc__ = sources.nixpkgs;
Expand Down
12 changes: 6 additions & 6 deletions src/args/make-node-js-version/default.nix
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
{__nixpkgs__, ...}: version:
if version == "14"
then __nixpkgs__.nodejs-14_x
else if version == "16"
then __nixpkgs__.nodejs-16_x
else if version == "18"
then __nixpkgs__.nodejs-18_x
if version == "18"
then __nixpkgs__.nodejs_18
else if version == "20"
then __nixpkgs__.nodejs_20
else if version == "21"
then __nixpkgs__.nodejs_21
else abort "Supported node versions are: 14, 16 and 18"
6 changes: 3 additions & 3 deletions src/nix/sources.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,10 @@
"homepage": "",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "2362848adf8def2866fabbffc50462e929d7fffb",
"sha256": "0wjr874z2y3hc69slaa7d9cw7rj47r1vmc1ml7dw512jld23pn3p",
"rev": "e97b3e4186bcadf0ef1b6be22b8558eab1cdeb5d",
"sha256": "114ggf0xbwq16djg4qql3jljknk9xr8h7dw18ccalwqg9k1cgv0g",
"type": "tarball",
"url": "https://github.com/NixOS/nixpkgs/archive/2362848adf8def2866fabbffc50462e929d7fffb.tar.gz",
"url": "https://github.com/NixOS/nixpkgs/archive/e97b3e4186bcadf0ef1b6be22b8558eab1cdeb5d.tar.gz",
"url_template": "https://github.com/<owner>/<repo>/archive/<rev>.tar.gz"
}
}

0 comments on commit cd42f30

Please sign in to comment.