#!/bin/bash export ROOT=~/dotfiles export OS=$1 export DOTFILES=$ROOT/$OS export EDITOR=micro case $2 in edit) $EDITOR $ROOT/$OS/config/$3 ;; add) echo " - $3" >> $ROOT/$OS/packages.conf.yaml ;; install) sudo pacman -Sy python --noconfirm SCRIPTS=$DOTFILES/install_scripts $SCRIPTS/pre-install $SCRIPTS/install-packages # if (( $3 == "applications" )) # then # $SCRIPTS/install-applications # fi $SCRIPTS/post-install ;; *) echo "Commands:" echo " install installs the dotfiles" echo " edit edit one of the config files" echo " add add a package to the list" ;; esac