diff --git a/.travis.yml b/.travis.yml index 97d373312d..83758a606a 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,39 +1,35 @@ +sudo: required +dist: trusty language: node_js git: depth: 10 node_js: - "0.12" before_install: - - travis_retry sudo pip install -r test-infra/requirements.txt - - rvm install 2.0.0 - - rvm use 2.0.0 --fuzzy - - export GEMDIR=$(rvm gemdir) - - if [ "$TWBS_TEST" = validate-html ]; then echo "ruby=$(basename $GEMDIR) jekyll=$JEKYLL_VERSION rouge=$ROUGE_VERSION" > pseudo_Gemfile.lock; fi + # Remove ./node_modules/.bin from PATH so node-which doesn't replace Unix which and cause RVM to barf. See https://github.com/travis-ci/travis-ci/issues/5092 + - export PATH=$(python -c 'from sys import argv;from collections import OrderedDict as od;print(":".join(od((p,None) for p in argv[1].split(":") if p.startswith("/")).keys()))' "$PATH") + - rvm install 2.2 + - rvm use 2.2 --fuzzy - "export TRAVIS_COMMIT_MSG=\"$(git log --format=%B --no-merges -n 1)\"" - echo "$TRAVIS_COMMIT_MSG" | grep '\[skip validator\]'; export TWBS_DO_VALIDATOR=$?; true - echo "$TRAVIS_COMMIT_MSG" | grep '\[skip sauce\]'; export TWBS_DO_SAUCE=$?; true - if [ "$TRAVIS_REPO_SLUG" = twbs-savage/bootstrap ]; then export TWBS_DO_VALIDATOR=0; fi install: + - bundle install --deployment --jobs=1 + - cp grunt/npm-shrinkwrap.json ./ - npm install -g grunt-cli - - ./test-infra/s3_cache.py download npm-modules - - if [ "$TWBS_TEST" = validate-html ] && [ $TWBS_DO_VALIDATOR -ne 0 ]; then ./test-infra/s3_cache.py download rubygems; fi -after_script: - - if [ "$TRAVIS_REPO_SLUG" != twbs-savage/bootstrap ] && [ "$TWBS_TEST" = core ]; then ./test-infra/s3_cache.py upload npm-modules; fi - - if [ "$TRAVIS_REPO_SLUG" != twbs-savage/bootstrap ] && [ "$TWBS_TEST" = validate-html ] && [ $TWBS_DO_VALIDATOR -ne 0 ]; then ./test-infra/s3_cache.py upload rubygems; fi + - npm install +cache: + directories: + - node_modules + - vendor/bundle env: global: - - JEKYLL_VERSION="3.0.0" - - ROUGE_VERSION="1.10.1" + - NPM_CONFIG_PROGRESS="false" - SAUCE_USERNAME="bootstrap" - secure: "pJkBwnuae9dKU5tEcCqccfS1QQw7/meEcfz63fM7ba7QJNjoA6BaXj08L5Z3Vb5vBmVPwBawxo5Hp0jC0r/Z/O0hGnAmz/Cz09L+cy7dSAZ9x4hvZePSja/UAusaB5ogMoO8l2b773MzgQeSmrLbExr9BWLeqEfjC2hFgdgHLaQ=" - - secure: "gqjqISbxBJK6byFbsmr1AyP1qoWH+rap06A2gI7v72+Tn2PU2nYkIMUkCvhZw6K889jv+LhQ/ybcBxDOXHpNCExCnSgB4dcnmYp+9oeNZb37jSP0rQ+Ib4OTLjzc3/FawE/fUq5kukZTC7porzc/k0qJNLAZRx3YLALmK1GIdUY=" - - secure: "Gghh/e3Gsbj1+4RR9Lh2aR/xJl35HWiHqlPIeSUqE9D7uDCVTAwNce/dGL3Ew7uJPfJ6Pgr70wD3zgu3stw0Zmzayax0hiDtGwcQCxVIER08wqGANK9C2Q7PYJkNTNtiTo6ehKWbdV4Z+/U+TEYyQfpQTDbAFYk/vVpsdjp0Lmc=" - - secure: "RTbRdx4G/2OTLfrZtP1VbRljxEmd6A1F3GqXboeQTldsnAlwpsES65es5CE3ub/rmixLApOY9ot7OPmNixFgC2Y8xOsV7lNCC62QVpmqQEDyGFFQKb3yO6/dmwQxdsCqGfzf9Np6Wh5V22QFvr50ZLKLd7Uhd9oXMDIk/z1MJ3o=" - secure: "RKWpS+P20b4tG9tawzCMJSmQftoonmC7tJzyGYiHuEM1TcpHALLBcnzKlr/+DiPTfzDJWY4kS8pxfhK4uXOe8OHnhpMNub7LEWtFPePlZIervOJcsOydaQocTKqVVWD6OUubMeQmQ+tZmvmpjoJ1uPPEbFs9ciF7+dv3U5tLUZ0=" - secure: "XswSKBY0HJ/aO9VOBeWlvGpqSFF/DsJmNKz7o5RkJMJX340qe44J929uUNwwOwlv9YrgptzC2W6l8bpmZQV+p6IYs99SoSA8CCaUfIJaqeU9x/UiT5vIHgqaNax+vFJwvzHLpF5v/ggFqFEKCd54gCDasePLTztHeC4oL104iaQ=" - - secure: "Dv1HX5dzyTh8gA2YsLI+yWEgh9lnGKPpRDDEYYvm42fjBFziUYfcpvA9g8GXQuU9srY3mhfsZkCDHN0x5n1gliOai5TSjmd5Hh+9UyhvNWE+D8HoUpcFXWoQXvy/if2r25m+ZWi3cqgXkkBOcal3W1ePMtU4ln18NcWyIZ0tEFo=" - - secure: "PabpUdG2dE40hHUkMCdxk1e9Ak3BOo0h7Y5/uekosLKOz5N60Xmn/ooyrSkvicLthXO4cfONFhO3/xSVRKQOxlUw4on5i0VuNK+QSqxJk0IDaRSZnTCcC8J7083K0YL+FvMdGQwcYwMY9LiwS8aS014IRkSQjsa+mjo3owP+dOU=" - - secure: "G4/f4PVyVi9o6UbZMqw9YFmDu7cHqe9iymiXYd1RcnPXwhWAePX12m0PWMhUj5itJ180PTEddVip8PNOgBdqyrDxEPKkcgAW2EElVAPIKJXVfvDW64UjQ0H7NS7XvF7iLQUJp/XfmR7NJ7tT393AQdh8SGmuQpJhgYbwIWbES/k=" matrix: - TWBS_TEST=core - TWBS_TEST=validate-html diff --git a/Gemfile b/Gemfile new file mode 100644 index 0000000000..832d45f9f6 --- /dev/null +++ b/Gemfile @@ -0,0 +1,6 @@ +source 'https://rubygems.org' + +group :development, :test do + gem 'jekyll', '~> 3.1.2' + gem 'jekyll-sitemap', '~> 0.10.0' +end diff --git a/Gemfile.lock b/Gemfile.lock new file mode 100644 index 0000000000..cddfec5b6b --- /dev/null +++ b/Gemfile.lock @@ -0,0 +1,41 @@ +GEM + remote: https://rubygems.org/ + specs: + colorator (0.1) + ffi (1.9.10-x64-mingw32) + jekyll (3.1.2) + colorator (~> 0.1) + jekyll-sass-converter (~> 1.0) + jekyll-watch (~> 1.1) + kramdown (~> 1.3) + liquid (~> 3.0) + mercenary (~> 0.3.3) + rouge (~> 1.7) + safe_yaml (~> 1.0) + jekyll-sass-converter (1.4.0) + sass (~> 3.4) + jekyll-sitemap (0.10.0) + jekyll-watch (1.3.1) + listen (~> 3.0) + kramdown (1.10.0) + liquid (3.0.6) + listen (3.0.6) + rb-fsevent (>= 0.9.3) + rb-inotify (>= 0.9.7) + mercenary (0.3.5) + rb-fsevent (0.9.7) + rb-inotify (0.9.7) + ffi (>= 0.5.0) + rouge (1.10.1) + safe_yaml (1.0.4) + sass (3.4.21) + +PLATFORMS + x64-mingw32 + +DEPENDENCIES + jekyll (~> 3.1.2) + jekyll-sitemap (~> 0.10.0) + +BUNDLED WITH + 1.11.2 diff --git a/Gruntfile.js b/Gruntfile.js index a1447445d0..689b186423 100644 --- a/Gruntfile.js +++ b/Gruntfile.js @@ -301,7 +301,9 @@ module.exports = function (grunt) { jekyll: { options: { - config: '_config.yml' + bundleExec: true, + config: '_config.yml', + incremental: false }, docs: {}, github: { @@ -501,7 +503,7 @@ module.exports = function (grunt) { if (err) { grunt.fail.warn(err); } - var dest = 'test-infra/npm-shrinkwrap.json'; + var dest = 'grunt/npm-shrinkwrap.json'; fs.renameSync('npm-shrinkwrap.json', dest); grunt.log.writeln('File ' + dest.cyan + ' updated.'); done(); diff --git a/README.md b/README.md index fe20ecda9f..bc2ddf927e 100644 --- a/README.md +++ b/README.md @@ -80,10 +80,9 @@ Bootstrap's documentation, included in this repo in the root directory, is built ### Running documentation locally -1. If necessary, [install Jekyll](http://jekyllrb.com/docs/installation) (requires v3.0.x). +1. If necessary, [install Jekyll](http://jekyllrb.com/docs/installation) and other Ruby dependencies with `bundle install`. **Note for Windows users:** Read [this unofficial guide](http://jekyll-windows.juthilo.com/) to get Jekyll up and running without problems. -2. Install the Ruby-based syntax highlighter, [Rouge](https://github.com/jneen/rouge), with `gem install rouge`. -3. From the root `/bootstrap` directory, run `jekyll serve` in the command line. +2. From the root `/bootstrap` directory, run `bundle exec jekyll serve` in the command line. 4. Open `http://localhost:9001` in your browser, and voilà. Learn more about using Jekyll by reading its [documentation](http://jekyllrb.com/docs/home/). diff --git a/_config.yml b/_config.yml index 8f0dc85774..38f21b86ce 100644 --- a/_config.yml +++ b/_config.yml @@ -13,6 +13,9 @@ port: 9001 url: http://getbootstrap.com encoding: UTF-8 +gems: + - jekyll-sitemap + # Custom vars current_version: 3.3.6 repo: https://github.com/twbs/bootstrap diff --git a/dist/js/bootstrap.js b/dist/js/bootstrap.js index 7348b5361c..78bb6b0d60 100644 --- a/dist/js/bootstrap.js +++ b/dist/js/bootstrap.js @@ -543,6 +543,7 @@ if (typeof jQuery === 'undefined') { * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE) * ======================================================================== */ +/* jshint latedef: false */ +function ($) { 'use strict'; diff --git a/docs/_includes/components/navbar.html b/docs/_includes/components/navbar.html index 418da7915a..a53293d3ad 100644 --- a/docs/_includes/components/navbar.html +++ b/docs/_includes/components/navbar.html @@ -60,7 +60,7 @@ -