Skip to content

Commit

Permalink
Replaced Python extraction script with JS (#1570)
Browse files Browse the repository at this point in the history
  • Loading branch information
xPaw committed Apr 12, 2022
1 parent 11c988c commit 8db96d4
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 11 deletions.
10 changes: 10 additions & 0 deletions deps/extract.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
const tar = require("tar");
const path = require("path");
const tarball = path.resolve(process.argv[2]);
const dirname = path.resolve(process.argv[3]);

tar.extract({
sync: true,
file: tarball,
cwd: dirname,
});
9 changes: 0 additions & 9 deletions deps/extract.py

This file was deleted.

2 changes: 1 addition & 1 deletion deps/sqlite3.gyp
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@
'outputs': [
'<(SHARED_INTERMEDIATE_DIR)/sqlite-autoconf-<@(sqlite_version)/sqlite3.c'
],
'action': ['<!(node -p "process.env.PYTHON")','./extract.py','./sqlite-autoconf-<@(sqlite_version).tar.gz','<(SHARED_INTERMEDIATE_DIR)']
'action': ['node','./extract.js','./sqlite-autoconf-<@(sqlite_version).tar.gz','<(SHARED_INTERMEDIATE_DIR)']
}
],
'direct_dependent_settings': {
Expand Down
3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,8 @@
},
"dependencies": {
"@mapbox/node-pre-gyp": "^1.0.0",
"node-addon-api": "^4.2.0"
"node-addon-api": "^4.2.0",
"tar": "^6.1.11"
},
"devDependencies": {
"eslint": "^7.32.0",
Expand Down

0 comments on commit 8db96d4

Please sign in to comment.