It assumes that every package.json file has a version prop, 'cause that's the default behavior of npm init I guess, but this isn't true for Meteor projects.
Meteor's flaw I would say, but I thought it would be nice to issue that.
C:\cmder/vendor/clink-completions/npm_prompt.lua:11: attempt to concatenate local 'package_version' (a nil value)
C:\apache\htdocs\hello-meteor-1.3 {git}{hg}
{lamb}
Ps.: just ignore my workspace :laughing:
Not having specific version numbers is normal for documentation and web sites, like the Atom Flight Manual.
I'm too much of a Lua noob to fix this. Apparently neither setting a default value for local package_version, nor checking for it after the string.match() attempt is capable of overcoming the bug. I tried
if not package_version then
local package_version = "unknown"
end
and
if package_version == nil then
local package_version = "unknown"
end
Not a Lua expert also, but it seams that using local makes the variable available only on the scope and maybe if blocks are scoped. Not using local to mutate package_version works here:
if package_version == nil then
package_version = '0.0.0'
end
In fact, it seams that it is just a matter of updating the dependency:
https://github.com/vladimir-kotikov/clink-completions/blob/master/npm.lua#L212
@vladimir-kotikov, we are missing bumps to 0.3.x :laughing:
Sorry, just saw it at dev branch. Nice!
:arrow_up: 0.3.1 ;-)
Most helpful comment
:arrow_up: 0.3.1 ;-)