-
Notifications
You must be signed in to change notification settings - Fork 227
58 lines (48 loc) · 1.37 KB
/
release.yml
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
name: Release httpsnippet
on:
workflow_dispatch:
inputs:
version:
description: 'Tag version to release'
required: true
env:
# Release Tag to build and publish
TAG: ${{ github.event.inputs.version }}
jobs:
release:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
with:
fetch-depth: 0
token: ${{ secrets.PAT_INSOMNIA_INFRA }}
- name: Configure Git user
uses: Homebrew/actions/git-user-config@master
with:
username: ${{ (github.event_name == 'workflow_dispatch' && github.actor) || 'insomnia-infra' }}
- name: Setup Node
uses: actions/setup-node@v4
with:
node-version: 20
- name: Install
run: npm ci
- name: Create new package version
run: npm version "${{ env.TAG }}"
- name: DEBUG see tags
run: |
git tag --list
git remote -v
- name: Merge version commit into master
run: |
git push origin v${{ env.TAG }}
git push origin master
- name: Create Tag and Release
uses: ncipollo/release-action@v1
id: core_tag_and_release
with:
tag: v${{ env.TAG }}
name: 'httpsnippet v${{ env.TAG }} 📦'
generateReleaseNotes: true
prerelease: false
draft: false