Skip to content

Commit 4a02b5a

Browse files
committed
chore: switch to release-it
1 parent 13d175a commit 4a02b5a

13 files changed

+37
-82
lines changed

.autorc.json

-10
This file was deleted.

.github/workflows/first-interaction.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -11,4 +11,4 @@ jobs:
1111
- uses: actions/first-interaction@v1
1212
with:
1313
repo-token: ${{ secrets.GITHUB_TOKEN }}
14-
pr-message: 'Welcome to Vega. Since this is your first contribution, please make sure to read the [contributing guide](https://github.com/vega/vega-lite/blob/next/CONTRIBUTING.md).'
14+
pr-message: 'Welcome to Vega. Since this is your first contribution, please make sure to read the [contributing guide](https://github.com/vega/vega-lite/blob/main/CONTRIBUTING.md).'

.github/workflows/publish-to-npm.yml

-45
This file was deleted.

.prettierignore

+1
Original file line numberDiff line numberDiff line change
@@ -4,3 +4,4 @@ examples/specs/*.vl.json
44
site/_includes/*
55
site/examples/*
66
site/_site/*
7+
CHANGELOG.md

.release-it.json

+16
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
{
2+
"git": {
3+
"commitMessage": "chore: release v${version}"
4+
},
5+
"github": {
6+
"release": true
7+
},
8+
"hooks": {
9+
"after:bump": "yarn build"
10+
},
11+
"plugins": {
12+
"@release-it/conventional-changelog": {
13+
"infile": "CHANGELOG.md"
14+
}
15+
}
16+
}

CONTRIBUTING.md

+3-9
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ You can find [tasks with the "Good first issue" label in the issue tracker :pray
4242

4343
The website is under `site/` and the documentation is under `site/docs/`. We use GitHub Pages to publish our documentation when we release a new version. To contribute changes to the documentation or website, simply submit a pull request that changes the corresponding markdown files in `site/`.
4444

45-
Since we only publish the GitHub Pages when we release a new version, it might be slightly outdated compared to `next`. For development, once you have [setup the repository](#repository-setup), you can run `yarn site` to serve the GitHub page locally at [http://localhost:4000/vega-lite/](http://localhost:4000/vega-lite/).
45+
Since we only publish the GitHub Pages when we release a new version, it might be slightly outdated compared to `main`. For development, once you have [setup the repository](#repository-setup), you can run `yarn site` to serve the GitHub page locally at [http://localhost:4000/vega-lite/](http://localhost:4000/vega-lite/).
4646

4747
Note that when you checkout different branches, the compiled JavaScript for the website might be reset. You might have to run `yarn build:site` to recompile the JavaScript so that interactive examples work.
4848

@@ -194,15 +194,9 @@ During development, it can be convenient to rebuild automatically or to run test
194194

195195
`yarn site`. See details in [Documentation and Website](#documentation-and-website).
196196

197-
### Deployment
197+
### Publishing
198198

199-
Publishing is handled by a 2-branch [pre-release process](https://intuit.github.io/auto/docs/generated/shipit#next-branch-default), configured in `publish-to-npm.yml`. All changes should be based off the default `next` branch, and are published automatically.
200-
201-
- PRs made into the default branch are auto-deployed to the `next` pre-release tag on NPM. The result can be installed with `npm install vega-lite/@next`.
202-
- When merging into `next`, please use the `squash and merge` strategy.
203-
- To release a new stable version, open a PR from `next` into `stable` using this [compare link](https://github.com/vega/vega-lite/compare/stable...next).
204-
- When merging from `next` into `stable`, please use the `create a merge commit` strategy.
205-
- After the release note is generated (from commits), please take a look to clean up so the log is readable to the community.
199+
To make a release, run `npm run release`. After the release notes are generated (from commits), please take a look to clean up so they are readable to the community. Triggered by the GitHub release, the CI will automatically deploy the website and update the schema repo.
206200

207201
## Suggested Programming Environment.
208202

README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Vega-Lite <a href="https://vega.github.io/vega-lite/"><img align="right" src="https://github.com/vega/logos/blob/master/assets/[email protected]?raw=true" height="38"></img></a>
22

3-
[![npm version](https://img.shields.io/npm/v/vega-lite.svg)](https://www.npmjs.com/package/vega-lite) [![Build Status](https://github.com/vega/vega-lite/workflows/Test/badge.svg)](https://github.com/vega/vega-lite/actions) [![codecov](https://codecov.io/gh/vega/vega-lite/branch/next/graph/badge.svg)](https://codecov.io/gh/vega/vega-lite) [![code style: prettier](https://img.shields.io/badge/code_style-prettier-ff69b4.svg?style=rounded)](https://github.com/prettier/prettier) [![JSDevlivr](https://data.jsdelivr.com/v1/package/npm/vega-lite/badge?style=rounded)](https://www.jsdelivr.com/package/npm/vega-lite)
3+
[![npm version](https://img.shields.io/npm/v/vega-lite.svg)](https://www.npmjs.com/package/vega-lite) [![Build Status](https://github.com/vega/vega-lite/workflows/Test/badge.svg)](https://github.com/vega/vega-lite/actions) [![codecov](https://codecov.io/gh/vega/vega-lite/branch/main/graph/badge.svg)](https://codecov.io/gh/vega/vega-lite) [![code style: prettier](https://img.shields.io/badge/code_style-prettier-ff69b4.svg?style=rounded)](https://github.com/prettier/prettier) [![JSDevlivr](https://data.jsdelivr.com/v1/package/npm/vega-lite/badge?style=rounded)](https://www.jsdelivr.com/package/npm/vega-lite)
44

55
![Teaser](site/static/teaser.png)
66

package.json

+8-10
Original file line numberDiff line numberDiff line change
@@ -71,8 +71,7 @@
7171
"watch:site": "yarn build:site -w",
7272
"watch:test": "yarn jest --watch test/",
7373
"watch:test:runtime": "NODE_OPTIONS=--experimental-vm-modules TZ=America/Los_Angeles npx jest --watch test-runtime/ --config test-runtime/jest-config.json",
74-
"release": "yarn run prebuild && yarn build && yarn shipit",
75-
"shipit": "auto shipit"
74+
"release": "yarn release-it"
7675
},
7776
"repository": {
7877
"type": "git",
@@ -83,47 +82,46 @@
8382
"url": "https://github.com/vega/vega-lite/issues"
8483
},
8584
"devDependencies": {
86-
"@auto-it/conventional-commits": "^10.37.6",
87-
"@auto-it/first-time-contributor": "^10.37.6",
8885
"@babel/core": "^7.19.1",
8986
"@babel/preset-env": "^7.19.1",
9087
"@babel/preset-typescript": "^7.18.6",
88+
"@release-it/conventional-changelog": "^5.1.1",
9189
"@rollup/plugin-alias": "^4.0.0",
9290
"@rollup/plugin-babel": "^6.0.0",
9391
"@rollup/plugin-commonjs": "^24.0.0",
9492
"@rollup/plugin-json": "^6.0.0",
9593
"@rollup/plugin-node-resolve": "^15.0.1",
94+
"@rollup/plugin-terser": "^0.4.0",
9695
"@types/chai": "^4.3.3",
9796
"@types/d3": "^7.4.0",
9897
"@types/jest": "^27.4.1",
9998
"@types/mkdirp": "^1.0.2",
10099
"@types/pako": "^2.0.0",
101100
"@typescript-eslint/eslint-plugin": "^5.38.0",
102101
"@typescript-eslint/parser": "^5.38.0",
103-
"ajv": "^8.11.0",
104102
"ajv-formats": "^2.1.1",
105-
"auto": "^10.37.6",
103+
"ajv": "^8.11.0",
106104
"chai": "^4.3.6",
107105
"cheerio": "^1.0.0-rc.12",
108106
"conventional-changelog-cli": "^2.2.2",
109107
"d3": "^7.6.1",
110108
"del-cli": "^5.0.0",
111-
"eslint": "^8.23.1",
112109
"eslint-config-prettier": "^8.5.0",
113110
"eslint-plugin-jest": "^27.0.4",
114111
"eslint-plugin-prettier": "^4.2.1",
112+
"eslint": "^8.23.1",
115113
"gh-pages": "^5.0.0",
116114
"highlight.js": "^11.6.0",
117-
"jest": "^27.5.1",
118115
"jest-dev-server": "^6.1.1",
116+
"jest": "^27.5.1",
119117
"mkdirp": "^2.1.3",
120118
"pako": "^2.0.4",
121119
"prettier": "^2.7.1",
122120
"puppeteer": "^15.0.0",
123-
"rollup": "^2.79.1",
121+
"release-it": "^15.6.0",
124122
"rollup-plugin-bundle-size": "^1.0.3",
125123
"rollup-plugin-sourcemaps": "^0.6.3",
126-
"rollup-plugin-terser": "^7.0.2",
124+
"rollup": "^2.79.1",
127125
"serve": "^14.0.1",
128126
"terser": "^5.15.0",
129127
"ts-jest": "^29.0.1",

rollup.config.js

+3-2
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,11 @@
1+
import alias from '@rollup/plugin-alias';
12
import babel from '@rollup/plugin-babel';
23
import commonjs from '@rollup/plugin-commonjs';
34
import json from '@rollup/plugin-json';
45
import resolve from '@rollup/plugin-node-resolve';
5-
import alias from '@rollup/plugin-alias';
6+
import terser from '@rollup/plugin-terser';
67
import bundleSize from 'rollup-plugin-bundle-size';
7-
import {terser} from 'rollup-plugin-terser';
8+
89
import pkg from './package.json';
910

1011
export function disallowedImports() {

scripts/check-and-commit-toc.sh

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ set -euo pipefail
55
GIT_BRANCH="${GITHUB_REF/refs\/heads\//}"
66

77
# Only push on human pull request branches. Exclude release, prerelease, and bot branches.
8-
if [ "$GIT_BRANCH" != "stable" ] && [ "$GIT_BRANCH" != "next" ] && [[ "$GIT_BRANCH" != dependabot/* ]]; then
8+
if [ "$GIT_BRANCH" != "stable" ] && [ "$GIT_BRANCH" != "main" ] && [[ "$GIT_BRANCH" != dependabot/* ]]; then
99
PUSH_BRANCH=true
1010
echo "Will try to push changes."
1111
else

scripts/check-and-commit.sh

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ set -euo pipefail
55
GIT_BRANCH="${GITHUB_REF/refs\/heads\//}"
66

77
# Only push on human pull request branches. Exclude release, prerelease, and bot branches.
8-
if [ "$GIT_BRANCH" != "stable" ] && [ "$GIT_BRANCH" != "next" ] && [[ "$GIT_BRANCH" != dependabot/* ]]; then
8+
if [ "$GIT_BRANCH" != "stable" ] && [ "$GIT_BRANCH" != "main" ] && [[ "$GIT_BRANCH" != dependabot/* ]]; then
99
PUSH_BRANCH=true
1010
echo "Will try to push changes."
1111
else

site/ecosystem.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ permalink: /ecosystem.html
66
redirect_from: /applications.html
77
---
88

9-
This is an incomplete list of integrations, applications, and extensions of the Vega-Lite language and compiler. If you want to add a tool or library, [edit this file and send us a pull request](https://github.com/vega/vega-lite/blob/next/site/ecosystem.md).
9+
This is an incomplete list of integrations, applications, and extensions of the Vega-Lite language and compiler. If you want to add a tool or library, [edit this file and send us a pull request](https://github.com/vega/vega-lite/blob/main/site/ecosystem.md).
1010

1111
We mark featured plugins and tools with a <span class="octicon octicon-star"></span>.
1212

site/rollup.config.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,8 @@ import babel from '@rollup/plugin-babel';
22
import commonjs from '@rollup/plugin-commonjs';
33
import json from '@rollup/plugin-json';
44
import nodeResolve from '@rollup/plugin-node-resolve';
5+
import terser from '@rollup/plugin-terser';
56
import bundleSize from 'rollup-plugin-bundle-size';
6-
import {terser} from 'rollup-plugin-terser';
77

88
const watch = process.env.ROLLUP_WATCH;
99

0 commit comments

Comments
 (0)