Skip to content

Commit

Permalink
fix: update dependencies to clean up yarn audit (#234)
Browse files Browse the repository at this point in the history
* fix: update dependencies to clean up yarn audit

BREAKING CHANGE: Update minimum node version to >=14

* build: more dependency bumps

* build: no more node 12 tests

* build: we can still support 12?

* Revert "build: we can still support 12?"

This reverts commit 1bb6207.

* Update package.json

Co-authored-by: Black-Hole <158blackhole@gmail.com>

---------

Co-authored-by: Black-Hole <158blackhole@gmail.com>
  • Loading branch information
MarshallOfSound and BlackHole1 committed Oct 31, 2023
1 parent cd7b6c0 commit 6ab6b88
Show file tree
Hide file tree
Showing 13 changed files with 1,679 additions and 3,018 deletions.
1 change: 0 additions & 1 deletion .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@ workflows:
- 18.16.0
- 16.20.0
- 14.21.3
- 12.22.12
- cfa/release:
requires:
- test
Expand Down
21 changes: 10 additions & 11 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
"license": "MIT",
"scripts": {
"build": "tsc && tsc -p tsconfig.esm.json",
"build:docs": "typedoc --out docs",
"build:docs": "typedoc --out docs src/index.ts",
"eslint": "eslint --ext .ts src test",
"jest": "jest --coverage",
"lint": "npm run prettier && npm run eslint",
Expand All @@ -19,11 +19,11 @@
"test:nonetwork": "npm run lint && npm run jest -- --testPathIgnorePatterns network.spec"
},
"files": [
"dist/*",
"dist/",
"README.md"
],
"engines": {
"node": ">=12"
"node": ">=14"
},
"dependencies": {
"debug": "^4.1.1",
Expand All @@ -38,7 +38,7 @@
"@continuous-auth/semantic-release-npm": "^3.0.0",
"@types/debug": "^4.1.4",
"@types/fs-extra": "^8.0.0",
"@types/jest": "^24.0.13",
"@types/jest": "^29.0.0",
"@types/node": "^12.20.55",
"@types/progress": "^2.0.3",
"@types/semver": "^6.2.0",
Expand All @@ -49,12 +49,12 @@
"eslint-plugin-import": "^2.22.1",
"eslint-plugin-jest": "< 24.0.0",
"husky": "^2.3.0",
"jest": "^24.8.0",
"lint-staged": "^8.1.7",
"jest": "^29.3.1",
"lint-staged": "^13.0.4",
"prettier": "^1.17.1",
"ts-jest": "^24.0.0",
"typedoc": "^0.17.2",
"typescript": "^3.8.0"
"ts-jest": "^29.0.0",
"typedoc": "^0.23.21",
"typescript": "^4.9.3"
},
"eslintConfig": {
"parser": "@typescript-eslint/parser",
Expand All @@ -78,8 +78,7 @@
"lint-staged": {
"*.ts": [
"eslint --fix",
"prettier --write",
"git add"
"prettier --write"
]
},
"keywords": [
Expand Down
2 changes: 2 additions & 0 deletions src/types.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
import { Downloader } from './Downloader';

export { Downloader };

// eslint-disable-next-line @typescript-eslint/no-explicit-any
export type DownloadOptions = any;

Expand Down
2 changes: 1 addition & 1 deletion src/utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ export function getHostArch(): string {

export function ensureIsTruthyString<T, K extends keyof T>(obj: T, key: K): void {
if (!obj[key] || typeof obj[key] !== 'string') {
throw new Error(`Expected property "${key}" to be provided as a string but it was not`);
throw new Error(`Expected property "${String(key)}" to be provided as a string but it was not`);
}
}

Expand Down
1 change: 1 addition & 0 deletions test/fixtures/electron-v1.0.0-darwin-arm64.zip
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
electron-v1.0.0-darwin-x64.zip
1 change: 1 addition & 0 deletions test/fixtures/electron-v1.3.3-darwin-arm64.zip
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
electron-v1.3.2-darwin-x64.zip
1 change: 1 addition & 0 deletions test/fixtures/electron-v1.3.5-darwin-arm64.zip
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
electron-v1.3.5-darwin-x64.zip
1 change: 1 addition & 0 deletions test/fixtures/electron-v2.0.10-darwin-arm64.zip
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
electron-v2.0.10-darwin-x64.zip
1 change: 1 addition & 0 deletions test/fixtures/electron-v2.0.3-darwin-arm64.zip
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
electron-v2.0.3-darwin-x64.zip
1 change: 1 addition & 0 deletions test/fixtures/electron-v2.0.9-darwin-arm64.zip
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
electron-v2.0.9-darwin-x64.zip
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
electron-v6.0.0-nightly.20190213-darwin-x64.zip
6 changes: 5 additions & 1 deletion test/utils.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,11 @@ describe('utils', () => {
describe('uname()', () => {
if (process.platform !== 'win32') {
it('should return the correct arch for your system', () => {
expect(uname()).toEqual('x86_64');
if (process.arch === 'arm64') {
expect(uname()).toEqual('arm64');
} else {
expect(uname()).toEqual('x86_64');
}
});
}
});
Expand Down
Loading

0 comments on commit 6ab6b88

Please sign in to comment.