This repository was archived by the owner on May 20, 2025. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 92
132 lines (110 loc) · 4.01 KB
/
covector.yml
File metadata and controls
132 lines (110 loc) · 4.01 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
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
name: Covector
on:
push:
branches: [develop, production]
paths-ignore:
- "specs/**"
- "documentation/**"
concurrency:
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
cancel-in-progress: true
jobs:
status:
name: Status
runs-on: ubuntu-latest
steps:
- name: Checkout the Source Code
uses: actions/checkout@v3
- name: Run Covector Status
uses: jbolda/covector/packages/action@covector-v0
id: covector
with:
command: status
version-or-publish:
name: Version-or-publish
runs-on: ubuntu-latest
outputs:
change: ${{ steps.covector.outputs.change }}
commandRan: ${{ steps.covector.outputs.commandRan }}
successfulPublish: ${{ steps.covector.outputs.successfulPublish }}
steps:
- name: Checkout the Source Code
uses: actions/checkout@v3
- name: Set Up Node.js 14
uses: actions/setup-node@v2
with:
node-version: "14"
registry-url: "https://registry.npmjs.org"
- name: Configure the Git User to Use
run: |
git config --global user.name "${{ github.event.pusher.name }}"
git config --global user.email "${{ github.event.pusher.email }}"
- name: Set up Homebrew
uses: Homebrew/actions/setup-homebrew@master
- name: Install Dasel
run: |
brew update --preinstall
brew install dasel
# Publish when no change file is present.
- id: covector
name: Run Covector Version-or-publish
uses: jbolda/covector/packages/action@covector-v0
with:
token: ${{ secrets.GITHUB_TOKEN }}
command: version-or-publish
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
- name: Create Pull Request with Versions Bumped
if: ${{ steps.covector.outputs.commandRan == 'version' }}
uses: iotaledger/create-pull-request@v3.4.1
with:
token: ${{ secrets.GITHUB_TOKEN }}
branch: release/version-updates
title: Apply Version Updates From Current Changes
commit-message: apply version updates
labels: i-release
body: ${{ steps.covector.outputs.change }}
nodejs-binding-prebuild:
name: Build Prebuilt Binaries for Node.js
needs: version-or-publish
if: needs.version-or-publish.outputs.successfulPublish == 'true'
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
# The GitHub hosted Windows 2022 image comes with Visual Studio 2022, but node-gyp
# (which is used by neon-sys) sadly fails to recognize it. As a mitigation, we still run the
# tests on Windows 2019, until we can figure out a way to fix the problem.
os: [ubuntu-latest, macos-latest, windows-2019]
steps:
- name: Checkout the Source Code
uses: actions/checkout@v3
- name: Set Up Stable Rust
uses: ./.github/actions/setup-rust
with:
toolchain: stable
cache: false
- name: Set up Node.js 16.x
uses: actions/setup-node@v2
with:
node-version: "16.x"
- name: Install required packages (Ubuntu)
if: ${{ startsWith(matrix.os, 'ubuntu') }}
run: |
sudo apt-get update
sudo apt-get install libudev-dev libusb-1.0-0-dev
# Temporary fix for "ValueError: invalid mode: 'rU' while trying to load binding.gyp"
# This can be removed when "prebuild" updates "node-gyp"
- name: Set up Python 3.10
uses: actions/setup-python@v4
with:
python-version: "3.10"
- name: Run Yarn Install
working-directory: client/bindings/nodejs/
run: yarn install
- name: Build Node.js Prebuilds
working-directory: client/bindings/nodejs/
run: yarn prebuild
- name: Upload Prebuilds to GitHub Release
working-directory: client/bindings/nodejs/
run: yarn prebuild --upload-all ${{ secrets.GITHUB_TOKEN }} --tag-prefix nodejs-binding-v