Skip to content

Commit 96acb88

Browse files
authored
Resurrection (#542)
* feat: modernization * fix: util.inspect in node 22 * fix: minor tweaks * fix: node 6 tests * feat: add support for typescript compiler * feat: modernize readme * feat: resolve compiler automatically from filename * docs: update readme * fix: tests on legacy node versions * fix: coffee script file extension
1 parent d9a1fde commit 96acb88

27 files changed

+4415
-4675
lines changed

.editorconfig

Lines changed: 0 additions & 20 deletions
This file was deleted.

.eslintignore

Lines changed: 0 additions & 4 deletions
This file was deleted.

.eslintrc.js

Lines changed: 0 additions & 19 deletions
This file was deleted.

.github/stale.yml

Lines changed: 0 additions & 18 deletions
This file was deleted.

.github/workflows/deploy-npm.yml

Lines changed: 57 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,57 @@
1+
name: Publish to npm
2+
3+
on:
4+
release:
5+
types: [created]
6+
workflow_dispatch:
7+
8+
jobs:
9+
test:
10+
runs-on: ubuntu-latest
11+
timeout-minutes: 10
12+
strategy:
13+
matrix:
14+
node-version: [22, 20, 18, 16]
15+
steps:
16+
- name: Checkout
17+
uses: actions/checkout@v4
18+
19+
- name: Setup Node
20+
uses: actions/setup-node@v4
21+
with:
22+
node-version: ${{ matrix.node-version }}
23+
cache: 'npm'
24+
25+
- name: Install dependencies
26+
run: npm ci
27+
28+
- name: Run unit tests
29+
run: npm test
30+
31+
publish:
32+
needs: test
33+
runs-on: ubuntu-latest
34+
steps:
35+
- name: Checkout
36+
uses: actions/checkout@v4
37+
38+
- name: Setup Node
39+
uses: actions/setup-node@v4
40+
with:
41+
node-version: 22
42+
registry-url: 'https://registry.npmjs.org'
43+
cache: 'npm'
44+
45+
- name: Install dependencies
46+
run: npm ci
47+
48+
- name: Build version
49+
run: npm run build:version
50+
51+
- name: Build
52+
run: npm run build
53+
54+
- name: Publish to npm
55+
run: npm publish --access public
56+
env:
57+
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}

.github/workflows/node-test.yml

Lines changed: 0 additions & 21 deletions
This file was deleted.

.github/workflows/test.yml

Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
name: Test
2+
3+
on:
4+
push:
5+
branches: '*'
6+
pull_request:
7+
branches: [master]
8+
workflow_dispatch:
9+
10+
jobs:
11+
test:
12+
runs-on: ubuntu-latest
13+
timeout-minutes: 10
14+
strategy:
15+
matrix:
16+
node-version: [22, 20, 18, 16, 14, 12, 10, 8]
17+
steps:
18+
- name: Checkout
19+
uses: actions/checkout@v4
20+
21+
- name: Setup Node
22+
uses: actions/setup-node@v4
23+
with:
24+
node-version: ${{ matrix.node-version }}
25+
cache: 'npm'
26+
27+
- name: Install dependencies
28+
if: ${{ matrix.node-version >= 8 }}
29+
run: npm ci
30+
31+
- name: Install dependencies (node < 8)
32+
if: ${{ matrix.node-version < 8 }}
33+
run: npm install --only=prod
34+
35+
- name: Run unit tests
36+
if: ${{ matrix.node-version >= 16 }}
37+
run: npm test
38+
39+
- name: Run unit tests (node < 16)
40+
if: ${{ matrix.node-version < 16 }}
41+
run: node scripts/legacy-test-runner.js
42+
43+
- name: Run unit tests (compilers)
44+
if: ${{ matrix.node-version >= 16 }}
45+
run: npm install typescript coffee-script --no-save && npm run test:compilers
46+

.gitignore

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,4 @@
11
/node_modules
22
.DS_Store
3-
.svn
4-
/node-*
5-
/test.js
6-
.vscode
3+
.vscode
4+
/test.js

.npmignore

Lines changed: 0 additions & 9 deletions
This file was deleted.

.prettierrc

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
{
2+
"semi": true,
3+
"trailingComma": "all",
4+
"singleQuote": true,
5+
"printWidth": 120,
6+
"tabWidth": 4,
7+
"bracketSpacing": true,
8+
"arrowParens": "avoid",
9+
"useTabs": true
10+
}

0 commit comments

Comments
 (0)