From 35fe20a97092bd67c8fe389f8312873ded72abdb Mon Sep 17 00:00:00 2001 From: Ayo Date: Sat, 28 Mar 2026 09:34:09 +0100 Subject: [PATCH] feat(conf): intial initializing command for initializing initial config file --- conf.sh | 17 +++++++++++++++-- 1 file changed, 15 insertions(+), 2 deletions(-) diff --git a/conf.sh b/conf.sh index 335a08d..887636e 100644 --- a/conf.sh +++ b/conf.sh @@ -2,12 +2,25 @@ # configuration management +. $HOME/ayo.conf + command=$2 function main() { case $command in - "edit") - echo "Editing config file" + "edit") # edit the script + echo "Editing config script" + vim "$scripts_dir/conf.sh" + ;; + "init") #TODO: a command that initializes the configuration + echo "Initializing config file..." + # check if there is an existing config file + # if yes, ask if user is sure? + # if yes, back up with datetime + # copy example config file to $HOME/ayo.conf + ;; + *) # edit the configuration + echo "Editing config file..." vim "$HOME/ayo.conf" ;; esac