Skip to content

Commit

Permalink
Change prelease and release environments, skip snapshots for now
Browse files Browse the repository at this point in the history
  • Loading branch information
zencephalon committed Oct 24, 2023
1 parent 04d7600 commit d010260
Show file tree
Hide file tree
Showing 3 changed files with 38 additions and 36 deletions.
1 change: 1 addition & 0 deletions .github/workflows/prerelease.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ jobs:
prerelease:
name: Changests Prerelease
runs-on: ubuntu-latest
environment: release
# Permissions necessary for Changesets to push a new branch and open PRs
# (for automated Version Packages PRs), and request the JWT for provenance.
# More info: https://docs.github.com/en/actions/deployment/security-hardening-your-deployments/about-security-hardening-with-openid-connect#adding-permissions-settings
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ jobs:
version:
name: Release
runs-on: ubuntu-latest
environment: release
permissions:
contents: write
pull-requests: write
Expand Down
72 changes: 36 additions & 36 deletions .github/workflows/snapshot.yml
Original file line number Diff line number Diff line change
@@ -1,42 +1,42 @@
name: Snapshot release
# name: Snapshot release

# Releases a snapshot release when new commits merge to main
# This ensures the release process is working as expected
on:
workflow_dispatch:
push:
branches:
- main
# # Releases a snapshot release when new commits merge to main
# # This ensures the release process is working as expected
# on:
# workflow_dispatch:
# push:
# branches:
# - main

jobs:
release-snapshot:
name: Publish snapshot release to npm
runs-on: ubuntu-latest
environment: release
if: github.event_name != 'workflow_dispatch'
steps:
- name: Checkout
uses: actions/checkout@v3
with:
submodules: recursive
fetch-depth: 0
# jobs:
# release-snapshot:
# name: Publish snapshot release to npm
# runs-on: ubuntu-latest
# environment: release
# if: github.event_name != 'workflow_dispatch'
# steps:
# - name: Checkout
# uses: actions/checkout@v3
# with:
# submodules: recursive
# fetch-depth: 0

- name: Setup
uses: ./.github/actions/setup
# - name: Setup
# uses: ./.github/actions/setup

- name: Set deployment token
run: npm config set '//registry.npmjs.org/:_authToken' "${NPM_TOKEN}"
env:
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
# - name: Set deployment token
# run: npm config set '//registry.npmjs.org/:_authToken' "${NPM_TOKEN}"
# env:
# NPM_TOKEN: ${{ secrets.NPM_TOKEN }}

# Remove this once https://github.com/changesets/changesets/issues/1195 is addressed
- name: Temporarily exit pre-release mode to release a snapshot
run: pnpm changeset pre exit
# # Remove this once https://github.com/changesets/changesets/issues/1195 is addressed
# - name: Temporarily exit pre-release mode to release a snapshot
# run: pnpm changeset pre exit

- name: Publish snapshots
uses: seek-oss/changesets-snapshot@v0
with:
pre-publish: pnpm build
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
# - name: Publish snapshots
# uses: seek-oss/changesets-snapshot@v0
# with:
# pre-publish: pnpm build
# env:
# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
# NPM_TOKEN: ${{ secrets.NPM_TOKEN }}

0 comments on commit d010260

Please sign in to comment.