From b1f827cc6d06a8592a58a6e7310ad02ae85e267d Mon Sep 17 00:00:00 2001 From: CrimsonTome Date: Tue, 22 Nov 2022 18:48:48 +0000 Subject: [PATCH] chore: os - package manager checker --- post-install | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/post-install b/post-install index 214dd97..6e01d63 100755 --- a/post-install +++ b/post-install @@ -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 '' \ No newline at end of file +ssh-keygen -t ed25519 -f $sshDir"/id_ed25519_git" -N ''