From dd2a0cfb9a0ad0964d1dde287c315cb0511c334f Mon Sep 17 00:00:00 2001 From: Matt Andrews Date: Sun, 19 Jan 2014 00:56:34 +0000 Subject: [PATCH 1/2] Add Travis CI --- .travis.yml | 5 +++++ README.md | 20 ++++++++++---------- test/silent.scss | 2 ++ test/travis.rb | 10 ++++++++++ 4 files changed, 27 insertions(+), 10 deletions(-) create mode 100644 .travis.yml create mode 100644 test/silent.scss create mode 100755 test/travis.rb diff --git a/.travis.yml b/.travis.yml new file mode 100644 index 0000000..f6ab2eb --- /dev/null +++ b/.travis.yml @@ -0,0 +1,5 @@ +script: + - "test/travis.rb" +language: ruby +before_install: + - gem install sass diff --git a/README.md b/README.md index b5b31cc..f353927 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,4 @@ -# csswizardry-grids +# csswizardry-grids [![Build Status](https://travis-ci.org/csswizardry/csswizardry-grids.png?branch=master)](https://travis-ci.org/csswizardry/csswizardry-grids) **Simple, fluid, nestable, flexible, Sass-based, responsive grid system.** @@ -90,15 +90,15 @@ If you are using traditional classes then an example, basic usage might look like this:
- +
...
...
- +
It’s as simple as that! @@ -127,15 +127,15 @@ If you are using silent classes (`$use-silent-classes: true;`) then your HTML might look like this:
- +
...
...
- +
…and your Sass, something like this: @@ -143,18 +143,18 @@ might look like this: .page{ @extend %grid; } - + .content, .sub-content{ @extend %grid__item; @extend %one-whole; @extend %lap--one-half; } - + .content{ @extend %desk--two-thirds; } - + .sub-content{ @extend %desk--one-third; } diff --git a/test/silent.scss b/test/silent.scss new file mode 100644 index 0000000..8c56c37 --- /dev/null +++ b/test/silent.scss @@ -0,0 +1,2 @@ +$use-silent-classes: true; +@import '../csswizardry-grids'; diff --git a/test/travis.rb b/test/travis.rb new file mode 100755 index 0000000..4525b58 --- /dev/null +++ b/test/travis.rb @@ -0,0 +1,10 @@ +#!/usr/bin/env ruby + +result = `sass csswizardry-grids.scss build.css` +raise result unless $?.to_i == 0 +puts "Regular sass compiled successfully" + +result = `sass test/silent.scss build.silent.css --style compressed` +raise result unless $?.to_i == 0 +raise "When $use-silent-classes is set to true the module should not output any CSS" unless File.size('build.silent.css') == 0 +puts "Silent sass compiled successfully" From 01acebd3b3587ca549c3496345b4f327334eb8af Mon Sep 17 00:00:00 2001 From: Matt Andrews Date: Sat, 5 Apr 2014 22:16:04 +0100 Subject: [PATCH 2/2] Switch to using Travis CI's .svg build badge --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index f353927..567aec1 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,4 @@ -# csswizardry-grids [![Build Status](https://travis-ci.org/csswizardry/csswizardry-grids.png?branch=master)](https://travis-ci.org/csswizardry/csswizardry-grids) +# csswizardry-grids [![Build Status](https://travis-ci.org/csswizardry/csswizardry-grids.svg?branch=master)](https://travis-ci.org/csswizardry/csswizardry-grids) **Simple, fluid, nestable, flexible, Sass-based, responsive grid system.**