Skip to content

Commit d920d92

Browse files
authored
Merge pull request #326 from hirosystems/devops-2230
ci: support npm trusted publishers
2 parents d04012f + 9b0d222 commit d920d92

File tree

3 files changed

+108
-25
lines changed

3 files changed

+108
-25
lines changed

.github/workflows/ci.yml

Lines changed: 17 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -18,10 +18,10 @@ jobs:
1818
lint:
1919
runs-on: ubuntu-latest
2020
steps:
21-
- uses: actions/checkout@v4
21+
- uses: actions/checkout@v5
2222

2323
- name: Use Node.js
24-
uses: actions/setup-node@v4
24+
uses: actions/setup-node@v6
2525
with:
2626
node-version-file: '.nvmrc'
2727

@@ -71,12 +71,12 @@ jobs:
7171
STACKS_NODE_RPC_HOST: 127.0.0.1
7272
STACKS_NODE_RPC_PORT: 24440
7373
steps:
74-
- uses: actions/checkout@v4
74+
- uses: actions/checkout@v5
7575
with:
7676
fetch-depth: 0
7777

7878
- name: Use Node.js
79-
uses: actions/setup-node@v4
79+
uses: actions/setup-node@v6
8080
with:
8181
node-version-file: '.nvmrc'
8282

@@ -107,7 +107,7 @@ jobs:
107107
run: npm run test:${{ matrix.suite }} -- --coverage
108108

109109
- name: Upload coverage to Codecov
110-
uses: codecov/codecov-action@v4
110+
uses: codecov/codecov-action@v5
111111
with:
112112
token: ${{ secrets.CODECOV_TOKEN }}
113113

@@ -122,6 +122,7 @@ jobs:
122122
build-publish:
123123
permissions:
124124
contents: write
125+
id-token: write
125126
issues: write
126127
pull-requests: write
127128
runs-on: ubuntu-latest
@@ -131,14 +132,13 @@ jobs:
131132
steps:
132133
- name: Generate release bot app token
133134
id: generate_token
134-
uses: actions/create-github-app-token@v1
135+
uses: actions/create-github-app-token@v2
135136
with:
136137
app-id: ${{ secrets.HIROSYSTEMS_RELEASE_BOT_ID }}
137138
private-key: ${{ secrets.HIROSYSTEMS_RELEASE_BOT_PEM }}
138139

139-
- uses: actions/checkout@v4
140+
- uses: actions/checkout@v5
140141
with:
141-
token: ${{ secrets.GH_TOKEN || secrets.GITHUB_TOKEN }}
142142
fetch-depth: 0
143143
persist-credentials: false
144144

@@ -149,8 +149,14 @@ jobs:
149149
env:
150150
GH_TOKEN: ${{ steps.generate_token.outputs.token }}
151151

152+
- name: Install deps
153+
run: |
154+
npm ci --audit=false
155+
cd client
156+
npm ci --audit=false
157+
152158
- name: Semantic Release
153-
uses: cycjimmy/semantic-release-action@v4
159+
uses: cycjimmy/semantic-release-action@9cc899c47e6841430bbaedb43de1560a568dfd16 # v5
154160
id: semantic
155161
# Only run on non-PR events or only PRs that aren't from forks
156162
if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name == github.repository
@@ -160,11 +166,10 @@ jobs:
160166
GIT_AUTHOR_EMAIL: "${{ steps.bot-user-id.outputs.user-id }}+${{ steps.generate_token.outputs.app-slug }}[bot]@users.noreply.github.com"
161167
GIT_COMMITTER_EMAIL: "${{ steps.bot-user-id.outputs.user-id }}+${{ steps.generate_token.outputs.app-slug }}[bot]@users.noreply.github.com"
162168
with:
163-
semantic_version: 19
164169
extra_plugins: |
165170
@semantic-release/changelog@6.0.3
166171
@semantic-release/git@10.0.1
167-
conventional-changelog-conventionalcommits@6.1.0
172+
conventional-changelog-conventionalcommits@9.1.0
168173
169174
- name: Set up Docker Buildx
170175
uses: docker/setup-buildx-action@v3
@@ -188,7 +193,7 @@ jobs:
188193
password: ${{ secrets.DOCKERHUB_PASSWORD }}
189194

