-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Gy0m
committed
Jul 20, 2023
0 parents
commit 356fdec
Showing
35 changed files
with
259 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
# ArchLife_repo | ||
My personal repo |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,58 @@ | ||
#!/bin/bash | ||
#set -e | ||
################################################################################################################## | ||
# ______ ____ | ||
# / ____/__ __ / __ \ ____ ___ | ||
# / / __ / / / // / / // __ `__ \ | ||
# / /_/ // /_/ // /_/ // / / / / / | ||
# \____/ \__, / \____//_/ /_/ /_/ | ||
# /____/ | ||
# | ||
################################################################################################################## | ||
#tput setaf 0 = black | ||
#tput setaf 1 = red | ||
#tput setaf 2 = green | ||
#tput setaf 3 = yellow | ||
#tput setaf 4 = dark blue | ||
#tput setaf 5 = purple | ||
#tput setaf 6 = cyan | ||
#tput setaf 7 = gray | ||
#tput setaf 8 = light blue | ||
################################################################################################################## | ||
|
||
|
||
# checking if i have the latest files from github | ||
echo "checking for newer files online firt" | ||
git pull | ||
|
||
# Below command will backup everything inside the project folder | ||
git add . | ||
|
||
# Give a comment to the commit if you want | ||
echo | ||
tput setaf 3 | ||
echo "####################################" | ||
echo "Write your commit comment!" | ||
echo "####################################" | ||
tput sgr0 | ||
echo | ||
|
||
|
||
read input | ||
|
||
# Committing to the local repository with a message containing the time details and commit text | ||
|
||
git commit -m "$input" | ||
|
||
# Push the local files to github | ||
|
||
git push -u origin main | ||
#git push -u origin master | ||
|
||
echo | ||
tput setaf 2 | ||
echo "################################################################" | ||
echo "################### Git Push Done ######################" | ||
echo "################################################################" | ||
tput sgr0 | ||
echo |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
#!/bin/bash | ||
#set -e | ||
################################################################################################################## | ||
# ______ ____ | ||
# / ____/__ __ / __ \ ____ ___ | ||
# / / __ / / / // / / // __ `__ \ | ||
# / /_/ // /_/ // /_/ // / / / / / | ||
# \____/ \__, / \____//_/ /_/ /_/ | ||
# /____/ | ||
# | ||
################################################################################################################## | ||
#tput setaf 0 = black | ||
#tput setaf 1 = red | ||
#tput setaf 2 = green | ||
#tput setaf 3 = yellow | ||
#tput setaf 4 = dark blue | ||
#tput setaf 5 = purple | ||
#tput setaf 6 = cyan | ||
#tput setaf 7 = gray | ||
#tput setaf 8 = light blue | ||
################################################################################################################## | ||
|
||
|
||
|
||
mv .git/config config | ||
|
||
rm -rf .git | ||
|
||
sh ./git_init* | ||
|
||
mv config .git/config | ||
|
||
git add --all . | ||
|
||
git commit -m "cleanup" | ||
|
||
git push origin main --force | ||
|
||
|
||
echo | ||
tput setaf 3 | ||
echo "######################################" | ||
echo "########## Cleanup Done #############" | ||
echo "######################################" | ||
tput sgr0 | ||
echo |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,75 @@ | ||
#!/bin/bash | ||
#set -e | ||
################################################################################################################## | ||
# ______ ____ | ||
# / ____/__ __ / __ \ ____ ___ | ||
# / / __ / / / // / / // __ `__ \ | ||
# / /_/ // /_/ // /_/ // / / / / / | ||
# \____/ \__, / \____//_/ /_/ /_/ | ||
# /____/ | ||
# | ||
################################################################################################################## | ||
#tput setaf 0 = black | ||
#tput setaf 1 = red | ||
#tput setaf 2 = green | ||
#tput setaf 3 = yellow | ||
#tput setaf 4 = dark blue | ||
#tput setaf 5 = purple | ||
#tput setaf 6 = cyan | ||
#tput setaf 7 = gray | ||
#tput setaf 8 = light blue | ||
################################################################################################################## | ||
|
||
echo | ||
tput setaf 3 | ||
echo "################################################################" | ||
echo "################### Start" | ||
echo "################################################################" | ||
tput sgr0 | ||
echo | ||
|
||
# Problem solving commands | ||
|
||
# Read before using it. | ||
# https://www.atlassian.com/git/tutorials/undoing-changes/git-reset | ||
# git reset --hard orgin/master | ||
# ONLY if you are very sure and no coworkers are on your github. | ||
|
||
# Command that have helped in the past | ||
# Force git to overwrite local files on pull - no merge | ||
# git fetch all | ||
# git push --set-upstream origin master | ||
# git reset --hard orgin/master | ||
|
||
|
||
#setting up git | ||
#https://www.atlassian.com/git/tutorials/setting-up-a-repository/git-config | ||
#https://medium.com/clarusway/how-to-use-git-github-without-asking-for-authentication-always-passwordless-usage-of-private-git-8c32489bc2e9 | ||
#https://blog.nillsf.com/index.php/2021/05/27/github-sso-using-password-protected-ssh-keys | ||
|
||
project=$(basename `pwd`) | ||
echo "-----------------------------------------------------------------------------" | ||
echo "this is project https://github.com/Gy0m/$project" | ||
echo "-----------------------------------------------------------------------------" | ||
|
||
git init | ||
git config --global pull.rebase false | ||
git config --global push.default simple | ||
git config --global user.name "Gy0m" | ||
git config --global user.email "[email protected]" | ||
git config --global core.editor lvim | ||
# #git config --global credential.helper cache | ||
# #git config --global credential.helper 'cache --timeout=32000' | ||
git config --global push.default simple | ||
git config --global init.defaultBranch main | ||
|
||
|
||
git remote set-url origin [email protected]:Gy0m/$project | ||
|
||
echo | ||
tput setaf 2 | ||
echo "################################################################" | ||
echo "################### End" | ||
echo "################################################################" | ||
tput sgr0 | ||
echo |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,65 @@ | ||
#!/bin/bash | ||
#set -e | ||
################################################################################################################## | ||
# ______ ____ | ||
# / ____/__ __ / __ \ ____ ___ | ||
# / / __ / / / // / / // __ `__ \ | ||
# / /_/ // /_/ // /_/ // / / / / / | ||
# \____/ \__, / \____//_/ /_/ /_/ | ||
# /____/ | ||
# | ||
################################################################################################################## | ||
#tput setaf 0 = black | ||
#tput setaf 1 = red | ||
#tput setaf 2 = green | ||
#tput setaf 3 = yellow | ||
#tput setaf 4 = dark blue | ||
#tput setaf 5 = purple | ||
#tput setaf 6 = cyan | ||
#tput setaf 7 = gray | ||
#tput setaf 8 = light blue | ||
################################################################################################################## | ||
|
||
# Creating the databases | ||
cd x86_64 | ||
sh update_repo.sh | ||
|
||
# checking if i have the latest files from github | ||
cd .. | ||
|
||
echo "checking for newer files online firt" | ||
git pull | ||
|
||
# Below command will backup everything inside the project folder | ||
git add . | ||
|
||
# Give a comment to the commit if you want | ||
|
||
echo | ||
tput setaf 3 | ||
echo "####################################" | ||
echo "Write your commit comment!" | ||
echo "####################################" | ||
tput sgr0 | ||
echo | ||
|
||
|
||
#read input | ||
input="update PKGS" | ||
|
||
# Committing to the local repository with a message containing the time details and commit text | ||
|
||
git commit -m "$input" | ||
|
||
# Push the local files to github | ||
|
||
git push -u origin main | ||
|
||
|
||
echo | ||
tput setaf 3 | ||
echo "################################################################" | ||
echo "################### Git Push Done ######################" | ||
echo "################################################################" | ||
tput sgr0 | ||
echo |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
ArchLife_repo.db.tar.gz |
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
ArchLife_repo.files.tar.gz |
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
#!/bin/bash | ||
|
||
rm ArchLife_repo* | ||
|
||
echo "repo-add" | ||
repo-add -n -R ArchLife_repo.db.tar.gz *.pkg.tar.zst | ||
sleep 5 | ||
|
||
echo "####################################" | ||
echo "Repo Updated!!" | ||
echo "####################################" |
Binary file not shown.