Every time I install a new bower package on my Ember CLI pack, I got
Missing bower packages:
Package: ember
* Specified: 1.11.0
* Installed: 1.10.0
then I run bower install ember#1.11.0.
Unable to find a suitable version for ember, please choose one:
1) ember#1.10.0 which resolved to 1.10.0 and is required by test-addon
2) ember#>= 1.8.1 < 2.0.0 which resolved to 1.11.0 and is required by ember-data#1.0.0-beta.16
3) ember#> 1.5.0-beta.3 which resolved to 1.11.0 and is required by ember-resolver#0.1.15
4) ember#>=1.4 <2 which resolved to 1.11.0 and is required by ember-cli-shims#0.0.3
5) ember#1.11.0 which resolved to 1.11.0Prefix the choice with ! to persist it to bower.json
I choose 5 (Why this hassle if I explicit added the desired version), then it works again.
But next time if I install a new bower package, I have to do it again.
node 0.12.1
bower 1.3.12
emvber cli 0.2.2
You may use -F flag to force to use latest version:
bower install -F
(see docs)
In this case bower didn't asking anything about versions.
Related
I'm installing plugins using bower, but bower only downloads Footable v2.0.1, not the latest release of v2.0.1.5.
I've tried:
bower install --save-dev footable
bower install --save-dev footable#2.0.1.x
Both these download v2.0.1, I want the latest tagged release of v2 (v2.0.1.5).
Using #2.0.1.x also gave the error "ENORESTARGET: Tag/Branch 2.0.1.x does not exist".
Bower package versions should follow semantic versioning.
In short, a valid semantic version is in the form of MAJOR.MINOR.PATCH.
2.0.1.5, for example, is not a valid semantic version.
You can get a list of available versions for a package by running the following command:
bower info footable
For footable you the results are:
Available versions:
- 2.0.1
- 2.0.0
- 0.5.0
- 0.1.0
I'm trying to install momentjs using bower:
bower install -S momentjs
But I get the following error:
bower ngStorage#0.3.0 not-cached git://github.com/agrublev/ngStorage.git#0.3.0
bower ngStorage#0.3.0 resolve git://github.com/agrublev/ngStorage.git#0.3.0
bower momentjs#2.6.0 cached git://github.com/moment/moment.git#2.6.0
bower momentjs#2.6.0 validate 2.6.0 against git://github.com/moment/moment.git#2.6.0
bower momentjs#* cached git://github.com/moment/moment.git#2.6.0
bower momentjs#* validate 2.6.0 against git://github.com/moment/moment.git#*
bower ngStorage#0.3.0 ENORESTARGET No tag found that was able to satisfy 0.3.0
Additional error details:
Available versions: 0.1.7, 0.1.6, 0.1.5
It looks like there's some sort of mix up between different repositories named ngStorage.
bower search ngStorage
Gives:
Search results:
ngstorage git://github.com/gsklee/ngStorage.git
ngStorage git://github.com/agrublev/ngStorage.git
The #0.3.0 tag exists for gsklee/ngStorage, but not for agrublev/ngStorage. (I already have the gsklee package installed for my project.)
How can I can workaround or fix whatever it is that is giving the error when trying to install momentjs?
I managed to solve this by:
1) Removing the following line from bower.json:
"ngStorage": "0.3.0"
2) Installing momentjs using:
bower install -S momentjs
3) Reinstalling ngstorage using:
bower install -S ngstorage
I suspect the issue was that I had manually edited bower.json (hadn't used -S while installing) and had the wrong entry for the ngstorage dependency (it was nsStorage, but should have been ngstorage - case sensitive)
> bower list
momentjs#2.2.1 (2.5.1 now available)
I go to change my bower.json to
{
"version": "0.0.0",
"dependencies": {
"momentjs": "~2.5.1",
...
And then run
> bower cache clean
> bower update momentjs
bower installing momentjs#2.2.1
Why am I getting 2.2.1 and not 2.5.1? Have I misunderstood some basics here?
The help page states that the update command:
Updates installed packages to their newest version according to bower.json
~ will only lookup patch versions in the current minor version range ("prereleases") e.g. 1.2.3 => 1.2.7.
To update the minor version, e.g. 1.2.3 = > 1.3.5, use bower install <package> instead.
I have package bootstrap-calendar
In bower.json it is version 0.2.0-RC and I even updated it to 0.2.0. But no matter what when you run
$> bower install bootstrap-calendar
it attempts to install version 0.0.9 which is earliest version. I cleaned cache but no success. What can I do that on bower install command latest package would be installed?
I don't think this is anything you are doing incorrectly. The package installs for me as 0.0.9 and the js file is listed as 0.1. I think the package is just not correct and needs to be mentioned on the issues section of Github, which I did.
Is there a way for bower list command to show updates available while respecting my dependencies versions
example bower.json :
{
"dependencies": {
"jquery": "<2"
}
}
bower install :
bower installing jquery#1.10.0
jquery update to 1.10.1 (bower info jquery):
jquery
Versions:
- 2.0.2
- 2.0.1
- 2.0.0
- 1.10.1
- 1.10.0
bower list:
bower discover Please wait while newer package versions are being discovered
...
└── jquery#1.10.0 (2.0.2 now available)
Edit:
a correction has been made in master branch.
The bug doesn't exists anymore https://github.com/bower/bower/issues/562
You should open a ticket about it.