diff --git a/checkout-dev.sh b/checkout-dev.sh old mode 100644 new mode 100755 diff --git a/install.sh b/install.sh index 233e961..736219a 100755 --- a/install.sh +++ b/install.sh @@ -1,6 +1,5 @@ -#!/bin/bash +#!/usr/bin/env bash -# get operating system install_packages() { declare -A osInfo; osInfo[/usr/bin/pacman]=pacman @@ -11,10 +10,10 @@ install_packages() { do if [[ -f $f ]];then if [[ ${osInfo[$f]} == 'pacman' ]]; then - pacman -S clang make cmake fltk catch2 + sudo pacman -S clang make cmake fltk catch2 elif [[ ${osInfo[$f]} == 'apt' ]]; then - apt install clang make cmake clang-tidy libfltk1.3 libfltk1.3-dev + sudo apt install clang make cmake clang-tidy libfltk1.3 libfltk1.3-dev git clone https://github.com/catchorg/Catch2.git cd Catch2 @@ -22,7 +21,7 @@ install_packages() { sudo cmake --build build/ --target install elif [[ ${osInfo[$f]} == 'brew' ]]; then - brew install llvm clang make cmake clang-format fltk catch2 + sudo brew install llvm clang make cmake clang-format fltk catch2 fi fi @@ -59,4 +58,4 @@ mkdir demo/build cd installation echo "installation completed" -./build.sh \ No newline at end of file +./build.sh