diff options
-rwxr-xr-x | genenetwork-local-container.sh | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/genenetwork-local-container.sh b/genenetwork-local-container.sh index 0f873a7..0875625 100755 --- a/genenetwork-local-container.sh +++ b/genenetwork-local-container.sh @@ -66,13 +66,21 @@ log() { } # Check dependencies -for cmd in git guix sudo diff cp; do +for cmd in git guix sudo diff cp grep; do if ! command -v "$cmd" &>/dev/null; then log "ERROR" "Required command '$cmd' not found" exit 1 fi done +guix_output=$(guix describe) +# Check for gn-bioinformatics channel +echo "$guix_output" | grep -q "gn-bioinformatics" +if [ $? = 1 ]; then + log ERROR "$guix_output" + log ERROR "Please make sure your current profile has gn-bioinformatics" + exit 1 +fi # Validate HOME is set if [ -z "${HOME:-}" ]; then log "ERROR" "HOME environment variable is not set" |