| LICENSES | ||
| nix | ||
| .git-blame-ignore-revs | ||
| flake.lock | ||
| flake.lock.license | ||
| flake.nix | ||
| giveupgithub.sh | ||
| README.md | ||
| README.template.md | ||
Give Up GitHub (The Musical The Script)
If you have a lot of projects to update on Github, this script may be useful.
(See Software Freedom Conservancy's Give Up GitHub site for details.)
Usage
Read and understand the script before running it. You may need to
edit it or the template README.template.md
to suit your needs.
Environment variables
| Variable | Default | Purpose |
|---|---|---|
SRCACCT |
librecast |
The source account or org on GitHub |
SRCHOST |
github.com |
gist.github.com triggers Gist support |
DSTACCT |
librecast |
The destination account or org on the target host |
DSTHOST |
codeberg.org |
The destination host |
DSTFORGE |
derived from $DSTHOST |
A friendly name of the destination host |
GITHUB_TOKEN |
Result of gh auth token |
A GitHub token to set the repository archive flag |
What it does
- Unarchive the repository on GitHub, in case previously archived
- Generates the
README.mdfrom the template and environment - Replaces the head of the default branch with just the
README.md - Pushes the commit to GitHub
- Sets the description to
$DSTFORGE - Sets the homepage to the new git repository1
- Archives the repository on GitHub
Comparison to original
This is a fork of a "quick hack" to move Librecast's projects.
That Librecast version removes all branches and tags, leaving just the single commit. That is a more forceful protest2, but also more harmful to your dependents' builds. The correct trade-off is up to you, and may even vary by repository.
The Librecast version does not alter the archive status of the repository.
This version floats a smaller version of the logo, to keep more focus on the text. The same trick does not appear to work on Forgejo.
This version supports Gists.
License
The work as a whole is licensed =GPL-3.0-only=. Some components are licensed more permissively, as marked.