mirror of
https://github.com/foxlet/macOS-Simple-KVM.git
synced 2025-03-01 03:15:13 +01:00
fetch.sh: provide dependencies using nix-shell if available
This commit is contained in:
parent
2324d48c66
commit
d5262e9747
2 changed files with 15 additions and 0 deletions
|
@ -7,6 +7,12 @@ set +x;
|
|||
SCRIPTDIR="$(dirname "$0")";
|
||||
cd "$SCRIPTDIR"
|
||||
|
||||
if [ -x "$(command -v nix-shell)" ]; then
|
||||
echo "Nix detected, using nix-shell for dependencies..."
|
||||
nix-shell --pure --run "python fetch-macos.py $*"
|
||||
exit
|
||||
fi
|
||||
|
||||
initpip() {
|
||||
if [ -x "$(command -v easy_install)" ]; then
|
||||
sudo easy_install pip
|
||||
|
|
9
tools/FetchMacOS/shell.nix
Normal file
9
tools/FetchMacOS/shell.nix
Normal file
|
@ -0,0 +1,9 @@
|
|||
{ pkgs ? import <nixpkgs> {} }:
|
||||
|
||||
pkgs.mkShell {
|
||||
propagatedBuildInputs = with pkgs.python3Packages; [
|
||||
python
|
||||
requests
|
||||
click
|
||||
];
|
||||
}
|
Loading…
Add table
Reference in a new issue