histograph / viewer

Viewer for Histograph API & Data
http://histograph.io/viewer
MIT License
0 stars 1 forks source link

Invalid serve hints on npm start #25

Closed reinvantveer closed 6 years ago

reinvantveer commented 8 years ago

reinv@lingui:~/data/Github/histograph/histograph-viewer$ npm start

histograph-viewer@0.5.0 start /var/data/Github/histograph/histograph-viewer NODE_ENV=development node viewer-config.js > config.json && watchify -d -t reactify src/index.js -o dist/bundle.js & serve

Please specify location of your user configuration in environment variable HISTOGRAPH_CONFIG, or use the --config command line option serving /var/data/Github/histograph/histograph-viewer on port 3000 ^C

reinv@lingui:~/data/Github/histograph/histograph-viewer$ npm start --config $PWD/../config/config.yml

histograph-viewer@0.5.0 start /var/data/Github/histograph/histograph-viewer NODE_ENV=development node viewer-config.js > config.json && watchify -d -t reactify src/index.js -o dist/bundle.js & serve "/home/reinv/data/Github/histograph/histograph-viewer/../config/config.yml"

Please specify location of your user configuration in environment variable HISTOGRAPH_CONFIG, or use the --config command line option serving /home/reinv/data/Github/histograph/config/config.yml on port 3000 Error: ENOTDIR: not a directory, stat '/home/reinv/data/Github/histograph/config/config.yml/' at Error (native)

bertspaan commented 8 years ago

Can you reformat your issue? It's hard to read + understand.

reinvantveer commented 8 years ago

Histograph-viewer seems to append an extra '/' when used with the --config CLI option.

To reproduce:

  1. use npm start instruction from docs
reinv@lingui:~/data/Github/histograph/histograph-viewer$ npm start

> histograph-viewer@0.5.0 start /var/data/Github/histograph/histograph-viewer
> NODE_ENV=development node viewer-config.js > config.json && watchify -d -t reactify src/index.js -o dist/bundle.js & serve

Please specify location of your user configuration in environment variable `HISTOGRAPH_CONFIG`, or use the `--config` command line option
serving /var/data/Github/histograph/histograph-viewer on port 3000

Pressed ^C

  1. used Please specify location of your user configuration in environment variableHISTOGRAPH_CONFIG, or use the--configcommand line option option as --config parameter
reinv@lingui:~/data/Github/histograph/histograph-viewer$ npm start --config $PWD/../config/config.yml

> histograph-viewer@0.5.0 start /var/data/Github/histograph/histograph-viewer
> NODE_ENV=development node viewer-config.js > config.json && watchify -d -t reactify src/index.js -o dist/bundle.js & serve "/home/reinv/data/Github/histograph/histograph-viewer/../config/config.yml"

Please specify location of your user configuration in environment variable `HISTOGRAPH_CONFIG`, or use the `--config` command line option
serving /home/reinv/data/Github/histograph/config/config.yml on port 3000
Error: ENOTDIR: not a directory, stat '/home/reinv/data/Github/histograph/config/config.yml/'
    at Error (native)
reinvantveer commented 8 years ago

Sorry was a bit quick I suppose with the previous comment :)

bertspaan commented 8 years ago

Oh, yeah... You cannot pass the --config option with npm start...

"Please specify location of your user configuration..." is output from viewer-config.js, you should add the --config option to the scripts section in package.json, or just set the environment variable!

bertspaan commented 8 years ago

This is confusing, I agree... We should update README.

sbocconi commented 6 years ago

Updated readme