mirror of
https://github.com/SebastianObi/LXMF-Tools.git
synced 2025-12-23 17:00:15 +00:00
Added service files
This commit is contained in:
27
build_git.sh
27
build_git.sh
@@ -21,7 +21,7 @@ COMMENT_INIT="Initial commit"
|
||||
_prompt() {
|
||||
echo -e ""
|
||||
echo -e "Select an option:"
|
||||
options=("Commit/Push" "Clear History" "Init" "Init (Pull only)" "Exit")
|
||||
options=("Commit/Push" "Clear History" "Init" "Init (Pull only)" "Init (Push only)" "Exit")
|
||||
select opt in "${options[@]}"; do
|
||||
case $opt in
|
||||
"Commit/Push"*)
|
||||
@@ -33,6 +33,9 @@ _prompt() {
|
||||
"Init (Pull only)"*)
|
||||
_init_pull
|
||||
break;;
|
||||
"Init (Push only)"*)
|
||||
_init_push
|
||||
break;;
|
||||
"Init"*)
|
||||
_init
|
||||
break;;
|
||||
@@ -152,6 +155,28 @@ _init_pull() {
|
||||
}
|
||||
|
||||
|
||||
_init_push() {
|
||||
echo -e ""
|
||||
echo -e "Init (Push only)"
|
||||
|
||||
read VAR
|
||||
if [ -z "${VAR}" ]; then
|
||||
VAR="${COMMENT_INIT}"
|
||||
fi
|
||||
|
||||
rm -rf .git
|
||||
|
||||
git init
|
||||
|
||||
_define_files
|
||||
|
||||
git branch -M "${BRANCH}"
|
||||
git remote add origin "${ORIGIN}"
|
||||
|
||||
git push -f -u origin "${BRANCH}"
|
||||
}
|
||||
|
||||
|
||||
##############################################################################################################
|
||||
# Setup/Start
|
||||
|
||||
|
||||
Reference in New Issue
Block a user