Closed billzt closed 5 years ago
If you want you can remove electron, electron-packager, and puppeteer from your package.json, I don't think that would hurt anything
Alternatively if you want to keep these things, maybe use cnpm or try to configure to use taobao
# first set these
npm config set registry https://registry.npm.taobao.org
npm config set puppeteer_download_host=https://npm.taobao.org/mirrors
export ELECTRON_MIRROR="https://npm.taobao.org/mirrors/electron/"
#then run
./setup.sh
References https://github.com/electron/electron/blob/master/docs/tutorial/installation.md#custom-mirrors-and-caches https://github.com/yarnpkg/yarn/issues/2411 https://github.com/GoogleChrome/puppeteer/issues/1597
It is important that jbrowse at least obtains yarn, so if you can configure jbrowse to at least allow yarn then that would be valuable. Setting the registry to taobao as above may help with it downloading yarn, and then you are still free to remove electron/puppeteer related dependencies
There are also ways to just not use setup.sh too. As a JBrowse developer, I rarely actually use ./setup.sh to install dependencies, I just run "yarn" directly from the command line and "yarn watch" to build jbrowse (in which starts a webpack-dev-server that watches for changes)
I only mention the above solutions because ideally I want users to still have a path to running setup.sh if possible
Resolved by setting:
npm config set registry http://r.cnpmjs.org
npm config set puppeteer_download_host=http://cnpmjs.org/mirrors
export ELECTRON_MIRROR="http://cnpmjs.org/mirrors/electron/"
The main reason is that I want to use the plugin "GCContent". According to the JBrowse document, I need to use the *-dev.zip
build of JBrowse if I use any plugins beyond the default ones and must re-run setup.sh to build the plugin's code into JBrowse. @cmdcolin
That is true, it is necessary to rebuild jbrowse if you are using plugins for jbrowse versions post 1.13.0
In
./setup.sh
, the script will check and try to download and install yarn through npm.However, in some countries (e.g. China) the npm-registry project page has been blocked by the government. Therefore the script
./setup.sh
will be stuck inInstalling node.js dependencies and building with webpack ...
forever.The same happens on
electron
, which will be automatically downloaded by./setup.sh
and would be very slow if users have poor internet access.Is there any methods for users to manually download them first (through other approaches) and then run
./setup.sh
?