piston/runtimes/octave.nix

30 lines
596 B
Nix
Raw Permalink Normal View History

2022-02-07 05:36:32 +01:00
{pkgs, piston, ...}:
let
pkg = pkgs.octave;
in piston.mkRuntime {
language = "octave";
version = pkg.version;
aliases = [
"matlab"
"m"
];
run = ''
${pkg}/bin/octave --no-gui --no-window-system --no-history --no-init-file --no-site-file --norc --quiet "$@"
'';
tests = [
(piston.mkTest {
files = {
"test.m" = ''
disp("OK");
'';
};
args = [];
stdin = "";
packages = [];
main = "test.m";
})
];
}