kostis-init's picture
Make setup.sh executable
5c115f4
raw
history blame
650 Bytes
#!/bin/bash
# Stop if any command fails
set -e
# Define version and paths
VERSION=2.9.3
MZN_DIR=/home/user/minizinc
# Download and extract MiniZinc
wget https://github.com/MiniZinc/MiniZincIDE/releases/download/${VERSION}/MiniZincIDE-${VERSION}-bundle-linux-x86_64.tgz
mkdir -p $MZN_DIR
tar -xzf MiniZincIDE-${VERSION}-bundle-linux-x86_64.tgz -C $MZN_DIR --strip-components=1
rm MiniZincIDE-${VERSION}-bundle-linux-x86_64.tgz
# Export path for the runtime
echo "export PATH=$MZN_DIR/bin:\$PATH" >> ~/.bashrc
echo "export PATH=$MZN_DIR/bin:\$PATH" >> ~/.profile
export PATH=$MZN_DIR/bin:$PATH
echo "βœ… setup.sh finished running" > setup_log.txt