Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
29 changes: 5 additions & 24 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,29 +22,8 @@ jobs:

- name: Run setup script
shell: pixi exec --spec sed -- bash -e {0}
run: |
sed -i "s?main?${{ github.event.pull_request.head.ref }}?g" pixi-setup.sh
sed -i "s?init.sh | bash?init.sh | sed 's,main,${{ github.event.pull_request.head.ref }},g' | bash?" pixi-setup.sh
printf "\n1\n" | ./pixi-setup.sh

osx-64:
runs-on: macos-13
strategy:
fail-fast: false

steps:
- name: Checkout pull request branch
uses: actions/checkout@v4
with:
fetch-depth: 0

- name: Setup pixi
uses: prefix-dev/setup-pixi@v0.8.3
with:
run-install: false

- name: Run setup script
shell: pixi exec --spec sed -- zsh -e {0}
env:
INSTALL_TYPE: full
run: |
sed -i "s?main?${{ github.event.pull_request.head.ref }}?g" pixi-setup.sh
sed -i "s?init.sh | bash?init.sh | sed 's,main,${{ github.event.pull_request.head.ref }},g' | bash?" pixi-setup.sh
Expand All @@ -68,7 +47,9 @@ jobs:

- name: Run setup script
shell: pixi exec --spec sed -- zsh -e {0}
env:
INSTALL_TYPE: full
run: |
sed -i "s?main?${{ github.event.pull_request.head.ref }}?g" pixi-setup.sh
sed -i "s?init.sh | bash?init.sh | sed 's,main,${{ github.event.pull_request.head.ref }},g' | bash?" pixi-setup.sh
printf "\n1\n" | ./pixi-setup.sh
printf "\n1\n" | ./pixi-setup.sh
25 changes: 1 addition & 24 deletions .github/workflows/dispatch_ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,29 +27,6 @@ jobs:
sed -i "s?init.sh | bash?init.sh | sed 's,StatFunGen/pixi-setup/main,${{ github.repository }}/${{ github.ref_name }},g' | bash?" pixi-setup.sh
printf "\n1\n" | ./pixi-setup.sh

osx-64_pixi:
runs-on: macos-latest
strategy:
fail-fast: false

steps:
- name: Checkout pull request branch
uses: actions/checkout@v4
with:
fetch-depth: 0

- name: Setup pixi
uses: prefix-dev/setup-pixi@v0.8.3
with:
run-install: false

- name: Run setup script
shell: pixi exec --spec sed -- bash -e {0}
run: |
sed -i "s?StatFunGen/pixi-setup/main?${{ github.repository }}/${{ github.ref_name }}?g" pixi-setup.sh
sed -i "s?init.sh | bash?init.sh | sed 's,StatFunGen/pixi-setup/main,${{ github.repository }}/${{ github.ref_name }},g' | bash?" pixi-setup.sh
printf "\n1\n" | ./pixi-setup.sh

osx-arm64_pixi:
runs-on: macos-14
strategy:
Expand All @@ -71,4 +48,4 @@ jobs:
run: |
sed -i "s?StatFunGen/pixi-setup/main?${{ github.repository }}/${{ github.ref_name }}?g" pixi-setup.sh
sed -i "s?init.sh | bash?init.sh | sed 's,StatFunGen/pixi-setup/main,${{ github.repository }}/${{ github.ref_name }},g' | bash?" pixi-setup.sh
printf "\n1\n" | ./pixi-setup.sh
printf "\n1\n" | ./pixi-setup.sh
5 changes: 3 additions & 2 deletions envs/full_packages.txt
Original file line number Diff line number Diff line change
Expand Up @@ -128,11 +128,11 @@ sos-r
bioconductor-annotationdbi
bioconductor-clusterprofiler
bioconductor-edger
bioconductor-genomeinfodb
bioconductor-genomeinfodbdata
bioconductor-illuminahumanmethylation450kmanifest
bioconductor-illuminahumanmethylationepicmanifest
bioconductor-impute
bioconductor-limma
bioconductor-minfi
bioconductor-mofa2
bioconductor-org.hs.eg.db
bioconductor-pcatools
Expand All @@ -142,6 +142,7 @@ bioconductor-qvalue
bioconductor-sesame
bioconductor-sesamedata
r-abind
r-argparser
r-arrow
r-ape
r-bedtoolsr
Expand Down
7 changes: 0 additions & 7 deletions init.sh
Original file line number Diff line number Diff line change
Expand Up @@ -51,10 +51,3 @@ else
code-server --install-extension ionutvmi.path-autocomplete
code-server --install-extension usernamehw.errorlens
fi

