Skip to content

Commit

Permalink
Adding save-code.sh
Browse files Browse the repository at this point in the history
to store into my other Git hosting account 馃槂
  • Loading branch information
pH-7 committed Oct 9, 2021
1 parent 6878f36 commit 4a6459d
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 0 deletions.
1 change: 1 addition & 0 deletions .gitattributes
Expand Up @@ -2,3 +2,4 @@
.gitattributes export-ignore
.gitignore export-ignore
phpunit.xml.dist export-ignore
save-code.sh export-ignore
18 changes: 18 additions & 0 deletions save-code.sh
@@ -0,0 +1,18 @@
#!/bin/bash

# Save a git project to a specific repo (e.g. github, bitbucket, ...)
function save-project-to-repo() {
git remote rm origin
git remote add origin $1
git push
}

declare readonly gitRemotes=(
git remote add origin git@bitbucket.org:pH_7/just-http-status-codes.git
git@gitlab.com:pH-7/just-http-status-codes.git
git@github.com:pH-7/JustHttpStatusCodes.git
)
for remote in "${gitRemotes[@]}"
do
save-project-to-repo $remote
done

0 comments on commit 4a6459d

Please sign in to comment.