Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Bower install: No versions available

I successfully registered my own library into bower:

bower register angular-ngkit https://github.com/daveoncode/angular-ngkit-bower.git

and I'm able to install it using:

bower install angular-ngkit

But by using simply:

bower install

or

bower info angular-ngkit

I get "No versions available" exception and I don't understand why, since using

git tag

I can see my latest (and only) release named "0.2"

I previously published the library under the name "angular-ngkit" using another git repo and then I unregistered it (using curl -X DELETE repo_url) and re-registered with the new repo url and I also executed the command:

bower cache clean

...so why bower is not working as it should?

UPDATE:

if I define the dependency to my library in bower.json as "angular-ngkit": "*" I'm able to run bower install properly... but it's not acceptable :(

like image 245
daveoncode Avatar asked Oct 26 '14 09:10

daveoncode


People also ask

Is bower deprecated?

Though it doesn't say it explicitly, it implies that Bower is deprecated. Existing projects that depend on package management via Bower will continue to work for the time being; but it's recommended that new projects should not take a dependency on Bower.

How do I know my bower version?

Bower lets you query the bower registry via the command line to find a package by a given name and then list its versions. e.g.


1 Answers

The reason that Bower does not see any versions of your package is that your repository contains only a single tag - v1.0 - which does not follow semantic versioning.
Bower versions can be Git tags or branches. The version number must be a valid semantic version (semver).
The reason that you manage to install using a star target ("angular-ngkit": "*") is that in this case if there are not valid tags, Bower will fallback to the latest commit on master.

like image 165
Dror Bereznitsky Avatar answered Oct 05 '22 21:10

Dror Bereznitsky