Skip to content

Commit

Permalink
Ready for publish (#81)
Browse files Browse the repository at this point in the history
* Ready for publish

* Using node v20 in CI

* Remove unused readme

* Updated package manager

* updated
  • Loading branch information
jimmychu0807 committed Feb 16, 2024
1 parent db7898a commit b22f90b
Show file tree
Hide file tree
Showing 14 changed files with 4,262 additions and 7,329 deletions.
38 changes: 20 additions & 18 deletions .github/workflows/validate.yml
Original file line number Diff line number Diff line change
@@ -1,27 +1,29 @@
name: Yarn Validate
name: Validate
on:
pull_request:
push:
branches: [main]

jobs:
yarn-validate:
validate:
runs-on: ubuntu-latest
strategy:
matrix:
step: ['validate']
name: ${{ matrix.step }}
runs-on: ubuntu-latest
node-version: [20]
steps:
- uses: actions/checkout@v3
with:
lfs: true
submodules: 'recursive'

- uses: actions/setup-node@v3
with:
node-version: lts/hydrogen

- name: ${{ matrix.step }}
run: |
yarn install --immutable | grep -v 'YN0013'
yarn ${{ matrix.step }}
- uses: actions/checkout@v3
with:
lfs: true
submodules: "recursive"
- uses: pnpm/action-setup@v2
with:
version: 8
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node-version }}
cache: "pnpm"
- name: Validate
run: |
pnpm install
pnpm validate
1 change: 1 addition & 0 deletions .npmrc
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
engine-strict=true
1 change: 0 additions & 1 deletion .nvmrc

This file was deleted.

546 changes: 0 additions & 546 deletions .yarn/plugins/@yarnpkg/plugin-interactive-tools.cjs

This file was deleted.

9 changes: 0 additions & 9 deletions .yarn/plugins/@yarnpkg/plugin-typescript.cjs

This file was deleted.

28 changes: 0 additions & 28 deletions .yarn/plugins/@yarnpkg/plugin-workspace-tools.cjs

This file was deleted.

786 changes: 0 additions & 786 deletions .yarn/releases/yarn-3.2.1.cjs

This file was deleted.

11 changes: 0 additions & 11 deletions .yarnrc.yml

This file was deleted.

6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
# @jimmychu0807/aoc-2021

## 0.2.0

### Minor Changes

- Updated to use pnpm and completed all 25 days.

## 0.1.0

### Minor Changes
Expand Down
23 changes: 0 additions & 23 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -59,26 +59,3 @@ yarn docs:serve
```

- Do not update the root [`README.md`](https://github.com/jimmychu0807/advent-of-code-2021/blob/main/README.md) directly. Instead update [`scripts/templates/README.md.tpl`](https://github.com/jimmychu0807/advent-of-code-2021/blob/main/scripts/templates/README.md.tpl) as `scripts/doc-update.ts` will auto-generate the doc based on this template.

**For publishing packages**

```bash
# Contributor

yarn changeset add
yarn changeset version
yarn install
git add .
git commit -m "message"
git push <repo>
# Pull request to remote repo base branch

# Repo owner

# (Squash) Merge PR from contributor to base branch
yarn changeset publish
git push --follow-tags
```

For detail refer to: <https://github.com/changesets/changesets/blob/main/packages/cli/README.md>

43 changes: 24 additions & 19 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,44 +1,48 @@
{
"author": "Jimmy chu <jimmychu0807@gmail.com>",
"name": "@jimmychu0807/aoc-2021",
"author": "Jimmy chu <jimmychu0807@gmail.com>",
"version": "0.2.0",
"description": "Advent of Code 2021",
"license": "MIT",
"homepage": "https://jimmychu0807.github.io/advent-of-code-2021/",
"bugs": {
"url": "https://jimmychu0807.github.io/advent-of-code-2021/issues"
},
"repository": "https://github.com/jimmychu0807/advent-of-code-2021",
"repository": {
"type": "git",
"url": "https://github.com/jimmychu0807/advent-of-code-2021.git"
},
"keywords": [
"advent-of-code",
"2021"
],
"version": "0.1.0",
"type": "module",
"scripts": {
"build": "tsc -p .",
"postinstall": "yarn build",
"clean": "yarn del-cli -f dist tsconfig.tsbuildinfo",
"build:clean": "yarn clean && yarn build",
"postinstall": "pnpm build",
"clean": "pnpm del-cli -f dist tsconfig.tsbuildinfo",
"build:clean": "pnpm clean && pnpm build",
"lint": "eslint 'src/**/*.ts' 'scripts/**/*.ts' --ext .ts --max-warnings 0 && prettier --check --config .prettierrc 'src/**/*.ts' 'scripts/**/*.ts'",
"lint:fix": "yarn build && eslint 'src/**/*.ts' 'scripts/**/*.ts' --ext .ts --fix && prettier -w --config .prettierrc 'src/**/*.ts' 'scripts/**/*.ts'",
"lint:fix": "pnpm build && eslint 'src/**/*.ts' 'scripts/**/*.ts' --ext .ts --fix && prettier -w --config .prettierrc 'src/**/*.ts' 'scripts/**/*.ts'",
"test": "ts-mocha -p ./tsconfig.json -r tsconfig-paths/register 'src/**/*.test.ts'",
"cli": "ts-node src/index.ts",
"validate": "yarn build && yarn test && yarn lint",
"validate": "pnpm lint && pnpm build && pnpm test",
"docs:update": "ts-node scripts/docs-update.ts",
"docs:serve": "yarn docsify serve docs -o"
"docs:serve": "pnpm docsify serve docs -o"
},
"dependencies": {
"commander": "^9.4.0",
"debug": "^4.3.4"
},
"devDependencies": {
"@changesets/cli": "^2.24.2",
"@tsconfig/node16-strictest": "^1.0.3",
"@changesets/cli": "^2.27.1",
"@tsconfig/node20": "^20.1.2",
"@types/chai": "^4.3.4",
"@types/debug": "^4.1.7",
"@types/mocha": "^10.0.1",
"@types/node": "^16.11.43",
"@typescript-eslint/eslint-plugin": "^5.27.1",
"@typescript-eslint/parser": "^5.27.1",
"@types/node": "^18.18.6",
"@typescript-eslint/eslint-plugin": "^6.7.5",
"@typescript-eslint/parser": "^6.7.5",
"chai": "^4.3.7",
"del-cli": "^5.0.0",
"docsify-cli": "^4.4.4",
Expand All @@ -47,21 +51,22 @@
"mocha": "^10.2.0",
"prettier": "^2.7.1",
"ts-mocha": "^10.0.0",
"ts-node": "^10.8.1",
"ts-node": "^10.9.1",
"tsconfig-paths": "^4.1.1",
"typescript": "^4.7.3"
"typescript": "^5.2.2"
},
"exports": "src/index.ts",
"main": "src/index.ts",
"files": [
"dist"
],
"engines": {
"node": ">=20"
},
"publishConfig": {
"access": "public",
"registry": "https://registry.npmjs.org",
"bin": "dist/index.js",
"main": "dist/index.js"
},
"license": "MIT",
"packageManager": "yarn@3.2.1"
}
}

0 comments on commit b22f90b

Please sign in to comment.