190195
- name: Build/Tag/Push Image
191-
uses: docker/build-push-action@v5
196+
uses: docker/build-push-action@v6
192197
with:
193198
context: .
194199
tags: ${{ steps.meta.outputs.tags }}

.releaserc

Lines changed: 17 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,24 @@
1212
"preset": "conventionalcommits"
1313
}
1414
],
15+
[
16+
"@semantic-release/npm",
17+
{
18+
"pkgRoot": "./client",
19+
"npmPublish": true
20+
}
21+
],
1522
"@semantic-release/github",
1623
"@semantic-release/changelog",
17-
"@semantic-release/git"
24+
[
25+
"@semantic-release/git",
26+
{
27+
"assets": [
28+
"CHANGELOG.md",
29+
"client/package.json",
30+
"client/package-lock.json"
31+
]
32+
}
33+
]
1834
]
1935
}

client/src/generated/schema.d.ts

Lines changed: 74 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -126,6 +126,8 @@ export interface operations {
126126
* @example SP3K8BC0PPEVCV7NZ6QSRWPQ2JE9E5B6N3PA0KBR9
127127
*/
128128
address?: string;
129+
/** @description If enabled, only tokens with valid SIP-016 metadata will be returned */
130+
valid_metadata_only?: boolean;
129131
/** @description Result offset */
130132
offset?: number;
131133
/** @description Results per page */
@@ -165,30 +167,42 @@ export interface operations {
165167
total_supply?: string;
166168
/**
167169
* Format: uri
170+
* @description URI for this token's metadata JSON
168171
* @example ipfs://ipfs/Qmf9yDYuPTrp8NRUFf8xxDd5Ud24Dx9uYMwMn8o8G2cWPW/12200.json
169172
*/
170173
token_uri?: string;
171-
/** @example Heavy hitters, all-stars and legends of the game join forces to create a collection of unique varsity jackets */
174+
/**
175+
* @description Description
176+
* @example Heavy hitters, all-stars and legends of the game join forces to create a collection of unique varsity jackets
177+
*/
172178
description?: string;
173179
/**
174180
* Format: uri
181+
* @description Cached image URL
175182
* @example https://ipfs.io/ipfs/QmZMqhh2ztwuZ3Y8PyEp2z5auyH3TCm3nnr5ZfjjgDjd5q/12199.png
176183
*/
177184
image_uri?: string;
178185
/**
179186
* Format: uri
187+
* @description Cached image URL
180188
* @example https://ipfs.io/ipfs/QmZMqhh2ztwuZ3Y8PyEp2z5auyH3TCm3nnr5ZfjjgDjd5q/12199.png
181189
*/
182190
image_thumbnail_uri?: string;
183191
/**
184192
* Format: uri
193+
* @description Original image URL
185194
* @example ipfs://ipfs/QmZMqhh2ztwuZ3Y8PyEp2z5auyH3TCm3nnr5ZfjjgDjd5q/12199.png
186195
*/
187196
image_canonical_uri?: string;
188197
/** @example 0xef2ac1126e16f46843228b1dk4830e19eb7599129e4jf392cab9e65ae83a45c0 */
189198
tx_id: string;
190199
/** @example ST399W7Z9WS0GMSNQGJGME5JAENKN56D65VGMGKGA */
191200
sender_address: string;
201+
/**
202+
* @description Clarity asset identifier
203+
* @example SPZA22A4D15RKH5G8XDGQ7BPC20Q5JNMH0VQKSR6.token-ststx-earn-v1::stSTXearn
204+
*/
205+
asset_identifier: string;
192206
/** @example SP1H1733V5MZ3SZ9XRW9FKYGEZT0JDGEB8Y634C7R.miamicoin-token-v2 */
193207
contract_principal: string;
194208
}[];
@@ -222,62 +236,96 @@ export interface operations {
222236
};
223237
content: {
224238
"application/json": {
225-
/** @example Wrapped USD */
239+
/**
240+
* @description Token name
241+
* @example Wrapped USD
242+
*/
226243
name?: string;
227-
/** @example xUSD */
244+
/**
245+
* @description Token symbol
246+
* @example xUSD
247+
*/
228248
symbol?: string;
229-
/** @example 8 */
249+
/**
250+
* @description Number of decimal places clients should use to format this token's amounts
251+
* @example 8
252+
*/
230253
decimals?: number;
231-
/** @example 9999980000000 */
254+
/**
255+
* @description Current circulating supply as reported by its contract. Clients should format this amount with the correct number of `decimals` before displaying to users
256+
* @example 9999980000000
257+
*/
232258
total_supply?: string;
233259
/**
234260
* Format: uri
261+
* @description URI for this token's metadata JSON
235262
* @example ipfs://ipfs/Qmf9yDYuPTrp8NRUFf8xxDd5Ud24Dx9uYMwMn8o8G2cWPW/12200.json
236263
*/
237264
token_uri?: string;
238-
/** @example Heavy hitters, all-stars and legends of the game join forces to create a collection of unique varsity jackets */
265+
/**
266+
* @description Description
267+
* @example Heavy hitters, all-stars and legends of the game join forces to create a collection of unique varsity jackets
268+
*/
239269
description?: string;
240270
/**
241271
* Format: uri
272+
* @description Cached image URL
242273
* @example https://ipfs.io/ipfs/QmZMqhh2ztwuZ3Y8PyEp2z5auyH3TCm3nnr5ZfjjgDjd5q/12199.png
243274
*/
244275
image_uri?: string;
245276
/**
246277
* Format: uri
278+
* @description Cached image URL
247279
* @example https://ipfs.io/ipfs/QmZMqhh2ztwuZ3Y8PyEp2z5auyH3TCm3nnr5ZfjjgDjd5q/12199.png
248280
*/
249281
image_thumbnail_uri?: string;
250282
/**
251283
* Format: uri
284+
* @description Original image URL
252285
* @example ipfs://ipfs/QmZMqhh2ztwuZ3Y8PyEp2z5auyH3TCm3nnr5ZfjjgDjd5q/12199.png
253286
*/
254287
image_canonical_uri?: string;
255-
/** @example 0x5642ca7d68976b6b2a2055689d9a57de26d67f0dd8b016d1b0d94cb634454cdd */
288+
/**
289+
* @description ID for the transaction that deployed this token
290+
* @example 0x5642ca7d68976b6b2a2055689d9a57de26d67f0dd8b016d1b0d94cb634454cdd
291+
*/
256292
tx_id: string;
257-
/** @example SPZA22A4D15RKH5G8XDGQ7BPC20Q5JNMH0VQKSR6 */
293+
/**
294+
* @description Deployer address
295+
* @example SPZA22A4D15RKH5G8XDGQ7BPC20Q5JNMH0VQKSR6
296+
*/
258297
sender_address: string;
259-
/** @example SPZA22A4D15RKH5G8XDGQ7BPC20Q5JNMH0VQKSR6.token-ststx-earn-v1::stSTXearn */
298+
/**
299+
* @description Clarity asset identifier
300+
* @example SPZA22A4D15RKH5G8XDGQ7BPC20Q5JNMH0VQKSR6.token-ststx-earn-v1::stSTXearn
301+
*/
260302
asset_identifier: string;
261303
/** Metadata */
262304
metadata?: {
263305
/** @example 16 */
264306
sip: number;
265307
/** @example Satoshi's Team #12200 */
266308
name?: string;
267-
/** @example Heavy hitters, all-stars and legends of the game join forces to create a collection of unique varsity jackets */
309+
/**
310+
* @description Description
311+
* @example Heavy hitters, all-stars and legends of the game join forces to create a collection of unique varsity jackets
312+
*/
268313
description?: string;
269314
/**
270315
* Format: uri
316+
* @description Original image URL
271317
* @example ipfs://ipfs/QmZMqhh2ztwuZ3Y8PyEp2z5auyH3TCm3nnr5ZfjjgDjd5q/12199.png
272318
*/
273319
image?: string;
274320
/**
275321
* Format: uri
322+
* @description Cached image URL
276323
* @example https://ipfs.io/ipfs/QmZMqhh2ztwuZ3Y8PyEp2z5auyH3TCm3nnr5ZfjjgDjd5q/12199.png
277324
*/
278325
cached_image?: string;
279326
/**
280327
* Format: uri
328+
* @description Cached image URL
281329
* @example https://ipfs.io/ipfs/QmZMqhh2ztwuZ3Y8PyEp2z5auyH3TCm3nnr5ZfjjgDjd5q/12199.png
282330
*/
283331
cached_thumbnail_image?: string;
@@ -389,6 +437,7 @@ export interface operations {
389437
"application/json": {
390438
/**
391439
* Format: uri
440+
* @description URI for this token's metadata JSON
392441
* @example ipfs://ipfs/Qmf9yDYuPTrp8NRUFf8xxDd5Ud24Dx9uYMwMn8o8G2cWPW/12200.json
393442
*/
394443
token_uri?: string;
@@ -398,20 +447,26 @@ export interface operations {
398447
sip: number;
399448
/** @example Satoshi's Team #12200 */
400449
name?: string;
401-
/** @example Heavy hitters, all-stars and legends of the game join forces to create a collection of unique varsity jackets */
450+
/**
451+
* @description Description
452+
* @example Heavy hitters, all-stars and legends of the game join forces to create a collection of unique varsity jackets
453+
*/
402454
description?: string;
403455
/**
404456
* Format: uri
457+
* @description Original image URL
405458
* @example ipfs://ipfs/QmZMqhh2ztwuZ3Y8PyEp2z5auyH3TCm3nnr5ZfjjgDjd5q/12199.png
406459
*/
407460
image?: string;
408461
/**
409462
* Format: uri
463+
* @description Cached image URL
410464
* @example https://ipfs.io/ipfs/QmZMqhh2ztwuZ3Y8PyEp2z5auyH3TCm3nnr5ZfjjgDjd5q/12199.png
411465
*/
412466
cached_image?: string;
413467
/**
414468
* Format: uri
469+
* @description Cached image URL
415470
* @example https://ipfs.io/ipfs/QmZMqhh2ztwuZ3Y8PyEp2z5auyH3TCm3nnr5ZfjjgDjd5q/12199.png
416471
*/
417472
cached_thumbnail_image?: string;
@@ -523,6 +578,7 @@ export interface operations {
523578
"application/json": {
524579
/**
525580
* Format: uri
581+
* @description URI for this token's metadata JSON
526582
* @example ipfs://ipfs/Qmf9yDYuPTrp8NRUFf8xxDd5Ud24Dx9uYMwMn8o8G2cWPW/12200.json
527583
*/
528584
token_uri?: string;
@@ -536,20 +592,26 @@ export interface operations {
536592
sip: number;
537593
/** @example Satoshi's Team #12200 */
538594
name?: string;
539-
/** @example Heavy hitters, all-stars and legends of the game join forces to create a collection of unique varsity jackets */
595+
/**
596+
* @description Description
597+
* @example Heavy hitters, all-stars and legends of the game join forces to create a collection of unique varsity jackets
598+
*/
540599
description?: string;
541600
/**
542601
* Format: uri
602+
* @description Original image URL
543603
* @example ipfs://ipfs/QmZMqhh2ztwuZ3Y8PyEp2z5auyH3TCm3nnr5ZfjjgDjd5q/12199.png
544604
*/
545605
image?: string;
546606
/**
547607
* Format: uri
608+
* @description Cached image URL
548609
* @example https://ipfs.io/ipfs/QmZMqhh2ztwuZ3Y8PyEp2z5auyH3TCm3nnr5ZfjjgDjd5q/12199.png
549610
*/
550611
cached_image?: string;
551612
/**
552613
* Format: uri
614+
* @description Cached image URL
553615
* @example https://ipfs.io/ipfs/QmZMqhh2ztwuZ3Y8PyEp2z5auyH3TCm3nnr5ZfjjgDjd5q/12199.png
554616
*/
555617
cached_thumbnail_image?: string;

0 commit comments

Comments
 (0)