Skip to content

Commit

Permalink
feat: Add changesets & Replace release-it
Browse files Browse the repository at this point in the history
  • Loading branch information
wottpal committed Oct 15, 2023
1 parent 84bcc23 commit dabf972
Show file tree
Hide file tree
Showing 6 changed files with 1,730 additions and 3,115 deletions.
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/changelog-github", { "repo": "scio-labs/use-inkathon" }],
"commit": true,
"fixed": [],
"linked": [],
"access": "restricted",
"baseBranch": "main",
"updateInternalDependencies": "patch",
"ignore": []
}
50 changes: 50 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
# yaml-language-server: $schema=https://json.schemastore.org/github-workflow.json
name: Release

on:
push:
branches:
- main

concurrency: ${{ github.workflow }}-${{ github.ref }}

jobs:
release:
name: Release
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [18]
pnpm-version: [8.8]
steps:
- name: Checkout Repo
uses: actions/checkout@v3
with:
# This makes Actions fetch all Git history so that Changesets can generate changelogs with the correct commits
fetch-depth: 0
submodules: true

- name: Set up pnpm action ${{ matrix.pnpm-version }}
uses: pnpm/action-setup@v2
with:
version: ${{ matrix.pnpm-version }}

- name: Set up Node ${{ matrix.node-version }}
uses: actions/setup-node@v3
with:
cache: 'pnpm'
node-version: ${{ matrix.node-version }}

- name: Install Dependencies
run: pnpm install --lockfile-only

- name: Create Release Pull Request
uses: changesets/action@v1
with:
title: 'chore(changeset): Bump package version'
commit: 'chore(changeset): Bump package version'
version: pnpm run changeset:version
publish: pnpm run changeset:publish
env:
GITHUB_TOKEN: ${{ secrets.CHANGESETS_PAT }}
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
2 changes: 1 addition & 1 deletion .nvmrc
Original file line number Diff line number Diff line change
@@ -1 +1 @@
v16
v18
9 changes: 0 additions & 9 deletions .release-it.json

This file was deleted.

34 changes: 18 additions & 16 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,34 +28,36 @@
"dist"
],
"scripts": {
"build": "tsup && pnpm typedoc",
"typedoc": "typedoc src/index.ts --titleLink \"https://github.com/scio-labs/use-inkathon\"",
"dev": "tsup --watch",
"lint": "prettier . --check && pnpm eslint",
"lint:fix": "prettier . --write && pnpm eslint --fix",
"prepare": "husky install"
"build": "tsup",
"typedoc": "typedoc src/index.ts --titleLink \"https://github.com/scio-labs/use-inkathon\"",
"changeset:version": "pnpm run typedoc && changeset version",
"changeset:publish": "pnpm run build && changeset publish"
},
"peerDependencies": {
"@polkadot/api": ">=9.14.0",
"@polkadot/api-contract": ">=9.14.0",
"@polkadot/extension-inject": ">=0.44.0",
"@polkadot/types": ">=9.14.0",
"@polkadot/util": ">=10.4.0",
"react": ">=18.0.0",
"react-dom": ">=18.0.0"
"@polkadot/api": ">=10",
"@polkadot/api-contract": ">=10",
"@polkadot/extension-inject": ">=0.46",
"@polkadot/types": ">=10",
"@polkadot/util": ">=10",
"react": ">=18",
"react-dom": ">=18"
},
"devDependencies": {
"@changesets/changelog-github": "^0.4.8",
"@changesets/cli": "^2.26.2",
"@types/node": "^18.17.14",
"@types/react": "^18.2.21",
"@typescript-eslint/eslint-plugin": "^5.62.0",
"@typescript-eslint/parser": "^5.62.0",
"@typescript-eslint/eslint-plugin": "^6.7.5",
"@typescript-eslint/parser": "^6.7.5",
"eslint": "^8.48.0",
"eslint-config-prettier": "^8.10.0",
"eslint-config-prettier": "^9.0.0",
"eslint-plugin-react": "^7.33.2",
"husky": "^8.0.3",
"lint-staged": "^14.0.1",
"prettier": "^2.8.8",
"release-it": "^16.1.5",
"lint-staged": "^15.0.1",
"prettier": "^3.0.3",
"tsup": "^7.2.0",
"typedoc": "^0.25.1",
"typescript": "^5.2.2"
Expand Down
Loading

0 comments on commit dabf972

Please sign in to comment.