aboutsummarylogtreecommitdiffstats
path: root/clm-wrapper.sh
blob: e52ff4ee20cafe2b55c9cec87bc985c320c3bcd3 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
#!/usr/bin/env bash

# default paths
CLEAN_HOME=/opt/clean-itasks-dev-bin

if [ -d "$HOME/.cache/clean-itasks-dev-bin" ]; then
    CLEAN_HOME="$HOME/.cache/clean-itasks-dev-bin"
elif [ -d "$PWD/clean-itasks-dev-bin" ]; then
    echo "Notice: using CWD install of clean/itasks"
    CLEAN_HOME="$PWD/clean-itasks-dev-bin"
else
    echo "Warning: you are calling clm using the system install of Clean," >&2
    echo "         this can cause compilation to fail. Use the clenv tool" >&2
    echo "         to create a user specific checkout of Clean/iTasks." >&2
fi

export CLEAN_HOME
exec /opt/clean-itasks-dev-bin/bin/clm "$@"