Skip to content

Commit

Permalink
chore: run yarn upgrade
Browse files Browse the repository at this point in the history
  • Loading branch information
pmowrer committed Jan 12, 2024
1 parent 8d7a71c commit 2f6282a
Show file tree
Hide file tree
Showing 4 changed files with 2,234 additions and 2,988 deletions.
14 changes: 14 additions & 0 deletions .github/workflows/release-preview.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
name: Release preview
on: [pull_request]
jobs:
run-semantic-release-github-pr:
runs-on: ubuntu-latest
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: 18
- run: git checkout -b ${{ github.head_ref }}
- run: unset GITHUB_ACTIONS && yarn && node ./bin/semantic-release-github-pr --debug --branches ${{ github.head_ref }}
11 changes: 11 additions & 0 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
name: Tests
on: [pull_request]
jobs:
run-tests:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: 18
- run: yarn && yarn test
7 changes: 1 addition & 6 deletions bin/semantic-release-github-pr.js
Original file line number Diff line number Diff line change
@@ -1,25 +1,20 @@
#!/usr/bin/env node
const execa = require('execa');
const envCi = require('env-ci');
const { argv } = process;
const { resolve } = require('path');
const { getCurrentBranchName } = require('../src/git-utils');

(async function() {
const plugins = `${resolve(__dirname, '../src/index.js')}`;
const currentBranchName = await getCurrentBranchName();
// If we're in a "detached HEAD" state, assume we're running on CI.
const branch =
currentBranchName !== 'HEAD' ? currentBranchName : envCi().prBranch;

const args = argv.slice(2).concat([
// We want to run on pull request builds, but `semantic-release` won't
// let us unless we pass `--no-ci`.
// https://github.com/semantic-release/semantic-release/issues/584
`--no-ci`,
// Set `dry-run` to keep `semantic-release` from publishing an actual release.
`--dry-run`,
`--branches=${branch}`,
`--branches=${currentBranchName}`,
`--extends=${plugins}`,
]);

Expand Down
Loading

0 comments on commit 2f6282a

Please sign in to comment.