mirror of
https://github.com/ArchiveBox/ArchiveBox.git
synced 2025-05-14 23:24:30 -04:00
ominous warnings
This commit is contained in:
parent
aa53fe653c
commit
e0a2b2e252
1 changed files with 9 additions and 7 deletions
|
@ -984,16 +984,18 @@ def setup(out_dir: Path=OUTPUT_DIR) -> None:
|
|||
elif path.is_file():
|
||||
os.remove(path)
|
||||
|
||||
shutil.copyfile(PACKAGE_DIR / 'package.json', out_dir / 'package.json')
|
||||
shutil.copyfile(PACKAGE_DIR / 'package.json', out_dir / 'package.json') # copy the js requirements list from the source install into the data dir
|
||||
# lets blindly assume that calling out to npm via shell works reliably cross-platform 🤡 (until proven otherwise via support tickets)
|
||||
run_shell([
|
||||
'npm',
|
||||
'install',
|
||||
'--prefix', str(out_dir),
|
||||
'--force',
|
||||
'--no-save',
|
||||
'--no-audit',
|
||||
'--no-fund',
|
||||
'--loglevel', 'error',
|
||||
'--prefix', str(out_dir), # force it to put the node_modules dir in this folder
|
||||
'--force', # overwrite any existing node_modules
|
||||
'--no-save', # don't bother saving updating the package.json or package-lock.json file
|
||||
'--no-audit', # don't bother checking for newer versions with security vuln fixes
|
||||
'--no-fund', # hide "please fund our project" messages
|
||||
'--loglevel', 'error', # only show erros (hide warn/info/debug) during installation
|
||||
# these args are written in blood, change with caution
|
||||
], capture_output=False, cwd=out_dir)
|
||||
os.remove(out_dir / 'package.json')
|
||||
except BaseException as e: # lgtm [py/catch-base-exception]
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue