Pavel Eremin
Pavel Eremin

Reputation: 91

Composer + twitter bootstrap 2

How I can add this repo https://github.com/twbs/bootstrap-sass/tree/2.1-stable to my composer.json?

I tryed this:

"minimum-stability": "dev",
"require-dev": {
  "twbs/bootstrap-sass": "dev-2.1-stable"
}

but got error:

The requested package twbs/bootstrap-sass could not be found in any version, there may be a typo in the package name

Upvotes: 0

Views: 314

Answers (2)

DavidT
DavidT

Reputation: 2481

I am assuming you know they have a version 3 available. Also, do you not have Ruby gems installed? To install using their instructions add the package to your Gemfile, not to composer.

If you do want to install via composer, it has to be a composer package, which from https://packagist.org/packages/twbs/bootstrap-sass looks like only version 3 and up are available.

Try using:

"require-dev": {
    "twbs/bootstrap-sass": "3.2.*"
}

Notice the 3 above, I tried 2.1.* and it couldn't be found. 3.2.* worked fine.

Also, incase you're wondering the * just means 'latest'. If you want 2.1 you might have to do it via Ruby Gems.

Upvotes: 1

Jonathan
Jonathan

Reputation: 1564

dev-2.1-stable isnt in the package:

https://packagist.org/packages/twbs/bootstrap-sass

its a branch in their git repo, but they havent submitted those versions to packagist (or the tags they have given on the branches arent valid for packagist to pick them up on its own: https://packagist.org/about)

Upvotes: 1

Related Questions