Files
pixi-deploy/autodeploy/setup.sh
T
2026-06-11 15:44:57 +02:00

46 lines
1002 B
Bash
Executable File

#!/bin/bash
set -euo pipefail
DESTINATION_DIR="$1"
echo $DESTINATION_DIR
# URL="https://github.com/prefix-dev/pixi/releases/latest/download/pixi-x86_64-unknown-linux-musl.tar.gz"
URL="https://gitea.psi.ch/python/pixi/releases/download/latest/pixi-x86_64-unknown-linux-musl.tar.gz"
ARCHIVE=$(basename "$URL")
BINARY=$(echo "$ARCHIVE" | cut -d. -f1 | cut -d- -f1)
SCRIPT_PATH=$(dirname "$0")
"$SCRIPT_PATH/download.sh" "$URL"
"$SCRIPT_PATH/gitignore.sh" add "$ARCHIVE" || true
"$SCRIPT_PATH/gitignore.sh" add "$BINARY" || true
# git config user.name "GFA AutoDeploy"
# git config user.email "gfa-autodeploy@psi.ch"
export CONDA_OVERRIDE_GLIBC=2.28
chmod +x "${GITHUB_WORKSPACE}/pixi"
cd "$DESTINATION_DIR"
"${GITHUB_WORKSPACE}/pixi" init || true
"${GITHUB_WORKSPACE}/pixi" install --all
# chmod -R g=u .
# "$SCRIPT_PATH/symlink.sh" "$PWD/.pixi/envs" "$PWD/../../envs"
# git add .gitattributes .gitignore pixi.lock pixi.toml
# git commit -m"automatic commit after install"
# git push