Skip to content

Commit 51e3c23

Browse files
authored
Merge pull request #102 from uber/cc
Add changesets
2 parents 4cd6621 + 033ad02 commit 51e3c23

File tree

8 files changed

+1460
-5
lines changed

8 files changed

+1460
-5
lines changed

.changeset/README.md

+8
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
# Changesets
2+
3+
Hello and welcome! This folder has been automatically generated by `@changesets/cli`, a build tool that works
4+
with multi-package repos, or single-package repos to help you version and publish your code. You can
5+
find the full documentation for it [in our repository](https://github.com/changesets/changesets)
6+
7+
We have a quick list of common questions to get you started engaging with this project in
8+
[our documentation](https://github.com/changesets/changesets/blob/main/docs/common-questions.md)

.changeset/config.json

+11
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
{
2+
"$schema": "https://unpkg.com/@changesets/[email protected]/schema.json",
3+
"changelog": ["@changesets/changelog-github", { "repo": "uber/react-view" }],
4+
"commit": false,
5+
"fixed": [],
6+
"linked": [],
7+
"access": "public",
8+
"baseBranch": "master",
9+
"updateInternalDependencies": "patch",
10+
"ignore": []
11+
}

.changeset/hungry-wolves-laugh.md

+5
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"react-view": major
3+
---
4+
5+
No breaking changes really, just bumping all dependencies and modernizing the tooling. Live code that has export default gets wrapped by an additional IIEF, so you can have other variables defined at the root scope.

.github/workflows/ci.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ name: CI
22

33
on:
44
push:
5-
branches: ["main"]
5+
branches: ["master"]
66
pull_request:
77
types: [opened, synchronize]
88

.github/workflows/release.yml

+54
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,54 @@
1+
name: Release
2+
3+
on:
4+
push:
5+
branches:
6+
- master
7+
8+
concurrency: ${{ github.workflow }}-${{ github.ref }}
9+
10+
jobs:
11+
release:
12+
name: Release
13+
runs-on: ubuntu-latest
14+
permissions:
15+
contents: write
16+
pull-requests: write
17+
id-token: write
18+
steps:
19+
- name: Checkout Repo
20+
uses: actions/checkout@v3
21+
with:
22+
# This makes Actions fetch all Git history so that Changesets can generate changelogs with the correct commits
23+
fetch-depth: 0
24+
25+
- uses: pnpm/[email protected]
26+
with:
27+
version: 8.7.1
28+
29+
- name: Setup Node.js environment
30+
uses: actions/setup-node@v3
31+
with:
32+
node-version: 20.5
33+
cache: "pnpm"
34+
35+
- name: Install dependencies
36+
run: pnpm install --frozen-lockfile
37+
38+
- name: Creating .npmrc
39+
run: |
40+
cat << EOF > "$HOME/.npmrc"
41+
42+
//registry.npmjs.org/:_authToken=$NPM_TOKEN
43+
EOF
44+
env:
45+
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
46+
47+
- name: Create Release Pull Request or Publish to npm
48+
id: changesets
49+
uses: changesets/action@v1
50+
with:
51+
publish: pnpm build && pnpm changeset publish
52+
env:
53+
GITHUB_TOKEN: ${{ secrets.GIT_DEPLOY_KEY }}
54+
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}

commitlint.config.js

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
module.exports = { extends: ["@commitlint/config-conventional"] };

package.json

+12
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,14 @@
1515
"files": [
1616
"dist"
1717
],
18+
"packageManager": "[email protected]",
19+
"publishConfig": {
20+
"access": "public",
21+
"provenance": true
22+
},
23+
"engines": {
24+
"node": ">=18.0.0"
25+
},
1826
"author": "Vojtech Miksu <[email protected]>",
1927
"repository": "uber/react-view",
2028
"license": "MIT",
@@ -49,6 +57,10 @@
4957
},
5058
"devDependencies": {
5159
"@babel/preset-typescript": "^7.23.3",
60+
"@changesets/changelog-github": "^0.5.0",
61+
"@changesets/cli": "^2.27.1",
62+
"@commitlint/cli": "^18.4.3",
63+
"@commitlint/config-conventional": "^18.4.3",
5264
"@ladle/react": "^4.0.0",
5365
"@playwright/test": "^1.40.0",
5466
"@types/babel__code-frame": "^7.0.6",

0 commit comments

Comments
 (0)