Skip to content

Commit

Permalink
feat: use runscript v2
Browse files Browse the repository at this point in the history
  • Loading branch information
fengmk2 committed Dec 10, 2024
1 parent dbeb971 commit e923786
Show file tree
Hide file tree
Showing 10 changed files with 13 additions and 108 deletions.
24 changes: 0 additions & 24 deletions .github/PULL_REQUEST_TEMPLATE.md

This file was deleted.

68 changes: 0 additions & 68 deletions .github/workflows/codeql-analysis.yml

This file was deleted.

11 changes: 4 additions & 7 deletions .github/workflows/nodejs.yml
Original file line number Diff line number Diff line change
@@ -1,18 +1,15 @@
name: CI
name: CI for 5.x

on:
push:
branches: [ master, 5.x ]

branches: [ 5.x ]
pull_request:
branches: [ master, 5.x ]

workflow_dispatch: {}
branches: [ 5.x ]

jobs:
Job:
name: Node.js
uses: node-modules/github-actions/.github/workflows/node-test.yml@master
with:
os: 'ubuntu-latest, macos-latest'
version: '14, 16, 18, 20'
version: '14, 16, 18, 20, 22'
2 changes: 1 addition & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
name: Release
on:
push:
branches: [ master, 5.x ]
branches: [ 5.x ]

jobs:
release:
Expand Down
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -33,3 +33,5 @@ yarn.lock
.c8_output
.idea
.eslintcache
dist
.package-lock.json
2 changes: 1 addition & 1 deletion bin/postinstall.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

const path = require('path');
const fs = require('fs');
const runscript = require('runscript');
const { runscript } = require('runscript');

// node posintall.js </path/to/egg-ts-helper/dist/bin> <framework-package-name>
const etsBinFile = process.argv[2] || require.resolve('egg-ts-helper/dist/bin');
Expand Down
2 changes: 1 addition & 1 deletion lib/cmd/dev.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
const debug = require('util').debuglog('egg-bin:dev');
const path = require('path');
const utils = require('egg-utils');
const detect = require('detect-port');
const { detect } = require('detect-port');
const Command = require('../command');

class DevCommand extends Command {
Expand Down
6 changes: 2 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -21,15 +21,15 @@
"c8": "^7.11.3",
"chalk": "^4.1.2",
"common-bin": "^3.0.0",
"detect-port": "^1.3.0",
"detect-port": "^2.1.0",
"egg-ts-helper": "^1.30.3",
"egg-utils": "^2.4.1",
"globby": "^11.1.0",
"inspector-proxy": "^1.2.2",
"jest-changed-files": "^28.0.2",
"mocha": "^10.0.0",
"mochawesome-with-mocha": "^7.1.3",
"runscript": "^1.5.3",
"runscript": "^2.0.1",
"test": "^3.0.0",
"ts-node": "^10.8.0",
"tsconfig-paths": "^4.1.1",
Expand Down Expand Up @@ -64,7 +64,6 @@
"esbuild-register": "^2.5.0",
"eslint": "^8.16.0",
"eslint-config-egg": "^12.0.0",
"git-contributor": "2",
"mm": "^3.2.0",
"typescript": "^5.0.4"
},
Expand All @@ -79,7 +78,6 @@
"author": "fengmk2 <[email protected]> (https://github.com/fengmk2)",
"scripts": {
"postinstall": "node bin/postinstall.js",
"contributor": "git-contributor",
"lint": "eslint .",
"test": "npm run lint -- --fix && npm run test-local",
"test-local": "node bin/egg-bin.js test -t 120000",
Expand Down
2 changes: 1 addition & 1 deletion test/lib/cmd/debug.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ const path = require('path');
const coffee = require('coffee');
const mm = require('egg-mock');
const net = require('net');
const detect = require('detect-port');
const { detect } = require('detect-port');

describe('test/lib/cmd/debug.test.js', () => {
const eggBin = require.resolve('../../../bin/egg-bin.js');
Expand Down
2 changes: 1 addition & 1 deletion test/lib/cmd/dev.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ const path = require('path');
const coffee = require('coffee');
const net = require('net');
const mm = require('mm');
const detect = require('detect-port');
const { detect } = require('detect-port');
const version = Number(process.version.substring(1, 3));

describe('test/lib/cmd/dev.test.js', () => {
Expand Down

0 comments on commit e923786

Please sign in to comment.