Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add changesets release management #32

Merged
merged 1 commit into from
Sep 15, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 20 additions & 0 deletions .changeset/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
# Changesets

Hello and welcome! This folder has been automatically generated by `@changesets/cli`, a build tool that works
with multi-package repos, or single-package repos to help you version and publish your code. You can
find the full documentation for it [in our repository](https://github.com/changesets/changesets)

We have a quick list of common questions to get you started engaging with this project in
[our documentation](https://github.com/changesets/changesets/blob/main/docs/common-questions.md)

## Releases

Releases are automatically managed by the CI, and changesets are added to each PR before merge.

### Adding a changeset

The following command will create a changeset in your Pull Request

```
yarn changeset
```
11 changes: 11 additions & 0 deletions .changeset/config.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
{
"$schema": "https://unpkg.com/@changesets/[email protected]/schema.json",
"changelog": "@changesets/cli/changelog",
"commit": false,
"fixed": [],
"linked": [],
"access": "public",
"baseBranch": "main",
"updateInternalDependencies": "patch",
"ignore": []
}
15 changes: 15 additions & 0 deletions .changeset/new-beans-travel.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
---
'@envy/example-apollo': patch
'@envy/example-apollo-client': patch
'@envy/example-express': patch
'@envy/example-express-client': patch
'@envy/example-next': patch
'@envy/apollo': patch
'@envy/browser': patch
'@envy/client': patch
'@envy/core': patch
'@envy/nextjs': patch
'@envy/node': patch
---

Add changesets release management
18 changes: 13 additions & 5 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,16 +12,24 @@ jobs:
- uses: ./.github/actions/setup
- run: yarn lint

build:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: ./.github/actions/setup
- run: yarn build
- run: yarn test

test:
runs-on: ubuntu-latest
publish:
needs: [lint, test]
steps:
- uses: actions/checkout@v3
- uses: ./.github/actions/setup
- run: yarn test
- run: yarn build

- uses: changesets/action@v1
with:
version: yarn run changeset version
#publish: yarn run changeset publish
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
#NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
4 changes: 3 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,8 @@
"test": "turbo run test",
"example:apollo": "concurrently \"cd examples/apollo && yarn start\" \"wait-on tcp:4000 && (cd examples/apollo-client && yarn start)\"",
"example:express": "concurrently \"cd examples/express && yarn start\" \"wait-on tcp:4000 && (cd examples/express-client && yarn dev)\"",
"example:next": "cd examples/next && yarn && yarn dev"
"example:next": "cd examples/next && yarn && yarn dev",
"changeset": "changeset"
},
"workspaces": [
"packages/*",
Expand All @@ -28,6 +29,7 @@
"@types/jest": "^29.5.4",
"@typescript-eslint/eslint-plugin": "^6.6.0",
"@typescript-eslint/parser": "^6.6.0",
"@changesets/cli": "2.26.2",
"concurrently": "^8.2.1",
"eslint": "^8.48.0",
"eslint-config-prettier": "^9.0.0",
Expand Down
Loading