mirror of https://github.com/gitsnub/gitsnub.git
script added, README expanded
This commit is contained in:
parent
2e85759c3c
commit
651e51dc65
|
@ -33,6 +33,8 @@ So, I guess this is fine:
|
||||||
- https://github.com/microsoft/MLOS/blob/e4b537d25a5bfdea3bb0f2910b5b404b3d4de7db/GITHUB_IS_EVIL.md
|
- https://github.com/microsoft/MLOS/blob/e4b537d25a5bfdea3bb0f2910b5b404b3d4de7db/GITHUB_IS_EVIL.md
|
||||||
- https://github.com/github/training-kit/blob/7fdaaf1b4deed2689669e16959625c9be9485ace/GITHUB_IS_EVIL.md
|
- https://github.com/github/training-kit/blob/7fdaaf1b4deed2689669e16959625c9be9485ace/GITHUB_IS_EVIL.md
|
||||||
- https://github.com/microsoft/TypeScript/blob/a8fcd50d4ccff302b8175275230b05b252d3a1b4/GITHUB_IS_EVIL.md
|
- https://github.com/microsoft/TypeScript/blob/a8fcd50d4ccff302b8175275230b05b252d3a1b4/GITHUB_IS_EVIL.md
|
||||||
|
- https://github.com/microsoft/terminal/blob/9bd080ddbbfffd03925b9625ae534fe214283b11/GITHUB_IS_EVIL.md
|
||||||
|
- https://github.com/github/VisualStudio/blob/adb9631620d67164c429cf59b023863c7b21b423/GITHUB_IS_EVIL.md
|
||||||
|
|
||||||
|
|
||||||
## Better alternatives
|
## Better alternatives
|
||||||
|
@ -42,3 +44,10 @@ More importantly, stop using Microsoft GitHub. There are many alternatives, here
|
||||||
- [SourceHut](https://sr.ht/) is a nice, ethical forge.
|
- [SourceHut](https://sr.ht/) is a nice, ethical forge.
|
||||||
- [GitLab](https://gitlab.com/) is a good "batteries-included" alternative; it is self-hostable, or you can set-up an account on one of the many public instances.
|
- [GitLab](https://gitlab.com/) is a good "batteries-included" alternative; it is self-hostable, or you can set-up an account on one of the many public instances.
|
||||||
- [Gitea](https://gitea.io/en-us/) is a minimalistic self-hostable forge.
|
- [Gitea](https://gitea.io/en-us/) is a minimalistic self-hostable forge.
|
||||||
|
|
||||||
|
## GitSnub
|
||||||
|
|
||||||
|
GitSnub is here:
|
||||||
|
- https://fosstodon.org/@gitsnub
|
||||||
|
- https://github.com/gitsnub/gitsnub/
|
||||||
|
- repo outside of GitHub coming next
|
||||||
|
|
|
@ -0,0 +1,44 @@
|
||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
# this code is horrid.
|
||||||
|
|
||||||
|
set -e
|
||||||
|
|
||||||
|
if [[ "$GITHUB_TOKEN" == '' ]]; then
|
||||||
|
echo "GITHUB_TOKEN seems empty"
|
||||||
|
echo "You can generate one here: https://github.com/settings/tokens"
|
||||||
|
echo
|
||||||
|
echo "Once you have it, do:"
|
||||||
|
echo "export GITHUB_TOKEN=<token>"
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [[ "$1" == "" ]] || [[ "$1" == "--help" ]]; then
|
||||||
|
echo
|
||||||
|
echo "usage:"
|
||||||
|
echo " $0 someorg/project otherorg/project ..."
|
||||||
|
exit 0
|
||||||
|
fi
|
||||||
|
|
||||||
|
COMMIT_HASH_URLS=""
|
||||||
|
|
||||||
|
for p in "$@"; do
|
||||||
|
echo "+-- forking: $p"
|
||||||
|
gh repo fork "$p" --clone=true
|
||||||
|
done
|
||||||
|
|
||||||
|
for d in */; do
|
||||||
|
cp README.md $d/GITHUB_IS_EVIL.md
|
||||||
|
cd $d/
|
||||||
|
git add ./
|
||||||
|
sed -i -r -e "s#url = https://github#url = https://x-access-token:$GITHUB_TOKEN@github#" .git/config
|
||||||
|
git commit -m '#Hacktoberfest'
|
||||||
|
git push
|
||||||
|
COMMIT_HASH_URLS="$COMMIT_HASH_URLS
|
||||||
|
$(git remote get-url upstream | sed -r -e 's/x-access.+\@//' -r -e 's#\.git#/blob/#' | tr -d '\n'; git rev-parse HEAD | tr -d '\n' )/GITHUB_IS_EVIL.md"
|
||||||
|
cd ../
|
||||||
|
done
|
||||||
|
|
||||||
|
echo
|
||||||
|
echo
|
||||||
|
echo "$COMMIT_HASH_URLS"
|
Loading…
Reference in New Issue