refactor: v3
This commit is contained in:
parent
9434b666e5
commit
4c7c6b5307
26 changed files with 55 additions and 242 deletions
6
scripts/00-install-requirements.sh
Normal file
6
scripts/00-install-requirements.sh
Normal file
|
@ -0,0 +1,6 @@
|
|||
#!/bin/sh
|
||||
|
||||
# This file only installs what is needed for the sync to perform...
|
||||
|
||||
$SUDO $PM $PM_INSTALL $PM_NOCONFIRM \
|
||||
rsync
|
8
scripts/10-copy-files.sh
Normal file
8
scripts/10-copy-files.sh
Normal file
|
@ -0,0 +1,8 @@
|
|||
#!/bin/sh
|
||||
|
||||
HOME_FILES=${HOME_FILES:-./files/home}
|
||||
ROOT_FILES=${ROOT_FILES:-./files/root}
|
||||
|
||||
# overwrite files but preserve files surrounding
|
||||
rsync -av $HOME_FILES/ $HOME
|
||||
$SUDO rsync -av $ROOT_FILES/ /
|
23
scripts/20-install-pkgs.sh
Normal file
23
scripts/20-install-pkgs.sh
Normal file
|
@ -0,0 +1,23 @@
|
|||
#!/bin/sh
|
||||
|
||||
PACKAGE_LIST=${PACKAGE_LIST:-./package.list}
|
||||
GRAPHICAL_PACKAGE_LIST=${GRAPHICAL_PACKAGE_LIST:-./gpackage.list}
|
||||
|
||||
_APPLICATIONS=""
|
||||
while read -r pkg; do
|
||||
[ -z "$pkg" ] && continue
|
||||
[ "$(echo "$pkg" | cut -c1)" = "#" ] && continue
|
||||
_APPLICATIONS="$_APPLICATIONS $pkg"
|
||||
done < "$PACKAGE_LIST"
|
||||
|
||||
if [ "${GRAPHICAL:-no}" = "yes" ]; then
|
||||
if [ -f "$GRAPHICAL_PACKAGE_LIST" ]; then
|
||||
while read -r pkg; do
|
||||
[ -z "$pkg" ] && continue
|
||||
[ "$(echo "$pkg" | cut -c1)" = "#" ] && continue
|
||||
_APPLICATIONS="$_APPLICATIONS $pkg"
|
||||
done < "$GRAPHICAL_PACKAGE_LIST"
|
||||
fi
|
||||
fi
|
||||
|
||||
$SUDO $PM $PM_INSTALL $PM_NOCONFIRM $_APPLICATIONS
|
Loading…
Add table
Add a link
Reference in a new issue