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

chore: upgrade [email protected] #219

Draft
wants to merge 4 commits into
base: main
Choose a base branch
from
Draft
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
28 changes: 17 additions & 11 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,34 +2,40 @@ name: CI

on:
push:
branches: [master]
branches: [main]
pull_request:
branches: [master]
branches: [main]

jobs:
test:
name: 'Test'
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [14.x, 16.x]
node-version: [18, 20, 22]
steps:
- name: Checkout
uses: actions/checkout@v2

- name: Setup pnpm
uses: pnpm/[email protected]
with:
version: 7
uses: actions/checkout@v4

- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v2
uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
cache: 'pnpm'

- name: Use pnpm
run: corepack enable pnpm && pnpm --version

- name: Install dependencies
run: pnpm install

- name: Run Prettier check
run: pnpm run prettier-check

- name: Run ESLint check
run: pnpm run eslint-check

- name: Run TypeScript type check
run: pnpm run type-check

- name: Run tests
run: pnpm test
80 changes: 0 additions & 80 deletions .github/workflows/quality.yml

This file was deleted.

1 change: 1 addition & 0 deletions .prettierignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
pnpm-lock.yaml
39 changes: 20 additions & 19 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,40 +3,32 @@
"version": "3.0.0-canary.1",
"description": "Tiny millisecond conversion utility",
"repository": "vercel/ms",
"main": "./dist/index.cjs",
"license": "MIT",
"sideEffects": false,
"type": "module",
"exports": {
"types": "./dist/index.d.ts",
"import": "./dist/index.mjs",
"require": "./dist/index.cjs"
},
"main": "./dist/index.cjs",
"module": "./dist/index.mjs",
"types": "./dist/index.d.ts",
"sideEffects": false,
"license": "MIT",
"engines": {
"node": ">=12.13"
},
"files": [
"dist"
],
"scripts": {
"test": "npm run test-nodejs && npm run test-edge",
"test-nodejs": "jest --env node",
"test-edge": "jest --env @edge-runtime/jest-environment",
"build": "scripts/build.js",
"prepublishOnly": "npm run build",
"eslint-check": "eslint --max-warnings=0 .",
"prettier-check": "prettier --check .",
"type-check": "tsc --noEmit",
"precommit": "lint-staged",
"prepare": "husky install"
},
"jest": {
"preset": "ts-jest",
"testEnvironment": "node"
"prepare": "husky install",
"prepublishOnly": "npm run build",
"prettier-check": "prettier --check .",
"test": "npm run test-nodejs && npm run test-edge",
"test-edge": "jest --env @edge-runtime/jest-environment",
"test-nodejs": "jest --env node",
"type-check": "tsc --noEmit"
},
"prettier": "@vercel/style-guide/prettier",
"lint-staged": {
"*": [
"prettier --ignore-unknown --write"
Expand All @@ -45,16 +37,25 @@
"eslint --max-warnings=0 --fix"
]
},
"prettier": "@vercel/style-guide/prettier",
"jest": {
"preset": "ts-jest",
"testEnvironment": "node"
},
"devDependencies": {
"@edge-runtime/jest-environment": "1.1.0-beta.6",
"@types/jest": "27.0.1",
"@vercel/style-guide": "3.0.0",
"@vercel/style-guide": "6.0.0",
"eslint": "8.12.0",
"husky": "7.0.2",
"jest": "27.1.1",
"lint-staged": "11.1.2",
"prettier": "2.6.2",
"ts-jest": "27.0.5",
"typescript": "4.6.3"
},
"packageManager": "[email protected]",
"engines": {
"node": ">=12.13"
}
}
Loading
Loading