Skip to content

Commit a070ba2

Browse files
authored
chore: update project infra (#43)
* chore: update project infra Signed-off-by: Ryan Wang <[email protected]> * fix ci Signed-off-by: Ryan Wang <[email protected]> --------- Signed-off-by: Ryan Wang <[email protected]>
1 parent cf7b1cd commit a070ba2

File tree

12 files changed

+3224
-2727
lines changed

12 files changed

+3224
-2727
lines changed

.github/workflows/cd.yaml

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
name: CD
2+
3+
on:
4+
release:
5+
types:
6+
- published
7+
8+
jobs:
9+
cd:
10+
uses: halo-sigs/reusable-workflows/.github/workflows/plugin-cd.yaml@v1
11+
secrets:
12+
halo-username: ${{ secrets.HALO_USERNAME }}
13+
halo-password: ${{ secrets.HALO_PASSWORD }}
14+
permissions:
15+
contents: write
16+
with:
17+
app-id: app-TlUBt
18+
ui-path: "console"
19+
node-version: "20"
20+
pnpm-version: "9"

.github/workflows/ci.yaml

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
name: CI
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
pull_request:
8+
branches:
9+
- main
10+
11+
jobs:
12+
ci:
13+
uses: halo-sigs/reusable-workflows/.github/workflows/plugin-ci.yaml@v1
14+
with:
15+
ui-path: "console"
16+
node-version: "20"
17+
pnpm-version: "9"

.github/workflows/workflow.yaml

Lines changed: 0 additions & 138 deletions
This file was deleted.

build.gradle

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,14 +29,23 @@ node {
2929
nodeProjectDir = file("${project.projectDir}/console")
3030
}
3131

32-
task buildFrontend(type: PnpmTask) {
32+
tasks.register('buildFrontend', PnpmTask) {
3333
args = ['build']
34+
dependsOn('installDepsForUI')
35+
}
36+
37+
tasks.register('installDepsForUI', PnpmTask) {
38+
args = ['install']
3439
}
3540

3641
build {
37-
tasks.getByName('compileJava').dependsOn('buildFrontend')
42+
// build frontend before build
43+
tasks.named('compileJava').configure {
44+
dependsOn('buildFrontend')
45+
}
3846
}
3947

48+
4049
halo {
4150
version = '2.12'
4251
}

console/package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@
2828
"yaml": "^2.4.2"
2929
},
3030
"devDependencies": {
31+
"@halo-dev/ui-plugin-bundler-kit": "^2.16.0",
3132
"@iconify/json": "^2.2.95",
3233
"@rushstack/eslint-patch": "^1.3.2",
3334
"@types/jsdom": "^16.2.15",

0 commit comments

Comments
 (0)