36 lines
2.0 KiB
Plaintext
36 lines
2.0 KiB
Plaintext
|
|
#!/bin/bash
|
||
|
|
|
||
|
|
#Collection of funtions and aliases to automate the redundant tasks.
|
||
|
|
|
||
|
|
#First let's declare a few variables
|
||
|
|
company = "NewCompany"
|
||
|
|
|
||
|
|
update-DOTFiles() { #This command takes the local copies and puts them into the git repo for updating
|
||
|
|
rsync -rhHAX /home/ganome/.config/shellconfig/* /home/ganome/Projects/$company/repos/DOT-Files/gentoo/gentoognome/home/user/.config/shellconfig/. ;
|
||
|
|
rsync -rhHAX /home/ganome/.bashrc /home/ganome/Projects/$company/repos/DOT-Files/gentoo/gentoognome/home/user/.bashrc ;
|
||
|
|
rsync -rhHAX /home/ganome/.config/i3* /home/ganome/Projects/$company/repos/DOT-Files/gentoo/gentoognome/home/user/.config/. ;
|
||
|
|
|
||
|
|
rsync -rhHAX /etc/portage/* $HOME/Projects/$company/repos/DOT-Files/gentoo/gentoognome/etc/portage/. ;
|
||
|
|
|
||
|
|
rsync -rhHAX /boot/config-$(uname -r) $HOME/Projects/$company/repos/DOT-Files/gentoo/gentoognome/kernel/. ;
|
||
|
|
|
||
|
|
rsync -rhHAX --exclude="heroic" --exclude="quassel-irc.org" --exclude="google-chrome" --exclude="PCSX2" --exclude="transmission" --exclude="legendary" --exclude="Element" \
|
||
|
|
--exclude="balena-etcher-electron" --exclude="discord" --exclude="discord.bak" --exclude="heroic" --exclude="Slack" --exclude="Code" --exclude="Epic" \
|
||
|
|
$HOME/.config/* $HOME/Projects/$company/repos/DOT-Files/gentoo/gentoognome/home/user/.config/. ;
|
||
|
|
|
||
|
|
rsync -rhHAX $HOME/.*rc $HOME/Projects/$company/repos/DOT-Files/gentoo/gentoognome/home/user/. ;
|
||
|
|
|
||
|
|
cd /home/ganome/Projects/$company/repos/DOT-Files ;
|
||
|
|
git pull ;
|
||
|
|
git add .;
|
||
|
|
git commit -am "Automated updated process of shell scripts and DOT Files (gentoognome)" ;
|
||
|
|
git push;
|
||
|
|
cd - ;
|
||
|
|
}
|
||
|
|
|
||
|
|
replace-DOTFile() { #This command takes the git repo configs and moves them onto the local machine - in case remote edits were done and local machine needs updating
|
||
|
|
rsync -rhHAX /home/ganome/Projects/$company/repos/DOT-Files/gentoo/gentoognome/home/user/.bashrc /home/ganome/. ;
|
||
|
|
rsync -rhHAX /home/ganome/Projects/$company/repos/DOT-Files/gentoo/gentoognome/home/user/.config/shellconfig/* /home/ganome/.config/shellconfig/. ;
|
||
|
|
}
|
||
|
|
|