mirror of
https://github.com/revanced/revanced-releases-api.git
synced 2025-04-30 14:34:28 +02:00
feat: semantic release
This commit is contained in:
parent
502b87387e
commit
67f848245b
15
.github/workflows/main.yml
vendored
15
.github/workflows/main.yml
vendored
@ -54,7 +54,7 @@ jobs:
|
||||
latest=${{ startsWith(github.ref, 'refs/heads/main') }}
|
||||
suffix=-${{ github.sha }}
|
||||
|
||||
- name: Build and push Docker image
|
||||
- name: Build Docker image
|
||||
id: build
|
||||
uses: docker/build-push-action@v2
|
||||
with:
|
||||
@ -62,6 +62,17 @@ jobs:
|
||||
context: .
|
||||
file: ./Dockerfile
|
||||
platforms: linux/amd64,linux/arm64/v8
|
||||
push: true
|
||||
push: false
|
||||
tags: ${{ steps.meta.outputs.tags }}
|
||||
labels: ${{ steps.meta.outputs.labels }}
|
||||
|
||||
- name: Push Docker image
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
run: ./gradlew build
|
||||
- name: Setup semantic-release
|
||||
run: npm install -g semantic-release @semantic-release/git @semantic-release/changelog @codedependant/semantic-release-docker -D
|
||||
- name: Release
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
run: npx semantic-release
|
20
.releaserc
Normal file
20
.releaserc
Normal file
@ -0,0 +1,20 @@
|
||||
{
|
||||
"branches": [
|
||||
"main",
|
||||
{
|
||||
"name": "dev",
|
||||
"prerelease": true
|
||||
}
|
||||
],
|
||||
"plugins": [
|
||||
["@semantic-release/commit-analyzer", {
|
||||
"releaseRules": [
|
||||
{"type": "build", "release": "patch"}
|
||||
]
|
||||
}],
|
||||
"@semantic-release/release-notes-generator",
|
||||
"@semantic-release/changelog",
|
||||
"@semantic-release/github",
|
||||
"@codedependant/semantic-release-docker"
|
||||
]
|
||||
}
|
20
release.package.js
Normal file
20
release.package.js
Normal file
@ -0,0 +1,20 @@
|
||||
module.exports = {
|
||||
branches: ["main"],
|
||||
plugins: [
|
||||
[
|
||||
"@codedependant/semantic-release-docker",
|
||||
{
|
||||
dockerTags: [process.env.IMAGE_TAG],
|
||||
dockerImage: process.env.IMAGE_NAME,
|
||||
dockerFile: "Dockerfile",
|
||||
dockerRegistry: "ghcr.io",
|
||||
dockerProject: "codedependant",
|
||||
dockerArgs: {
|
||||
API_TOKEN: true,
|
||||
RELEASE_DATE: new Date().toISOString(),
|
||||
RELEASE_VERSION: "{{next.version}}",
|
||||
},
|
||||
},
|
||||
],
|
||||
],
|
||||
};
|
Loading…
x
Reference in New Issue
Block a user