Pour tout problème contactez-nous par mail : support@froggit.fr | La FAQ :grey_question: | Rejoignez-nous sur le Chat :speech_balloon:

Skip to content
Snippets Groups Projects
Commit 7bb4aea3 authored by Christophe Chaudier's avatar Christophe Chaudier :rocket:
Browse files

refactor: change init methode

parent 161f27c5
No related branches found
No related tags found
1 merge request!4Resolve "Bash more secure"
Pipeline #1371 passed with warnings
gitlab_url="https://gitlab.com/"
gitlab_api_token="dddddddddd"
......@@ -65,7 +65,9 @@ _load_config() {
# shellcheck disable=SC1090
source ${config_file}
else
_create_config
echo "There is no config file!"
echo "Use : mygb.sh init"
_fail "File ${config_file} doesn't exist"
fi
}
......@@ -86,16 +88,18 @@ _create_config() {
echo "Please add the line below on your .gitignore"
echo "${config_file}"
else
echo "You already have a config file !"
_fail "You already have a config file !"
fi
_succed
}
_export() {
_load_config
_succed
}
_import() {
_load_config
_succed
}
......@@ -125,7 +129,6 @@ main() {
*) _help ;;
esac
_load_config
_succed
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment