Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add gitea / forgejo support #28

Merged
merged 34 commits into from
Sep 26, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
34 commits
Select commit Hold shift + click to select a range
9be7bda
add gitea
anbraten Oct 24, 2023
2b3598b
update config
anbraten Oct 24, 2023
f0095a1
add github
anbraten Oct 24, 2023
71c29c1
Merge branch 'main' into gitea
6543 May 3, 2024
d4360f9
rm conflict-resolve relict
6543 May 3, 2024
74641ca
dedup code
6543 May 3, 2024
d401ccc
update deps
6543 May 3, 2024
8274b9f
update
anbraten May 30, 2024
657c6cd
Merge remote-tracking branch 'origin/main' into gitea
anbraten May 30, 2024
035ebde
Merge remote-tracking branch 'origin/main' into gitea
anbraten Jul 15, 2024
b29604a
default CI_FORGE_URL
anbraten Jul 16, 2024
8bfd52b
add forgejo
anbraten Jul 16, 2024
8d0f165
fix msg
anbraten Jul 16, 2024
98f587d
Merge remote-tracking branch 'origin/main' into gitea
anbraten Jul 17, 2024
2df6306
add git lfs
anbraten Jul 17, 2024
cce4fb9
enhance error handling
anbraten Jul 17, 2024
dbeff87
Merge branch 'main' into gitea
6543 Sep 9, 2024
5aa6eef
undo unrelated package upgrades
6543 Sep 9, 2024
5f109e2
use env from https://github.com/woodpecker-ci/plugin-ready-release-go…
6543 Sep 9, 2024
f67ed7e
Merge branch 'main' into gitea
6543 Sep 9, 2024
3987a00
clean changes that where moved into own pulls
6543 Sep 9, 2024
c790998
unified forge config
6543 Sep 9, 2024
bf882cb
update err msg
6543 Sep 9, 2024
60d2a11
fmt
6543 Sep 9, 2024
3b36a26
Merge branch 'main' into gitea
6543 Sep 9, 2024
596450a
Merge branch 'main' into gitea
anbraten Sep 10, 2024
fae7e55
Update README.md
anbraten Sep 10, 2024
9721cea
clarify forgejo
6543 Sep 11, 2024
4104816
merge main
pat-s Sep 25, 2024
2c9e7af
fix release api endpoint
pat-s Sep 25, 2024
3efe160
Update src/forges/gitea.ts
pat-s Sep 25, 2024
11dbbbf
Merge remote-tracking branch 'origin/main' into gitea
anbraten Sep 26, 2024
abf4c6e
undo debug
anbraten Sep 26, 2024
96ee084
adjust docs
anbraten Sep 26, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions .prettierrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
{
"semi": true,
"trailingComma": "all",
"singleQuote": true,
"printWidth": 120,
"tabWidth": 2,
"endOfLine": "lf"
}
9 changes: 5 additions & 4 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -4,15 +4,16 @@ WORKDIR /app

ENV NODE_ENV=production

COPY ["package.json", "pnpm-lock.yaml", "./"]
COPY ["tsconfig.json", "./"]
COPY ["src", "./src"]

RUN apt update \
&& apt install -y git git-lfs wget \
&& apt-get clean \
&& rm -rf /var/lib/apt/lists/*
RUN corepack enable

COPY ["package.json", "pnpm-lock.yaml", "./"]
RUN pnpm install --frozen-lockfile

COPY ["tsconfig.json", "./"]
COPY ["src", "./src"]

CMD ["/app/node_modules/.bin/tsx", "/app/src/run.ts"]
5 changes: 4 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -66,8 +66,11 @@ export default {
- [x] Support first release (no previous tags)
- [x] Support defining next version manually (can be done by changing the version on the release pull-request title / commit message)
- [ ] Support more forges:
- [ ] Gitea
- [x] Github
- [x] Gitea
anbraten marked this conversation as resolved.
Show resolved Hide resolved
- [x] Forgejo _(via gitea api client)_
- [ ] Gitlab
- [ ] Bitbucket

## Credits

Expand Down
4 changes: 3 additions & 1 deletion docs.md
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,9 @@ There are two parts to configure the plugin:

| Settings | Default | Description |
| ---------------------------- | ---------------------- | ------------------------------------------------- |
| `GITHUB_TOKEN` | _none_ | The GitHub token to use for the GitHub API |
| `FORGE_TYPE` | CI_FORGE_TYPE | The forge type we connect to (github, gitea, ...) |
| `FORGE_URL` | CI_FORGE_URL | The url of the forge |
| `FORGE_TOKEN` | _none_ | The token to connect to the forge |
| `GIT_EMAIL` | _none_ | The email to use for git commits |
| `RELEASE_BRANCH` | CI_REPO_DEFAULT_BRANCH | The branch used to merge the changelog to |
| `PULL_REQUEST_BRANCH_PREFIX` | `next-release/` | The prefix used for release pull-request branches |
Expand Down
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
"dependencies": {
"@octokit/rest": "^21.0.0",
"execa": "^9.0.0",
"gitea-js": "^1.22.0",
"picocolors": "^1.0.0",
"semver": "^7.5.3",
"shelljs": "^0.8.5",
Expand Down
Loading