-
Notifications
You must be signed in to change notification settings - Fork 3
Open
Description
While npm is probably the easiest way of installing jetpack, as long as we release the binary in an easy-to-download way (i.e. in GitHub's Releases tab), it shouldn't fail if package.json doesn't exist.
- jetpack version: 426b0b4 (head of Empty modules #55 as of now)
to repro
Given a package.json like: (exact content doesn't matter, as long as there's a top-level "devDependencies" property - reproduced here for reproducibility's sake)
$ cat package.json
{
"name": "jetpack-module-dir-bug",
"version": "1.0.0",
"description": "",
"main": "entry.js",
"scripts": {
"test": "echo \"Error: no test specified\" && exit 1"
},
"author": "",
"license": "ISC",
"devDependencies": {
"coffeescript": "^2.0.0",
"elm": "^0.18.0",
"sass": "^1.0.0-beta.2"
}
}error on missing package.json
$ mv package.json package.json.bak
$ ../jetpack/.stack-work/dist/x86_64-osx/Cabal-2.0.1.0/build/jetpack/jetpack --version
jetpack: path/to/here/package.json: openBinaryFile: does not exist (No such file or directory)error on missing "@noredink/jetpack" in devDependencies
$ jq '.' package.json.bak > package.json
$ ../jetpack/.stack-work/dist/x86_64-osx/Cabal-2.0.1.0/build/jetpack/jetpack --version
jetpack: I couldn't decode package.json in path/to/here/
Error in $: key "@noredink/jetpack" not presenterror on non-exact dependency version
This is likely from Data.SemVer's way of parsing semver.
$ jq '.devDependencies["@noredink/jetpack"] |= "^2.0.0"' package.json.bak > package.json
$ ../jetpack/.stack-work/dist/x86_64-osx/Cabal-2.0.1.0/build/jetpack/jetpack --version
jetpack: I couldn't decode package.json in path/to/here/
Error in $: Failed reading: takeWhile1Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels