Skip to content

Commit 83f3287

Browse files
authored
Merge pull request #867 from marle3003/develop
Develop
2 parents 9350210 + c3852c4 commit 83f3287

46 files changed

Lines changed: 715 additions & 529 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.github/actions/build-alpha-release-notes/action.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,12 +27,12 @@ runs:
2727
git log "${{ inputs.latest-tag }}..HEAD" \
2828
--oneline \
2929
--no-merges |
30-
grep -v -E 'github-actions\[bot\]|dependabot\[bot\]|test|Bump' |
30+
grep -v -E 'github-actions\[bot\]|dependabot\[bot\]|test|Bump|chore' || true |
3131
sed 's/^[a-f0-9]\{7,40\} //' | # remove SHA prefix
3232
awk '!seen[$0]++' |
3333
sed 's/^/- /'
3434
} > docs/release.md
35-
- name: Upload UI artifact
35+
- name: Upload release notes
3636
uses: actions/upload-artifact@v4
3737
with:
3838
name: release-notes

.github/actions/publish-website/action.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ runs:
2121
steps:
2222
- uses: actions/setup-node@v4
2323
with:
24-
node-version: 23.11.1
24+
node-version: 24
2525
registry-url: 'https://registry.npmjs.org'
2626
- id: release
2727
uses: pozetroninc/github-action-get-latest-release@master

.github/actions/run-frontend-tests/action.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ runs:
2727
shell: bash
2828
- uses: actions/setup-node@v4
2929
with:
30-
node-version: 20
30+
node-version: 24
3131
- name: Install and Build
3232
working-directory: ./webui
3333
run: |

.github/workflows/build.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ jobs:
2020
- name: Setup node
2121
uses: actions/setup-node@v4
2222
with:
23-
node-version: 23
23+
node-version: 24
2424
- name: build webui
2525
working-directory: ./webui
2626
run: |

.github/workflows/release.yml

Lines changed: 109 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,114 @@ permissions:
88
contents: write
99

1010
jobs:
11+
build-dashboard:
12+
runs-on: ubuntu-latest
13+
steps:
14+
- uses: actions/checkout@v4
15+
with:
16+
fetch-depth: 0
17+
- uses: actions/setup-go@v5
18+
with:
19+
go-version: 1.25.5
20+
- uses: ./.github/actions/build-release-notes
21+
- uses: actions/setup-node@v4
22+
with:
23+
node-version: 24
24+
registry-url: 'https://registry.npmjs.org'
25+
- run: npm install
26+
working-directory: ./webui
27+
- name: Install taskfile
28+
run: sh -c "$(curl --location https://taskfile.dev/install.sh)" -- -d -b ~/.local/bin
29+
- name: Build
30+
run: task build-vue-app
31+
- name: Upload UI artifact
32+
uses: actions/upload-artifact@v4
33+
with:
34+
name: dashboard
35+
path: webui/dist
36+
37+
release-unix:
38+
needs: build-dashboard
39+
runs-on: ubuntu-latest
40+
env:
41+
DOCKER_CLI_EXPERIMENTAL: "enabled"
42+
steps:
43+
- uses: actions/checkout@v4
44+
with:
45+
fetch-depth: 0
46+
- name: Download dashboard
47+
uses: actions/download-artifact@v4
48+
with:
49+
name: dashboard
50+
path: webui/dist
51+
- name: Set up QEMU
52+
uses: docker/setup-qemu-action@v3
53+
- name: Set up Docker Buildx
54+
uses: docker/setup-buildx-action@v3
55+
- name: Docker Login
56+
uses: docker/login-action@v1
57+
with:
58+
username: marle3003
59+
password: ${{ secrets.DOCKER_PASSWORD }}
60+
- uses: actions/setup-go@v5
61+
with:
62+
go-version: 1.25.5
63+
- name: Run GoReleaser
64+
uses: goreleaser/goreleaser-action@v6
65+
with:
66+
version: latest
67+
args: release --clean
68+
env:
69+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
70+
TAP_GITHUB_TOKEN: ${{ secrets.TAP_GITHUB_TOKEN }}
71+
72+
release-windows:
73+
needs: build-dashboard
74+
runs-on: windows-latest
75+
steps:
76+
- uses: actions/checkout@v4
77+
with:
78+
fetch-depth: 0
79+
- name: Download dashboard
80+
uses: actions/download-artifact@v4
81+
with:
82+
name: dashboard
83+
path: webui/dist
84+
- uses: actions/setup-go@v5
85+
with:
86+
go-version: 1.25.5
87+
- name: Install goversioninfo
88+
run: go install github.com/josephspurrier/goversioninfo/cmd/goversioninfo@v1.4.0
89+
- name: Generate Windows metadata (.syso)
90+
working-directory: ./cmd/mokapi
91+
shell: pwsh
92+
run: |
93+
$versionParts = ($env:GITHUB_REF -replace '.*/v', '').Split('.')
94+
'{}' | Out-File versioninfo.json -NoNewline ascii
95+
goversioninfo -64 `
96+
-platform-specific='true' `
97+
-charset="1200" `
98+
-company="Mokapi OpenSource" `
99+
-copyright="© Marcel Lehmann. Licensed under MIT." `
100+
-description="Your API Mocking Tool for Agile Development, using Go and JavaScript" `
101+
-icon="../../icon.ico" `
102+
-internal-name="mokapi" `
103+
-original-name="mokapi.exe" `
104+
-product-name="mokapi" `
105+
-translation="0x0409" `
106+
-ver-major="$($versionParts[0])" `
107+
-ver-minor="$($versionParts[1])" `
108+
-ver-patch="$($versionParts[2])" `
109+
-product-version="$($versionParts[0]).$($versionParts[1]).$($versionParts[2])"
110+
111+
- name: Run GoReleaser
112+
uses: goreleaser/goreleaser-action@v6
113+
with:
114+
version: latest
115+
args: release -f .goreleaser.windows.yml --clean
116+
env:
117+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
118+
CHOCOLATEY_API_KEY: ${{ secrets.CHOCOLATEY_API_KEY }}
11119

12120
release-npm:
13121
runs-on: ubuntu-latest
@@ -26,6 +134,6 @@ jobs:
26134
- name: Install taskfile
27135
run: sh -c "$(curl --location https://taskfile.dev/install.sh)" -- -d -b ~/.local/bin
28136
- name: Publish
29-
run: task publish-npm-package VERSION=${GITHUB_REF##*/v}
137+
run: task publish-all VERSION=${GITHUB_REF##*/v}
30138
env:
31139
CGO_ENABLED: 0

.gitignore

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
# vendor/
1717
data/*
1818
dist/
19-
bin/*
19+
**/bin/
2020
obj/
2121
Debug/
2222

Taskfile.yml

Lines changed: 74 additions & 38 deletions
Original file line numberDiff line numberDiff line change
@@ -3,30 +3,6 @@
33
version: '3'
44

55
tasks:
6-
default:
7-
deps: [build-vue-app]
8-
cmds:
9-
- task: build-windows
10-
build-windows:
11-
deps: [build-vue-app]
12-
cmds:
13-
- go build -o mokapi-windows-amd64.exe -ldflags="-w -s -X 'mokapi/version.BuildVersion=1.0'" ./cmd/mokapi
14-
env:
15-
GOOS: windows
16-
GOARCH: amd64
17-
build-linux:
18-
deps: [build-vue-app]
19-
cmds:
20-
- go build -o mokapi-linux-amd64 -ldflags="-X 'mokapi/version.BuildVersion=1.0'" ./cmd/mokapi
21-
env:
22-
GOOS: linux
23-
GOARCH: amd64
24-
build-macos:
25-
cmds:
26-
- go build -o mokapi-darwin-arm64 -ldflags="-X 'mokapi/version.BuildVersion=1.0'" ./cmd/mokapi
27-
env:
28-
GOOS: darwin
29-
GOARCH: arm64
306
build-vue-app:
317
deps: [ensure-dist-folder]
328
dir: webui
@@ -36,36 +12,96 @@ tasks:
3612
- go run ../cmd/internal/gen-cli-docs/main.go --output-dir ./webui/src/assets/docs/configuration/static
3713
- npm version {{.VERSION}}
3814
- npm run build-dashboard
39-
build-npm-package:
40-
deps: [build-vue-app]
15+
publish-all:
16+
deps: [ build-vue-app ]
4117
cmds:
42-
- task npm-build-windows VERSION={{.VERSION}}
43-
- task npm-build-linux VERSION={{.VERSION}}
44-
- task npm-build-macos VERSION={{.VERSION}}
45-
publish-npm-package:
46-
deps: [build-npm-package]
47-
dir: npm
18+
- task publish-platform-dependent VERSION={{.VERSION}}
19+
- task publish-mokapi VERSION={{.VERSION}}
20+
publish-platform-dependent:
21+
deps:
22+
- publish-mokapi-windows-x64
23+
- publish-mokapi-windows-arm64
24+
- publish-mokapi-linux-x64
25+
- publish-mokapi-linux-arm64
26+
- publish-mokapi-macos-x64
27+
- publish-mokapi-macos-arm64
28+
publish-mokapi:
29+
dir: npm/go-mokapi
4830
cmds:
4931
- npm version {{.VERSION}}
5032
- npm publish --provenance
51-
npm-build-windows:
33+
publish-mokapi-windows-x64:
34+
deps: [ build-mokapi-windows-x64 ]
35+
dir: npm/@go-mokapi/win32-x64
36+
cmds:
37+
- npm version {{.VERSION}}
38+
- npm publish --provenance --access public
39+
build-mokapi-windows-x64:
5240
cmds:
53-
- go build -o ./npm/dist/mokapi-windows-amd64/mokapi.exe -ldflags="-X mokapi/version.BuildVersion={{.VERSION}}" ./cmd/mokapi
41+
- go build -o ./npm/@go-mokapi/win32-x64/bin/mokapi.exe -ldflags="-X mokapi/version.BuildVersion={{.VERSION}}" ./cmd/mokapi
5442
env:
5543
GOOS: windows
5644
GOARCH: amd64
57-
npm-build-linux:
45+
publish-mokapi-windows-arm64:
46+
deps: [ build-mokapi-windows-arm64 ]
47+
dir: npm/@go-mokapi/win32-arm64
5848
cmds:
59-
- go build -o ./npm/dist/mokapi-linux-amd64/mokapi -ldflags="-X mokapi/version.BuildVersion={{.VERSION}}" ./cmd/mokapi
49+
- npm version {{.VERSION}}
50+
- npm publish --provenance --access public
51+
build-mokapi-windows-arm64:
52+
cmds:
53+
- go build -o ./npm/@go-mokapi/win32-arm64/bin/mokapi.exe -ldflags="-X mokapi/version.BuildVersion={{.VERSION}}" ./cmd/mokapi
54+
env:
55+
GOOS: windows
56+
GOARCH: arm64
57+
publish-mokapi-linux-x64:
58+
deps: [ build-mokapi-linux-x64 ]
59+
dir: npm/@go-mokapi/linux-x64
60+
cmds:
61+
- npm version {{.VERSION}}
62+
- npm publish --provenance --access public
63+
build-mokapi-linux-x64:
64+
cmds:
65+
- go build -o ./npm/@go-mokapi/linux-x64/bin/mokapi -ldflags="-X mokapi/version.BuildVersion={{.VERSION}}" ./cmd/mokapi
6066
env:
6167
GOOS: linux
6268
GOARCH: amd64
63-
npm-build-macos:
69+
publish-mokapi-linux-arm64:
70+
deps: [ build-mokapi-linux-arm64 ]
71+
dir: npm/@go-mokapi/linux-arm64
72+
cmds:
73+
- npm version {{.VERSION}}
74+
- npm publish --provenance --access public
75+
build-mokapi-linux-arm64:
76+
cmds:
77+
- go build -o ./npm/@go-mokapi/linux-arm64/bin/mokapi -ldflags="-X mokapi/version.BuildVersion={{.VERSION}}" ./cmd/mokapi
78+
env:
79+
GOOS: linux
80+
GOARCH: arm64
81+
publish-mokapi-macos-arm64:
82+
deps: [ build-mokapi-macos-arm64 ]
83+
dir: npm/@go-mokapi/darwin-arm64
84+
cmds:
85+
- npm version {{.VERSION}}
86+
- npm publish --provenance --access public
87+
build-mokapi-macos-arm64:
6488
cmds:
65-
- go build -o ./npm/dist/mokapi-darwin-arm64/mokapi -ldflags="-X mokapi/version.BuildVersion={{.VERSION}}" ./cmd/mokapi
89+
- go build -o ./npm/@go-mokapi/darwin-arm64/bin/mokapi -ldflags="-X mokapi/version.BuildVersion={{.VERSION}}" ./cmd/mokapi
6690
env:
6791
GOOS: darwin
6892
GOARCH: arm64
93+
publish-mokapi-macos-x64:
94+
deps: [ build-mokapi-macos-x64 ]
95+
dir: npm/@go-mokapi/darwin-x64
96+
cmds:
97+
- npm version {{.VERSION}}
98+
- npm publish --provenance --access public
99+
build-mokapi-macos-x64:
100+
cmds:
101+
- go build -o ./npm/@go-mokapi/darwin-x64/bin/mokapi -ldflags="-X mokapi/version.BuildVersion={{.VERSION}}" ./cmd/mokapi
102+
env:
103+
GOOS: darwin
104+
GOARCH: amd64
69105
ensure-dist-folder:
70106
cmds:
71107
- mkdir -p webui/dist

docs/resources/blogs/end-to-end-testing-mocked-apis.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,7 @@ jobs:
8383
- name: Set Up Node.js
8484
uses: actions/setup-node@v4
8585
with:
86-
node-version: 20
86+
node-version: 24
8787

8888
- name: Install Dependencies
8989
run: npm install

docs/resources/tutorials/running-mokapi-github-action.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -170,7 +170,7 @@ jobs:
170170
- name: Set Up Node.js
171171
uses: actions/setup-node@v4
172172
with:
173-
node-version: 20
173+
node-version: 24
174174

175175
- name: Install Dependencies
176176
run: npm install
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
# mokapi
2+
3+
This package contains the **macOS ARM 64-bit binary** for **mokapi**, an API mocking tool.
4+
See https://mokapi.io for details

0 commit comments

Comments
 (0)