Helper scripts for doing things through Forgejo's API. move_issue is a workaround pending https://codeberg.org/forgejo/forgejo/issues/1280
Find a file
2023-10-05 18:19:46 -04:00
.env.example Emerges fully-formed and working thanks to lots of help from Louis and Chris 2023-10-04 13:49:23 -04:00
.gitignore Ignore .env 2023-10-04 15:46:58 -04:00
move_issue.py Do not print unneeded info. 2023-10-04 23:57:08 -04:00
README.md Add readme 2023-10-05 18:19:46 -04:00

Forgejo Helpers

Setup:

git clone https://git.agaric.com/agaric/forgejo_helpers.git
cd forgejo_helpers
cp .env.example .env

Set your instance URL there and your API token (with permission to read and write issues at least).

Move issues

Currently this is the only script:

move_issue.py

Use it by passing in the source owner, the source repository, the issue number, the destination owner, and the destination repository, like so:

python move_issue old-example-org old-example-repo 123 new-example-org new-example-repo

All five parameters are needed, even if it is within the same organization.

It would not be difficult to change it so these could be environment variables so that only the issue need to be passed in, and in would not be hard to allow passing in a list of issues, but this has not been done yet.