Restructured some functions, switched to yubikey/gpg for ssh, added new gpg key, removed the old ones, added automatic config file insertion
This commit is contained in:
parent
83ba9af452
commit
14184eca99
|
@ -14,25 +14,22 @@ function config_git {
|
|||
git config --global help.autocorrect 50
|
||||
git config --list
|
||||
}
|
||||
function install_software {
|
||||
#Negativo17 Repo
|
||||
sudo dnf config-manager --add-repo=http://negativo17.org/repos/fedora-multimedia.repo
|
||||
|
||||
function install_rpms {
|
||||
#Google Play Music Desktop Player
|
||||
export rpm_links=$(curl -s https://api.github.com/repos/MarshallOfSound/Google-Play-Music-Desktop-Player-UNOFFICIAL-/releases | grep browser_download_url | grep '64[.]rpm' | head -n 1 | cut -d '"' -f 4)
|
||||
#RPM Fusion Free
|
||||
export rpm_links=$rpm_links http://download1.rpmfusion.org/free/fedora/rpmfusion-free-release-$(rpm -E %fedora).noarch.rpm
|
||||
#RPM Fusion Non-Free
|
||||
export rpm_links="$rpm_links http://download1.rpmfusion.org/nonfree/fedora/rpmfusion-nonfree-release-$(rpm -E %fedora).noarch.rpm"
|
||||
#Google Chrome
|
||||
#export rpm_links="$rpm_links https://dl.google.com/linux/direct/google-chrome-stable_current_x86_64.rpm"
|
||||
export rpm_links=$(curl -s \
|
||||
https://api.github.com/repos/MarshallOfSound/Google-Play-Music-Desktop-Player-UNOFFICIAL-/releases \
|
||||
| grep browser_download_url | grep '64[.]rpm' | head -n 1 | cut -d '"' -f 4)
|
||||
|
||||
#Keybase
|
||||
export rpm_links="$rpm_links https://prerelease.keybase.io/keybase_amd64.rpm"
|
||||
#Google Play Music Desktop Player
|
||||
export rpm_links="$rpm_links curl -s https://api.github.com/repos/atom/atom/releases | grep browser_download_url | grep '64[.]deb' | head -n 1 | cut -d '"' -f 4"
|
||||
|
||||
#Install RPMs specified above.
|
||||
sudo dnf install -y $rpm_links
|
||||
sudo dnf copr enable -y decathorpe/syncthing #Syncthing
|
||||
#sudo dnf copr enable -y region51/chrome-gnome-shell #Makes the gnome extension site function in Chrome
|
||||
sudo dnf copr enable -y tpokorra/nextcloud #Nextcloud-Client
|
||||
}
|
||||
function install_software {
|
||||
add_repos
|
||||
install_rpms
|
||||
export packages="vlc ffmpeg" #Multimedia Stuff
|
||||
export packages="$packages hexchat gajim" #Messaging
|
||||
export packages="$packages nextcloud-client"
|
||||
|
@ -49,6 +46,18 @@ function install_software {
|
|||
sudo dnf install -y $packages --best --allowerasing
|
||||
sudo dnf upgrade -y
|
||||
}
|
||||
function add_repos {
|
||||
#Negativo17 Fedora Multimedia
|
||||
sudo dnf config-manager --add-repo=http://negativo17.org/repos/fedora-multimedia.repo
|
||||
#RPM-Fusion Free
|
||||
sudo dnf install http://download1.rpmfusion.org/free/fedora/rpmfusion-free-release-$(rpm -E %fedora).noarch.rpm
|
||||
#RPM-Fusion Non Free
|
||||
sudo dnf install http://download1.rpmfusion.org/nonfree/fedora/rpmfusion-nonfree-release-$(rpm -E %fedora).noarch.rpm
|
||||
#Syncthing
|
||||
sudo dnf copr enable -y decathorpe/syncthing
|
||||
#Nextcloud Client
|
||||
sudo dnf copr enable -y tpokorra/nextcloud
|
||||
}
|
||||
function config_ssh {
|
||||
echo -n "Application Name (ssh key):"
|
||||
read application
|
||||
|
@ -61,29 +70,42 @@ function config_ssh {
|
|||
echo "Insert this SSH key into gogs before you continue."
|
||||
pause
|
||||
}
|
||||
function get_gpg_keys {
|
||||
gpg2 --keyserver hkp://pool.sks-keyservers.net --recv-keys 691C036821A1C2A05415F572F338AD3815B5D61C 33BD6633839B232E1A24BF4262BEE5EB8F370DC6
|
||||
gpg2 --import ~/.password-store/.keybase-key.pgp
|
||||
function setup_gpg_ssh {
|
||||
gpg2 --keyserver hkp://pool.sks-keyservers.net --recv-keys 816054803C0F5F14C462398B3D512CA0D8E8352E
|
||||
sudo systemctl enable pcscd && sudo systemctl start pcscd
|
||||
pkill -9 gpg-agent
|
||||
eval $(gpg-agent --daemon --enable-ssh-support --sh)
|
||||
}
|
||||
function clone_git_repos {
|
||||
cd ~
|
||||
git clone ssh://git@jcg.re:10022/jcgruenhage/.password-store.git
|
||||
mkdir dev
|
||||
cd dev
|
||||
|
||||
mkcdir dev
|
||||
git clone ssh://git@jcg.re:10022/jcgruenhage/scripts.git
|
||||
git clone ssh://git@jcg.re:10022/jcgruenhage/prog16_17.git
|
||||
git clone ssh://git@jcg.re:10022/jcgruenhage/homepage.git
|
||||
git clone ssh://git@jcg.re:10022/klug-O-soft/kOs_Timer.git
|
||||
}
|
||||
git clone ssh://git@jcg.re:10022/jcgruenhage/config-files.git
|
||||
|
||||
mkcdir gopath/src/git.jcg.re/jcgruenhage/
|
||||
git clone ssh://git@jcg.re:10022/jcgruenhage/go_helloworld.git
|
||||
|
||||
cd ../../../..
|
||||
git clone ssh://git@github.com/jcgruenhage/freeotp-android.git
|
||||
git clone ssh://git@github.com/jcgruenhage/nextcloud-android.git
|
||||
git clone ssh://git@github.com/jcgruenhage/PlayMusicExportet.git
|
||||
}
|
||||
function mkcdir {
|
||||
mkdir -p -- "$1" &&
|
||||
cd -P -- "$1"
|
||||
}
|
||||
function add_config_files {
|
||||
cp -f ~/dev/config-files/.bashrc ~/.bashrc
|
||||
source ~/.bashrc
|
||||
}
|
||||
# Execution:
|
||||
install_software
|
||||
config_ssh
|
||||
setup_gpg_ssh
|
||||
config_git
|
||||
clone_git_repos
|
||||
get_gpg_keys
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
add_config_files
|
||||
|
|
Loading…
Reference in a new issue