From 52c86cd76ef666ae6b0ec5c275e4b6ece5a14462 Mon Sep 17 00:00:00 2001 From: Julian Lechner Date: Tue, 21 Jul 2026 13:39:44 +0200 Subject: [PATCH] chore: update issue templates and workflow files for Gitea compatibility --- .gitea/FUNDING.yml | 15 ---------- .gitea/ISSUE_TEMPLATE/bug.yaml | 2 +- .gitea/ISSUE_TEMPLATE/feature.yaml | 2 +- .gitea/ISSUE_TEMPLATE/improvement.yaml | 2 +- .gitea/ISSUE_TEMPLATE/request.yaml | 2 +- .gitea/ISSUE_TEMPLATE/story.yaml | 2 +- .gitea/dependabot.yml | 11 ------- .gitea/workflows/Build-Rollout.yml | 41 +++++++++++++------------- .gitea/workflows/Build-Validation.yml | 4 +-- README.md | 4 +-- package.json | 4 +-- 11 files changed, 32 insertions(+), 57 deletions(-) delete mode 100644 .gitea/FUNDING.yml delete mode 100644 .gitea/dependabot.yml diff --git a/.gitea/FUNDING.yml b/.gitea/FUNDING.yml deleted file mode 100644 index 78c779e..0000000 --- a/.gitea/FUNDING.yml +++ /dev/null @@ -1,15 +0,0 @@ -# These are supported funding model platforms - -github: # Replace with up to 4 GitHub Sponsors-enabled usernames e.g., [user1, user2] -patreon: # Replace with a single Patreon username -open_collective: # Replace with a single Open Collective username -ko_fi: FrauJulian -tidelift: # Replace with a single Tidelift platform-name/package-name e.g., npm/babel -community_bridge: # Replace with a single Community Bridge project-name e.g., cloud-foundry -liberapay: # Replace with a single Liberapay username -issuehunt: # Replace with a single IssueHunt username -lfx_crowdfunding: # Replace with a single LFX Crowdfunding project-name e.g., cloud-foundry -polar: # Replace with a single Polar username -buy_me_a_coffee: # Replace with a single Buy Me a Coffee username -thanks_dev: # Replace with a single thanks.dev username -custom: # Replace with up to 4 custom sponsorship URLs e.g., ['link1', 'link2'] diff --git a/.gitea/ISSUE_TEMPLATE/bug.yaml b/.gitea/ISSUE_TEMPLATE/bug.yaml index c5c4a3f..71408dd 100644 --- a/.gitea/ISSUE_TEMPLATE/bug.yaml +++ b/.gitea/ISSUE_TEMPLATE/bug.yaml @@ -1,5 +1,5 @@ name: 🐛 Bug -description: Report a bug or unexpected behavior +about: Report a bug or unexpected behavior title: '🐛 [BUG]: ' body: - type: textarea diff --git a/.gitea/ISSUE_TEMPLATE/feature.yaml b/.gitea/ISSUE_TEMPLATE/feature.yaml index 583a271..374fa8a 100644 --- a/.gitea/ISSUE_TEMPLATE/feature.yaml +++ b/.gitea/ISSUE_TEMPLATE/feature.yaml @@ -1,5 +1,5 @@ name: 💡 Enhancement -description: Suggest a new feature +about: Suggest a new feature title: '💡 [Enhancement]: ' body: - type: textarea diff --git a/.gitea/ISSUE_TEMPLATE/improvement.yaml b/.gitea/ISSUE_TEMPLATE/improvement.yaml index 871d147..f290570 100644 --- a/.gitea/ISSUE_TEMPLATE/improvement.yaml +++ b/.gitea/ISSUE_TEMPLATE/improvement.yaml @@ -1,5 +1,5 @@ name: ⚙️ Improvement -description: Suggest an improvement to existing functionality +about: Suggest an improvement to existing functionality title: '⚙️ [Improvement]: ' body: - type: textarea diff --git a/.gitea/ISSUE_TEMPLATE/request.yaml b/.gitea/ISSUE_TEMPLATE/request.yaml index ddc81ae..83def3c 100644 --- a/.gitea/ISSUE_TEMPLATE/request.yaml +++ b/.gitea/ISSUE_TEMPLATE/request.yaml @@ -1,5 +1,5 @@ name: 📝 Service Request -description: Request a service or support task +about: Request a service or support task title: '📝 [Service Request]: ' body: - type: textarea diff --git a/.gitea/ISSUE_TEMPLATE/story.yaml b/.gitea/ISSUE_TEMPLATE/story.yaml index 3335fcf..7c24222 100644 --- a/.gitea/ISSUE_TEMPLATE/story.yaml +++ b/.gitea/ISSUE_TEMPLATE/story.yaml @@ -1,5 +1,5 @@ name: 👮 Story -description: Describe a user story +about: Describe a user story title: '👮 [Story]: ' body: - type: textarea diff --git a/.gitea/dependabot.yml b/.gitea/dependabot.yml deleted file mode 100644 index 1badd25..0000000 --- a/.gitea/dependabot.yml +++ /dev/null @@ -1,11 +0,0 @@ -# To get started with Dependabot version updates, you'll need to specify which -# package ecosystems to update and where the package manifests are located. -# Please see the documentation for all configuration options: -# https://docs.github.com/code-security/dependabot/dependabot-version-updates/configuration-options-for-the-dependabot.yml-file - -version: 2 -updates: - - package-ecosystem: 'npm' # See documentation for possible values - directory: '/' # Location of package manifests - schedule: - interval: 'daily' diff --git a/.gitea/workflows/Build-Rollout.yml b/.gitea/workflows/Build-Rollout.yml index 37a4aef..7534e25 100644 --- a/.gitea/workflows/Build-Rollout.yml +++ b/.gitea/workflows/Build-Rollout.yml @@ -3,9 +3,6 @@ name: Release and Deploy Build on: workflow_dispatch: -permissions: - contents: write - env: VERSION_MAJOR: '1' VERSION_MINOR: '1' @@ -16,17 +13,16 @@ jobs: steps: - name: Checkout Repository - uses: actions/checkout@v4 + uses: https://gitea.com/actions/checkout@v4 with: fetch-depth: 0 fetch-tags: true - name: Use NodeJS v22.22.3 - uses: actions/setup-node@v6 + uses: https://gitea.com/actions/setup-node@v4 with: node-version: '22.22.3' registry-url: 'https://registry.npmjs.org' - package-manager-cache: false - name: Install Dependencies run: npm ci @@ -39,7 +35,7 @@ jobs: id: release_version run: | package_version="$(node -p "require('./package.json').version")" - echo "tag=${package_version}" >> "$GITHUB_OUTPUT" + echo "tag=${package_version}" >> "$GITEA_OUTPUT" - name: Run Build run: npm run build @@ -49,24 +45,23 @@ jobs: env: NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }} - - name: Create GitHub release + - name: Create Gitea Release env: - GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} + GITEA_TOKEN: ${{ secrets.GITEA_TOKEN }} + GITEA_REPOSITORY: ${{ gitea.repository }} + GITEA_SERVER_URL: ${{ gitea.server_url }} + GITEA_SHA: ${{ gitea.sha }} RELEASE_TAG: v${{ steps.release_version.outputs.tag }} run: | git fetch --force --tags - previous_tag="$(gh api repos/${{ github.repository }}/releases --paginate --jq '.[] | select(.draft == false) | .tag_name' | grep -Fxv "$RELEASE_TAG" | head -n 1 || true)" + previous_tag="$(git describe --tags --abbrev=0 "$GITEA_SHA^" 2>/dev/null || true)" if [ -n "$previous_tag" ]; then - if git rev-parse --verify --quiet "${previous_tag}^{commit}" >/dev/null; then - commit_messages="$(git log --reverse --format='- %s' "${previous_tag}..${GITHUB_SHA}")" - else - commit_messages="$(git log --reverse --format='- %s' "${GITHUB_SHA}")" - fi - full_changelog="https://github.com/${{ github.repository }}/compare/${previous_tag}...${RELEASE_TAG}" + commit_messages="$(git log --reverse --format='- %s' "${previous_tag}..${GITEA_SHA}")" + full_changelog="${GITEA_SERVER_URL}/${GITEA_REPOSITORY}/compare/${previous_tag}...${RELEASE_TAG}" else - commit_messages="$(git log --reverse --format='- %s' "${GITHUB_SHA}")" + commit_messages="$(git log --reverse --format='- %s' "${GITEA_SHA}")" full_changelog="" fi @@ -84,8 +79,14 @@ jobs: fi } > release-notes.md - if gh release view "$RELEASE_TAG" >/dev/null 2>&1; then - gh release edit "$RELEASE_TAG" --title "$RELEASE_TAG" --notes-file release-notes.md + node -e 'const fs = require("node:fs"); fs.writeFileSync("release.json", JSON.stringify({ tag_name: process.env.RELEASE_TAG, target_commitish: process.env.GITEA_SHA, name: process.env.RELEASE_TAG, body: fs.readFileSync("release-notes.md", "utf8") }))' + + api_url="${GITEA_SERVER_URL}/api/v1/repos/${GITEA_REPOSITORY}/releases" + auth_header="Authorization: token ${GITEA_TOKEN}" + + if curl --fail --silent --header "$auth_header" --output current-release.json "${api_url}/tags/${RELEASE_TAG}"; then + release_id="$(node -p 'require("./current-release.json").id')" + curl --fail-with-body --header "$auth_header" --header 'Content-Type: application/json' --request PATCH --data-binary @release.json "${api_url}/${release_id}" else - gh release create "$RELEASE_TAG" --target "${GITHUB_SHA}" --title "$RELEASE_TAG" --notes-file release-notes.md + curl --fail-with-body --header "$auth_header" --header 'Content-Type: application/json' --request POST --data-binary @release.json "$api_url" fi diff --git a/.gitea/workflows/Build-Validation.yml b/.gitea/workflows/Build-Validation.yml index 5cbc41f..dddbb35 100644 --- a/.gitea/workflows/Build-Validation.yml +++ b/.gitea/workflows/Build-Validation.yml @@ -13,10 +13,10 @@ jobs: runs-on: ubuntu-latest steps: - name: Checkout Repository - uses: actions/checkout@v4 + uses: https://gitea.com/actions/checkout@v4 - name: use NodeJS v22.22.3 - uses: actions/setup-node@v4 + uses: https://gitea.com/actions/setup-node@v4 with: node-version: '22.22.3' diff --git a/README.md b/README.md index eeee6fd..4fd741b 100644 --- a/README.md +++ b/README.md @@ -13,7 +13,7 @@ reused. ## Support -Create an [issue](https://github.com/FrauJulian/Discord-Audio-Stream/issues) on GitHub or contact +Create an [issue](https://git.lechner-systems.at/fraujulian/Discord-Audio-Stream/issues) on GitHub or contact [`fraujulian`](https://discord.com/users/860206216893693973) on Discord. ## Installation @@ -204,4 +204,4 @@ npm run build ## Enjoy the package? -Give it a star on [GitHub](https://github.com/FrauJulian/discord-audio-stream)! +Give it a star on [Gitea](https://git.lechner-systems.at/fraujulian/Discord-Audio-Stream)! diff --git a/package.json b/package.json index ea7247d..b534e26 100644 --- a/package.json +++ b/package.json @@ -43,9 +43,9 @@ }, "repository": { "type": "git", - "url": "git+https://github.com/FrauJulian/Discord-Audio-Stream.git" + "url": "https://git.lechner-systems.at/fraujulian/Discord-Audio-Stream.git" }, - "bugs": "https://github.com/FrauJulian/Discord-Audio-Stream/issues", + "bugs": "https://git.lechner-systems.at/fraujulian/Discord-Audio-Stream/issues", "funding": "https://ko-fi.com/FrauJulian", "keywords": [ "discord",