remove userOutputs tool, it wasn't very useful #6
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: CI | |
on: | |
pull_request: | |
branches: | |
- main | |
push: | |
branches-ignore: | |
- main | |
jobs: | |
build-and-test: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v3 | |
with: | |
fetch-depth: 0 | |
- name: Setup Node.js | |
uses: actions/setup-node@v3 | |
with: | |
node-version: 18 | |
- name: Install pnpm | |
uses: pnpm/action-setup@v2 | |
with: | |
version: 8.9.0 | |
- name: Install dependencies | |
run: pnpm install | |
- name: Build | |
run: pnpm build | |
- name: Test | |
run: pnpm test | |
- name: Check for changeset | |
run: | | |
# Only run this check on pull requests | |
if [[ $GITHUB_EVENT_NAME == 'pull_request' ]]; then | |
# Check if there are any changes to source files | |
if git diff --name-only origin/main HEAD | grep -q '^src/'; then | |
echo "Changes detected in src directory. Checking for changeset..." | |
# This will exit with non-zero if a changeset is needed but not present | |
pnpm changeset status | |
else | |
echo "No changes to src directory detected. Skipping changeset check." | |
fi | |
else | |
echo "Not a pull request. Skipping changeset check." | |
fi |