Skip to content

Commit

Permalink
cicd: add ability to use next release for snapshot
Browse files Browse the repository at this point in the history
  • Loading branch information
chmanie committed May 3, 2024
1 parent 8dc948e commit a3ccf1a
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 1 deletion.
10 changes: 10 additions & 0 deletions .github/workflows/release-snapshot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,11 @@ name: Release a snapshot
on:
# Only manual workflow trigger
workflow_dispatch:
inputs:
includeNext:
description: 'include "next" version of contracts'
default: 'true'
type: boolean

concurrency: ${{ github.workflow }}-${{ github.ref }}

Expand All @@ -21,6 +26,11 @@ jobs:
uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node-version }}
- name: Set relevant environment variables
run: |
if [[ ${{ github.event.inputs.includeNext }} == 'true' ]]; then
echo "COLONY_CONTRACTOR_INCLUDE_NEXT=true" >> $GITHUB_ENV
fi
- name: Create .npmrc (to be logged in for publishing)
run: |
cat << EOF > "$HOME/.npmrc"
Expand Down
1 change: 1 addition & 0 deletions packages/contractor/src/contractor.ts
Original file line number Diff line number Diff line change
Expand Up @@ -249,6 +249,7 @@ const buildTokenContracts = async (

const start = async () => {
const { argv } = yargs(hideBin(process.argv))
.env('COLONY_CONTRACTOR_')
.command('core', 'Make core contracts')
.command('colony', 'Make Colony contracts', {
tag: {
Expand Down
2 changes: 1 addition & 1 deletion packages/events/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@
"homepage": "https://docs.colony.io/develop",
"scripts": {
"build": "npm run clean && npm run compile-cjs && npm run compile-esm && npm run compile-types && npm run create-pkg-json",
"build-contracts": "contractor events -n -o ./src/contracts",
"build-contracts": "contractor events -o ./src/contracts",
"clean": "rimraf ./dist",
"compile-cjs": "tsc -p tsconfig.build.json --module commonjs --target es2015 --outDir dist/cjs",
"compile-esm": "tsc -p tsconfig.build.json --module esnext --target es2022 --outDir dist/esm",
Expand Down

0 comments on commit a3ccf1a

Please sign in to comment.