# Temporary fix to run post-link scripts (only present in full install with bioconductor packages)
if [ -f "${PIXI_HOME}/envs/r-base/bin/.bioconductor-genomeinfodbdata-post-link.sh" ]; then
bash -c "PREFIX=${PIXI_HOME}/envs/r-base PATH=${PIXI_HOME}/envs/r-base/bin:${PATH} .bioconductor-genomeinfodbdata-post-link.sh"
fi
find ${PIXI_HOME}/envs/r-base/bin -name '*bioconductor-*-post-link.sh' | \
xargs -I % bash -c "PREFIX=${PIXI_HOME}/envs/r-base PATH=${PIXI_HOME}/envs/r-base/bin:${PATH} %"
49 changes: 32 additions & 17 deletions pixi-setup.sh
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ install_global_packages() {
missing_pkgs=$(comm -13 <(echo "$existing_pkgs" | sort -u) <(sort -u ${package_list}))

if (($(echo ${missing_pkgs} | wc -w) > 0 )); then
pixi global install $(echo ${missing_pkgs} | tr '\n' ' ')
pixi global install --run-post-link-scripts $(echo ${missing_pkgs} | tr '\n' ' ')
fi
}

Expand All @@ -48,7 +48,7 @@ inject_packages() {
fi

if (( $(echo ${missing_pkgs} | wc -w) > 0 )); then
pixi global install --environment ${environment} $(echo ${missing_pkgs} | tr '\n' ' ')
pixi global install --run-post-link-scripts --environment ${environment} $(echo ${missing_pkgs} | tr '\n' ' ')
fi
}

Expand All @@ -74,21 +74,36 @@ export PIXI_HOME="${_user_pixi_home:-${_default_pixi_home}}"
export RATTLER_CACHE_DIR="${PIXI_HOME}/cache"
echo "Using PIXI_HOME=${PIXI_HOME}"

# --- Prompt: install type ---
echo ""
echo "Choose installation type:"
echo " 1) minimal - Essential CLI tools + Python data science + base R"
echo " ~5 GB, ~100k files"
echo " 2) full - Complete bioinformatics environment (samtools, GATK, plink,"
echo " STAR, Seurat, bioconductor packages, etc.)"
echo " ~35 GB, ~350k files"
echo ""
read -r -p "Install type [1=minimal, 2=full, default=1]: " _install_type_input
case "${_install_type_input:-1}" in
2|full) INSTALL_TYPE="full" ;;
*) INSTALL_TYPE="minimal" ;;
esac
echo "Installation type: ${INSTALL_TYPE}"
# --- Install type ---
# Allow a preset INSTALL_TYPE env var to override the prompt (e.g. for
# non-interactive runs). A set-but-invalid value is a hard error.
if [[ -n "${INSTALL_TYPE:-}" ]]; then
case "$(echo "${INSTALL_TYPE}" | tr '[:upper:]' '[:lower:]')" in
2|full) INSTALL_TYPE="full" ;;
1|minimal) INSTALL_TYPE="minimal" ;;
*)
echo "ERROR: invalid INSTALL_TYPE='${INSTALL_TYPE}' (expected 'minimal'/'1' or 'full'/'2')" >&2
exit 1
;;
esac
echo "Installation type: ${INSTALL_TYPE} (from INSTALL_TYPE environment variable)"
else
# --- Prompt: install type ---
echo ""
echo "Choose installation type:"
echo " 1) minimal - Essential CLI tools + Python data science + base R"
echo " ~5 GB, ~100k files"
echo " 2) full - Complete bioinformatics environment (samtools, GATK, plink,"
echo " STAR, Seurat, bioconductor packages, etc.)"
echo " ~35 GB, ~350k files"
echo ""
read -r -p "Install type [1=minimal, 2=full, default=1]: " _install_type_input
case "${_install_type_input:-1}" in
2|full) INSTALL_TYPE="full" ;;
*) INSTALL_TYPE="minimal" ;;
esac
echo "Installation type: ${INSTALL_TYPE}"
fi

# Ensure PIXI_HOME exists
mkdir -p "${PIXI_HOME}"
Expand Down
Loading