chore(global): merge branch 'main' of remote into main
Signed-off-by: Andrei Jiroh Eugenio Halili <andreijiroh@madebythepins.tk>
This commit is contained in:
commit
69e8ca2369
|
@ -11,11 +11,11 @@ working at The Pins Team, see [our dotfiles][df-gl].
|
|||
|
||||
```sh
|
||||
## configure required variables
|
||||
export GITLAB_LOGIN=AndreiJirohHaliliDev2006
|
||||
export GITLAB_LOGIN=ajhalili2006
|
||||
export GITLAB_TOKEN=<my-gitlab1dotcom-PAT>
|
||||
|
||||
## Run the bootstrap script
|
||||
$(command -v curl>>/dev/null && echo curl -o- || echo wget -q0-) https://raw.githubusercontent.com/AndreiJirohHaliliDev2006/dotfiles/main/bootstrap | bash -
|
||||
$(command -v curl>>/dev/null && echo curl -o- || echo wget -q0-) https://raw.githubusercontent.com/ajhalili2006/dotfiles/main/bootstrap | bash -
|
||||
|
||||
## Done?
|
||||
unset GITLAB_TOKEN GITLAB_LOGIN
|
||||
|
@ -25,7 +25,7 @@ unset GITLAB_TOKEN GITLAB_LOGIN
|
|||
|
||||
```sh
|
||||
# assuming git is installed
|
||||
git clone https://github.com/AndreiJirohHaliliDev2006/dotfiles $HOME/.dotfiles
|
||||
git clone https://github.com/ajhalili2006/dotfiles $HOME/.dotfiles
|
||||
cd $HOME/.dotfiles
|
||||
|
||||
# no need for exporting my PAT before running this
|
||||
|
|
|
@ -83,7 +83,7 @@ installDeps() {
|
|||
cloneRepo() {
|
||||
if [ ! -d "$HOME/.dotfiles" ]; then
|
||||
echoStageName "Cloning the dotfiles repo"
|
||||
git clone https://github.com/AndreiJirohHaliliDev2006/dotfiles.git $HOME/.dotfiles
|
||||
git clone https://github.com/ajhalili2006/dotfiles.git $HOME/.dotfiles
|
||||
else
|
||||
echoStageName "Dotfiles repo found, pulling remote changes instead"
|
||||
git -C "$HOME/.dotfiles" fetch --all
|
||||
|
@ -94,15 +94,15 @@ cloneRepo() {
|
|||
if [[ $GITLAB_TOKEN == "" ]] && [[ $GITLAB_LOGIN == "" ]] && [ ! -d "$HOME/.dotfiles/secrets" ]; then
|
||||
error "GitLab login and token can't be blank!" && exit 1
|
||||
# Probably change my GitLab SaaS username with yours
|
||||
elif [[ $GITLAB_LOGIN != "AndreiJirohHaliliDev2006" ]] && [ ! -d "$HOME/.dotfiles/secrets" ]; then
|
||||
elif [[ $GITLAB_LOGIN != "ajhalili2006" ]]; then
|
||||
error "Only Andrei Jiroh can do this!" && exit 1
|
||||
elif [[ $GITLAB_LOGIN == "AndreiJirohHaliliDev2006" ]] && [[ $GITLAB_TOKEN == "" ]] && [ ! -d "$HOME/.dotfiles/secrets" ]; then
|
||||
elif [[ $GITLAB_LOGIN == "ajhalili2006" ]] && [[ $GITLAB_TOKEN == "" ]]; then
|
||||
error "Missing GitLab SaaS PAT! Check your Bitwarden vault for that key." && exit 1
|
||||
fi
|
||||
|
||||
if [ ! -d "$HOME/.dotfiles/secrets" ]; then
|
||||
echoStageName "Cloning secrets repo"
|
||||
git clone https://$GITLAB_LOGIN:$GITLAB_TOKEN@gitlab.com/AndreiJirohHaliliDev2006/dotfiles-secrets $HOME/.dotfiles/secrets
|
||||
git clone https://$GITLAB_LOGIN:$GITLAB_TOKEN@gitlab.com/ajhalili2006/dotfiles-secrets $HOME/.dotfiles/secrets
|
||||
[ $? != "0" ] && echo "error: That kinda sus, but either only Andrei Jiroh can proceed or maybe the PAT you used is invalid." && exit 1
|
||||
chmod 600 $HOME/.dotfiles/secrets/{ssh,pgp}
|
||||
sleep 5
|
||||
|
|
Loading…
Reference in New Issue