Finish clone_projects
This commit is contained in:
parent
594d26b80a
commit
7b941b8da1
3 changed files with 32 additions and 29 deletions
|
@ -1,14 +1,19 @@
|
||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
|
|
||||||
## This script clones all the different repos
|
## This script clones all the different repos.
|
||||||
|
|
||||||
set_up_2px_repo() {
|
if [ -z "$BASE_DIR" ]; then
|
||||||
|
echo "BASE_DIR wasn't set."
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
set_up_lime2_repo() {
|
||||||
repo_name="$1"
|
repo_name="$1"
|
||||||
folder="$2"
|
folder="$2"
|
||||||
echo "Setting up $repo_name..."
|
echo "Setting up $repo_name..."
|
||||||
if [ -e ~/"$folder""$repo_name" ]; then
|
if [ -e ~/"$folder"/"$repo_name" ]; then
|
||||||
echo "${GREEN}$repo_name is already there, updating...${NC}"
|
echo "${GREEN}$repo_name is already there, updating...${NC}"
|
||||||
cd ~/"$folder""$repo_name" && git pull
|
cd ~/"$folder"/"$repo_name" && git pull
|
||||||
else
|
else
|
||||||
echo "${ORANGE}Cloning new $repo_name...${NC}"
|
echo "${ORANGE}Cloning new $repo_name...${NC}"
|
||||||
cd ~/"$folder" && git clone ssh://flyingscorpio@2px.info.tm/~/repos/"$repo_name".git
|
cd ~/"$folder" && git clone ssh://flyingscorpio@2px.info.tm/~/repos/"$repo_name".git
|
||||||
|
@ -22,9 +27,9 @@ set_up_gitlab_repo() {
|
||||||
repo_name="$2"
|
repo_name="$2"
|
||||||
folder="$3"
|
folder="$3"
|
||||||
echo "Setting up $repo_owner/$repo_name..."
|
echo "Setting up $repo_owner/$repo_name..."
|
||||||
if [ -e ~/"$folder""$repo_name" ]; then
|
if [ -e ~/"$folder"/"$repo_name" ]; then
|
||||||
echo "${GREEN}$repo_name is already there, updating...${NC}"
|
echo "${GREEN}$repo_name is already there, updating...${NC}"
|
||||||
cd ~/"$folder""$repo_name" && git pull
|
cd ~/"$folder"/"$repo_name" && git pull
|
||||||
else
|
else
|
||||||
echo "${ORANGE}Cloning new $repo_name...${NC}"
|
echo "${ORANGE}Cloning new $repo_name...${NC}"
|
||||||
cd ~/"$folder" && git clone https://gitlab.com/"$repo_owner"/"$repo_name".git
|
cd ~/"$folder" && git clone https://gitlab.com/"$repo_owner"/"$repo_name".git
|
||||||
|
@ -39,14 +44,12 @@ echo "Setting up Lessons..."
|
||||||
if [ ! -e ~/Lessons ]; then
|
if [ ! -e ~/Lessons ]; then
|
||||||
mkdir ~/Lessons && echo "${ORANGE}Created ~/Lessons${NC}"
|
mkdir ~/Lessons && echo "${ORANGE}Created ~/Lessons${NC}"
|
||||||
fi
|
fi
|
||||||
set_up_2px_repo 'E2L' 'Lessons/'
|
set_up_lime2_repo 'E2L' 'Lessons'
|
||||||
set_up_2px_repo 'OpenClassrooms' 'Lessons/'
|
set_up_lime2_repo 'OpenClassrooms' 'Lessons'
|
||||||
set_up_2px_repo 'Keepass'
|
set_up_lime2_repo 'Keepass'
|
||||||
set_up_2px_repo 'PersonnalScripts'
|
set_up_lime2_repo 'PersonnalScripts'
|
||||||
set_up_2px_repo 'RootMe'
|
set_up_lime2_repo 'RootMe'
|
||||||
set_up_2px_repo 'SetupCockpit'
|
set_up_lime2_repo 'SetupCockpit'
|
||||||
set_up_2px_repo 'VimConf'
|
|
||||||
cd ~/VimConf && /bin/bash ~/VimConf/update.sh -o
|
|
||||||
|
|
||||||
# }}}
|
# }}}
|
||||||
|
|
||||||
|
@ -56,19 +59,19 @@ if [ ! -e ~/SRC ]; then
|
||||||
mkdir ~/SRC && echo "${ORANGE}Created ~/SRC${NC}"
|
mkdir ~/SRC && echo "${ORANGE}Created ~/SRC${NC}"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
set_up_gitlab_repo 'e2li' 'depydoc' 'SRC/'
|
set_up_gitlab_repo 'e2li' 'depydoc' 'SRC'
|
||||||
set_up_gitlab_repo 'flyingscorpio' 'BlurMySearches' 'SRC/'
|
set_up_gitlab_repo 'flyingscorpio' 'BlurMySearches' 'SRC'
|
||||||
set_up_gitlab_repo 'flyingscorpio' 'JsonToPython' 'SRC/'
|
set_up_gitlab_repo 'flyingscorpio' 'JsonToPython' 'SRC'
|
||||||
set_up_gitlab_repo 'flyingscorpio' 'MarioSokoban' 'SRC/'
|
set_up_gitlab_repo 'flyingscorpio' 'MarioSokoban' 'SRC'
|
||||||
set_up_gitlab_repo 'flyingscorpio' 'PythonLocalBlockchain' 'SRC/'
|
set_up_gitlab_repo 'flyingscorpio' 'PythonLocalBlockchain' 'SRC'
|
||||||
set_up_gitlab_repo 'flyingscorpio' 'Roboc-GUI' 'SRC/'
|
set_up_gitlab_repo 'flyingscorpio' 'Roboc-GUI' 'SRC'
|
||||||
set_up_gitlab_repo 'flyingscorpio' 'Roboc-console' 'SRC/'
|
set_up_gitlab_repo 'flyingscorpio' 'Roboc-console' 'SRC'
|
||||||
set_up_gitlab_repo 'flyingscorpio' 'ScheduleTimer' 'SRC/'
|
set_up_gitlab_repo 'flyingscorpio' 'ScheduleTimer' 'SRC'
|
||||||
set_up_gitlab_repo 'flyingscorpio' 'SudokuSolver' 'SRC/'
|
set_up_gitlab_repo 'flyingscorpio' 'SudokuSolver' 'SRC'
|
||||||
set_up_gitlab_repo 'flyingscorpio' 'TicTacToe' 'SRC/'
|
set_up_gitlab_repo 'flyingscorpio' 'TicTacToe' 'SRC'
|
||||||
set_up_gitlab_repo 'flyingscorpio' 'TorNoVPN' 'SRC/'
|
set_up_gitlab_repo 'flyingscorpio' 'TorNoVPN' 'SRC'
|
||||||
set_up_gitlab_repo 'flyingscorpio' 'WhitespaceInterpreter' 'SRC/'
|
set_up_gitlab_repo 'flyingscorpio' 'WhitespaceInterpreter' 'SRC'
|
||||||
set_up_gitlab_repo 'flyingscorpio' 'WikipediaAcronymScraper' 'SRC/'
|
set_up_gitlab_repo 'flyingscorpio' 'WikipediaAcronymScraper' 'SRC'
|
||||||
|
|
||||||
echo "Setting up 2px..."
|
echo "Setting up 2px..."
|
||||||
if [ -e ~/SRC/2px ]; then
|
if [ -e ~/SRC/2px ]; then
|
||||||
|
|
|
@ -2,7 +2,6 @@
|
||||||
|
|
||||||
## This script is used to visually separate commands in the other scripts
|
## This script is used to visually separate commands in the other scripts
|
||||||
|
|
||||||
|
|
||||||
if [ $? -eq 0 ]; then
|
if [ $? -eq 0 ]; then
|
||||||
echo -n "${GREEN}"
|
echo -n "${GREEN}"
|
||||||
else
|
else
|
||||||
|
|
|
@ -1,10 +1,11 @@
|
||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
|
|
||||||
|
## This script takes care of the vim configuration.
|
||||||
|
|
||||||
if [ -z "$BASE_DIR" ]; then
|
if [ -z "$BASE_DIR" ]; then
|
||||||
echo "BASE_DIR wasn't set."
|
echo "BASE_DIR wasn't set."
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
echo "$BASE_DIR"
|
|
||||||
|
|
||||||
# HANDLE ARGS {{{
|
# HANDLE ARGS {{{
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue