add perl-rename to container and update related runtime scripts
This commit is contained in:
parent
35cd527c69
commit
9cbec53580
|
@ -40,6 +40,7 @@ with pkgs; rec {
|
||||||
gnutar
|
gnutar
|
||||||
gzip
|
gzip
|
||||||
gnugrep
|
gnugrep
|
||||||
|
rename
|
||||||
util-linux
|
util-linux
|
||||||
];
|
];
|
||||||
|
|
||||||
|
|
|
@ -15,11 +15,11 @@ in piston.mkRuntime {
|
||||||
export TMPDIR="$PWD"
|
export TMPDIR="$PWD"
|
||||||
|
|
||||||
# modify file extension
|
# modify file extension
|
||||||
mv "$1" "$1.v"
|
filename="$1"
|
||||||
filename="$1.v"
|
rename 's/$/.v/' "$filename"
|
||||||
shift
|
shift
|
||||||
|
|
||||||
${pkg}/bin/v run "$filename" "$@"
|
${pkg}/bin/v run "$filename.v" "$@"
|
||||||
'';
|
'';
|
||||||
|
|
||||||
tests = [
|
tests = [
|
||||||
|
|
|
@ -8,7 +8,7 @@ in piston.mkRuntime {
|
||||||
|
|
||||||
# Add .zig extension for compile script and optimize compiler for small programs
|
# Add .zig extension for compile script and optimize compiler for small programs
|
||||||
compile = ''
|
compile = ''
|
||||||
for f; do mv "$f" "$f.zig"; done
|
rename 's/$/.zig/' "$@"
|
||||||
${pkg}/bin/zig build-exe -O ReleaseSafe --color off --cache-dir . --global-cache-dir . --name out *.zig
|
${pkg}/bin/zig build-exe -O ReleaseSafe --color off --cache-dir . --global-cache-dir . --name out *.zig
|
||||||
'';
|
'';
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue