videocutting/shell.nix

46 lines
695 B
Nix
Raw Normal View History

{ pkgs ? import <nixpkgs> { } }:
2023-02-16 16:54:39 +01:00
let
2023-06-11 17:04:44 +02:00
php = pkgs.php82;
inherit(pkgs.php82Packages) composer;
2023-02-16 16:54:39 +01:00
projectInstall = pkgs.writeShellApplication {
name = "project-install";
runtimeInputs = [
2023-06-11 17:04:44 +02:00
composer
2023-02-16 16:54:39 +01:00
];
text = ''
composer install
'';
};
2023-06-11 17:04:44 +02:00
projectUpdate = pkgs.writeShellApplication {
name = "project-update";
runtimeInputs = [
composer
];
text = ''
composer update --with-all-dependencies
./vendor/bin/phpunit
'';
};
2023-02-16 16:54:39 +01:00
in pkgs.mkShell {
name = "Videocutting";
buildInputs = [
pkgs.ffmpeg
2023-06-11 17:04:44 +02:00
php
composer
2023-02-16 16:54:39 +01:00
projectInstall
2023-06-11 17:04:44 +02:00
projectUpdate
];
shellHook = ''
export PATH="$(pwd)/:$PATH"
'';
}