Commitfd80777dRecorded20 Mar 2026Repositorysigil-forgejo
Initial sigil-forgejo library
Changed
.gitignore | 1 +
README.md | 50 ++++++++++++++++++++++++++++++++++++++++++++++++++
src/forgejo/repos.sgl | 2 ++
3 files changed, 53 insertions(+)Diff
.gitignoreadded
@@ -0,0 +1 @@
+1
build/README.mdadded
@@ -0,0 +1,50 @@
+1
# sigil-forgejo+2
+3
A [Sigil](https://codeberg.org/sigil/sigil) library for the Forgejo/Codeberg REST API.+4
+5
## Modules+6
+7
| Module | Description |+8
|--------|-------------|+9
| `(forgejo client)` | Shared auth headers, URL construction, HTTP helpers |+10
| `(forgejo repos)` | Get, list, create, delete repositories |+11
| `(forgejo orgs)` | Organization info and repo listing |+12
| `(forgejo topics)` | List, add, replace repository topics |+13
| `(forgejo issues)` | List, create, get, comment on issues |+14
| `(forgejo pulls)` | List, get, create, merge pull requests |+15
| `(forgejo releases)` | List, create releases and upload assets |+16
+17
## Usage+18
+19
Add `sigil-forgejo` as a dependency in your `package.sgl`:+20
+21
```scheme+22
(from-git url: "codeberg:sigil/sigil-forgejo" package: "sigil-forgejo")+23
```+24
+25
Then import the modules you need:+26
+27
```scheme+28
(import (forgejo repos)+29
(forgejo topics))+30
+31
(define base-url "https://codeberg.org")+32
(define token (getenv "FORGEJO_TOKEN"))+33
+34
;; List repos in an org+35
(forgejo-list-org-repos base-url token "sigil")+36
+37
;; Set topics on a repo+38
(forgejo-replace-topics base-url token "sigil" "my-repo"+39
'("library" "sigil"))+40
```+41
+42
## Building+43
+44
```bash+45
sigil build --redirects dev-redirects.sgl+46
```+47
+48
## License+49
+50
BSD-3-Clausesrc/forgejo/repos.sglmodified
@@ -31,6 +31,7 @@
31
(forgejo-api-url base-url "user" "repos") 32
#{ name: name 33
description: description+34
default_branch: "master" 35
auto_init: #t })) 36
37
;;; Create a new repository under an organization.@@ -39,6 +40,7 @@
40
(forgejo-api-url base-url "orgs" org "repos") 41
#{ name: name 42
description: description+43
default_branch: "master" 44
auto_init: #t })) 45
46
;;; Delete a repository.