forked from Gruntfuggly/todo-tree
-
-
Notifications
You must be signed in to change notification settings - Fork 0
98 lines (82 loc) · 2.8 KB
/
Copy pathlatest.yml
File metadata and controls
98 lines (82 loc) · 2.8 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
name: Latest
on:
push:
branches:
- master
schedule:
- cron: '17 5 * * *'
workflow_dispatch:
permissions:
contents: read
concurrency:
group: latest-master
cancel-in-progress: true
jobs:
preflight:
runs-on: ubuntu-24.04
outputs:
release_ref: ${{ steps.meta.outputs.release_ref }}
release_sha: ${{ steps.meta.outputs.release_sha }}
release_short_sha: ${{ steps.meta.outputs.release_short_sha }}
steps:
- name: Check out repository
uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10
with:
fetch-depth: 0
- name: Set up Node.js
uses: actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e
with:
node-version-file: .nvmrc
cache: npm
cache-dependency-path: package-lock.json
- name: Cache upstream parity clone
uses: actions/cache@27d5ce7f107fe9357f9df03efb73ab90386fccae
with:
path: .tools/upstream-todo-tree
key: upstream-todo-tree-7761bd02406a5c5f5bc8da944a561eb3c12a48df
- name: Install dependencies
run: npm ci
- name: Resolve latest release metadata
id: meta
run: |
echo "release_ref=${GITHUB_SHA}" >> "$GITHUB_OUTPUT"
echo "release_sha=$(git rev-parse HEAD)" >> "$GITHUB_OUTPUT"
echo "release_short_sha=$(git rev-parse --short=12 HEAD)" >> "$GITHUB_OUTPUT"
- name: Run test suite
run: npm test
- name: Build production bundle
run: npm run vscode:prepublish
build:
needs: preflight
uses: ./.github/workflows/reusable-build-vsix.yml
with:
ref: ${{ needs.preflight.outputs.release_ref }}
targets: '["win32-x64","win32-arm64","linux-x64","linux-arm64","linux-armhf","darwin-x64","darwin-arm64","alpine-x64","alpine-arm64","web"]'
secrets: inherit
github-release:
needs:
- preflight
- build
runs-on: ubuntu-24.04
permissions:
contents: write
steps:
- name: Check out repository
uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10
with:
fetch-depth: 0
ref: ${{ needs.preflight.outputs.release_ref }}
- name: Download VSIX artifacts
uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c
with:
pattern: vsix-*
path: artifacts/release
merge-multiple: true
- name: Create or update latest GitHub release
env:
GH_TOKEN: ${{ github.token }}
RELEASE_TAG: latest
RELEASE_TITLE: Latest Nightly Build (${{ needs.preflight.outputs.release_short_sha }})
RELEASE_TARGET_SHA: ${{ needs.preflight.outputs.release_sha }}
RELEASE_TARGET_BRANCH: master
run: bash scripts/release/create-or-update-moving-github-release.sh