chore: os - package manager checker

main
CrimsonTome 2022-11-22 18:48:48 +00:00 committed by Rowan Clark
parent 4b0bd80ec2
commit b1f827cc6d
No known key found for this signature in database
GPG Key ID: F620D51904044094
1 changed files with 4 additions and 1 deletions

View File

@ -12,6 +12,9 @@ echo $hostname
os=$(lsb_release -d| awk '{print $2}') # definitely works on Fedora
echo $os
[ $os == "Ubuntu" ] && packageManager='apt' || [ $os == "Fedora" ] && packageManager='dnf' || echo "OS not yet supported"
echo $packageManager
# ensure some directories exist
gitDir=$homeDir"/git"
[ ! -d $gitDir ] && mkdir -p $gitDir || echo $gitDir" already exists"
@ -24,4 +27,4 @@ configDir=$homeDir"/.config"
# create an ssh key, for use with git/github
ssh-keygen -t ed25519 -f $sshDir"/id_ed25519_git" -N ''
ssh-keygen -t ed25519 -f $sshDir"/id_ed25519_git" -N ''