neat 2.0.0 → 2.1.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 23c144afb938b1528dc2e36a180cb80d7480ac81
4
- data.tar.gz: c33ff2c82766d847ceb640c110e747f533a3e5e0
3
+ metadata.gz: 9dc82f3ba0b2ce909543138819c30dfa58dc1b8c
4
+ data.tar.gz: 37db8ca6fd99baf7d53e4c5ec78e1c2a34dd4c4f
5
5
  SHA512:
6
- metadata.gz: 3b17dbcc1c974e5a32c38589fee5f7a94bd3772ea1f7c17eb7e8b589c548c7159acfd0ca7cb3e3af44642a3acc4ccb5cda8e3ed4d110cc71301fbbf324ab61e5
7
- data.tar.gz: a56574e2c5db7f6ed15d32ed27d042462a7a0cc972a17cd08df81470def202b08a8f52cdbfe0abe09ef3817edab84dfa37b00719016d5f30081dc55284d97c55
6
+ metadata.gz: c8a1f2ecb47ebcecdfa22cc70a26a880fbf5811c6da87bdaa9568b42e3e17e468c5947c8b68156817178ea2c6a289b2c6715d39081cbf3b511696c470e588da5
7
+ data.tar.gz: 0f98e2bec20e15c6fe8c3761082bf04db4a0ebd1f75d30e3fc5840581bf04f89e32092368fa6dcf34e522f71ece5c7fd5962cbcf26da26c54aab2ca5ad723731
@@ -0,0 +1,22 @@
1
+ Welcome to Neat! 👋🎉
2
+
3
+ Do you need help or have a question? Please check out Neat on [Stack Overflow]. Got an idea for a new feature or found a bug? Please fill out the sections below... thank you 👍
4
+
5
+ [Stack Overflow]: https://stackoverflow.com/questions/tagged/neat
6
+
7
+ ### Issue Summary
8
+
9
+ A summary of the issue and the browser/OS environment in which it occurs.
10
+
11
+ ### Steps to Reproduce
12
+
13
+ 1. This is the first step
14
+ 2. This is the second step, etc.
15
+
16
+ Any other info, for example, why you consider this to be a bug? What did you expect to happen instead?
17
+
18
+ ### Technical details:
19
+
20
+ - Neat Version:
21
+ - Build Tool or Environment:
22
+ - Browser/OS:
@@ -0,0 +1,8 @@
1
+ Got some code for us? Awesome 🎊!
2
+
3
+ Please include a description of your change and the problem it solves. Then check your PR against this list. Thanks!
4
+ - [ ] Commit message has a short title & issue references
5
+ - [ ] Commits are squashed
6
+ - [ ] The build will pass (run `bundle exec rake`).
7
+
8
+ More info can be found by clicking the "guidelines for contributing" link above.
data/.npmignore CHANGED
@@ -1,15 +1,21 @@
1
+ .github/
1
2
  .gitignore
3
+ .hound.yml
4
+ .ruby-version
2
5
  .sass-cache
3
6
  .scss-lint.yml
4
- _site
5
7
  bin/
6
8
  bower.json
9
+ circle.yml
10
+ CODE_OF_CONDUCT.md
11
+ contrib/
7
12
  CONTRIBUTING.md
8
13
  Gemfile
9
14
  Gemfile.lock
15
+ Gulpfile.js
10
16
  lib/
11
17
  neat.gemspec
12
- NEWS.md
13
18
  pkg/
14
19
  Rakefile
20
+ RELEASING.md
15
21
  spec/
@@ -3,10 +3,31 @@
3
3
  All notable changes to this project will be documented in this file. This
4
4
  project adheres to [Semantic Versioning](http://semver.org).
5
5
 
6
- ## [Unreleased]
6
+ ## [Unreleased (`master`)][unreleased]
7
7
 
8
8
  Nothing at the moment.
9
9
 
10
+ ## [2.1.0] - 2017-06-27
11
+
12
+ ### Added
13
+
14
+ - A `--path` CLI option, which lets you install Neat into specific
15
+ directory. ([#459])
16
+ - A `style` property has been added to our `package.json`, which makes for easy
17
+ importing when using npm-sass, sass-module-importer and others. ([#514])
18
+
19
+ ### Fixed
20
+
21
+ - Fixed an issue that would cause Neat to not be found within Rails
22
+ apps. ([#612])
23
+ - Simplified the gradient used in the `grid-visual` mixin for more consistent
24
+ cross-browser behaviour. ([#569])
25
+
26
+ [#459]: https://github.com/thoughtbot/neat/pull/459
27
+ [#514]: https://github.com/thoughtbot/neat/pull/514
28
+ [#569]: https://github.com/thoughtbot/neat/pull/569
29
+ [#612]: https://github.com/thoughtbot/neat/pull/612
30
+
10
31
  ## [2.0.0]
11
32
 
12
33
  ### Fixed
@@ -312,7 +333,8 @@ Nothing at the moment.
312
333
 
313
334
  - Initial release
314
335
 
315
- [Unreleased]: https://github.com/thoughtbot/neat/compare/v2.0.0...HEAD
336
+ [unreleased]: https://github.com/thoughtbot/neat/compare/v2.1.0...HEAD
337
+ [2.1.0]: https://github.com/thoughtbot/neat/compare/v2.0.0...v2.1.0
316
338
  [2.0.0]: https://github.com/thoughtbot/neat/compare/v2.0.0.beta.2...v2.0.0
317
339
  [2.0.0.beta.2]: https://github.com/thoughtbot/neat/compare/v2.0.0.beta.1...v2.0.0.beta.2
318
340
  [2.0.0.beta.1]: https://github.com/thoughtbot/neat/compare/v2.0.0.alpha.1...v2.0.0.beta.1
@@ -0,0 +1,6 @@
1
+ # Code of Conduct
2
+
3
+ By participating in this project, you agree to abide by the
4
+ [thoughtbot code of conduct][tb-coc].
5
+
6
+ [tb-coc]: https://thoughtbot.com/open-source-code-of-conduct
data/README.md CHANGED
@@ -1,21 +1,27 @@
1
- [<img src="http://images.thoughtbot.com/bourbon/neat-logo-v2.svg" width="200" alt="Neat logo">](http://neat.bourbon.io)
1
+ [<img src="http://images.thoughtbot.com/bourbon/neat-logo-v2.svg" width="200" alt="Neat logo">][Neat]
2
2
 
3
3
  ## A lightweight and flexible Sass grid
4
4
 
5
- Neat is a fluid grid framework with the aim of being easy enough to use out of the box and flexible enough to customize down the road.
5
+ [Neat] is a fluid grid framework with the aim of being easy enough to
6
+ use out of the box and flexible enough to customize down the road.
6
7
 
7
- - **[Demo](http://neat.bourbon.io)**
8
- - **[Documentation](http://thoughtbot.github.io/neat-docs/latest)**
9
- - **[Changelog](https://github.com/thoughtbot/neat/releases)**
10
- - **[Issues & Bugs](https://github.com/thoughtbot/neat/issues)**
8
+ [Neat]: https://neat.bourbon.io/
11
9
 
12
- Follow the [@bourbonsass](https://twitter.com/bourbonsass) Twitter account
13
- for updates.
10
+ ### Helpful Links
11
+
12
+ - [Demos](https://neat.bourbon.io/examples/)
13
+ - [Documentation](https://neat.bourbon.io/docs/latest/)
14
+ - [Change log](CHANGELOG.md)
15
+ - [Twitter](https://twitter.com/bourbonsass)
16
+ - [Stack Overflow](https://stackoverflow.com/questions/tagged/neat)
17
+ - [Neat 2.0 Building the future of floated Sass grids](https://robots.thoughtbot.com/building-the-future-of-floated-css-grids) by [@whmii](http://social.mcmahan.me)
18
+ - [Getting started with Neat 2.0, a lightweight and flexible Sass grid](https://robots.thoughtbot.com/the-release-of-neat-2-0-a-lightweight-and-flexible-sass-grid) by [@whmii](http://social.mcmahan.me)
14
19
 
15
20
  ## Table of Contents
16
21
 
17
22
  - [Requirements](#requirements)
18
23
  - [Installation](#installation)
24
+ - [Command Line Interface](#command-line-interface)
19
25
  - [The Bourbon Family](#the-bourbon-family)
20
26
  - [Contributing](#contributing)
21
27
  - [License](#license)
@@ -23,106 +29,155 @@ for updates.
23
29
 
24
30
  ## Requirements
25
31
 
26
- - Sass 3.4+ or LibSass 3.3+
32
+ - [Sass] 3.4+ or [LibSass] 3.3+
33
+
34
+ [Sass]: https://github.com/sass/sass
35
+ [LibSass]: https://github.com/sass/libsass
27
36
 
28
37
  ## Installation
29
38
 
30
- For command line help, visit our wiki page on Neat’s [command line interface](https://github.com/thoughtbot/neat/wiki/Command-Line-Interface).
39
+ 1. Install the Neat gem using the [RubyGems] package manager:
40
+
41
+ ```bash
42
+ gem install neat
43
+ ```
31
44
 
32
- 1. Install the Neat gem using the [RubyGems](https://rubygems.org) package manager:
45
+ Alternatively, you can install Neat with [Bower].
33
46
 
34
- ```bash
35
- gem install neat
36
- ```
47
+ 1. Install or update Neat’s dependencies:
37
48
 
38
- Alternatively, you can install Neat with [Bower](http://bower.io).
49
+ ```bash
50
+ gem install sass # or gem update sass
51
+ ```
39
52
 
40
- 2. Install or update Neat’s dependencies:
53
+ **Pro Tip:** You can target installation into a specific directory using the
54
+ `path` flag:
41
55
 
42
- ```bash
43
- gem install sass # or gem update sass
44
- ```
56
+ ```bash
57
+ neat install --path my/custom/path/
58
+ ```
45
59
 
46
- 3. Install the Neat library into the current directory:
60
+ 1. Install the Neat library into the current directory:
47
61
 
48
- ```bash
49
- neat install
50
- ```
62
+ ```bash
63
+ neat install
64
+ ```
51
65
 
52
- 4. Import Neat in your stylesheet:
66
+ 1. Import Neat in your stylesheet:
53
67
 
54
- ```scss
55
- @import "neat/neat";
56
- ```
68
+ ```scss
69
+ @import "neat/neat";
70
+ ```
57
71
 
58
- It’s not recommended to add or modify the Neat files so that you can update them easily.
72
+ It’s not recommended to add or modify the Neat files so that you can update
73
+ them easily.
74
+
75
+ [RubyGems]: https://rubygems.org
76
+ [Bower]: http://bower.io
59
77
 
60
78
  ### Installation for Ruby on Rails 4.2+
61
79
 
62
80
  1. Add Neat to your Gemfile:
63
81
 
64
- ```ruby
65
- gem "neat"
66
- ```
82
+ ```ruby
83
+ gem "neat"
84
+ ```
67
85
 
68
- 2. Then run:
86
+ 1. Then run:
69
87
 
70
- ```bash
71
- bundle install
72
- ```
88
+ ```bash
89
+ bundle install
90
+ ```
73
91
 
74
- If you see the error `Bundler could not find compatible versions for gem "sass"`, run:
92
+ If you see the error `Bundler could not find compatible versions for gem
93
+ "sass"`, run:
75
94
 
76
- ```bash
77
- bundle update sass
78
- ```
95
+ ```bash
96
+ bundle update sass
97
+ ```
79
98
 
80
- 3. Import Neat in your `application.scss`:
99
+ 1. Import Neat in your `application.scss`:
81
100
 
82
- ```scss
83
- @import "neat";
84
- ```
101
+ ```scss
102
+ @import "neat";
103
+ ```
85
104
 
86
- It should be noted that `@import` rules are not compatible with Sprockets directives. You need to use one or the other.
105
+ It should be noted that `@import` rules are not compatible with Sprockets
106
+ directives. You need to use one or the other.
87
107
 
88
108
  ### Installing with npm and using a Node-based asset pipeline
89
109
 
90
110
  1. Add Neat as a dependency:
91
111
 
92
- ```bash
93
- npm install --save bourbon-neat
94
- ```
112
+ ```bash
113
+ npm install --save bourbon-neat
114
+ ```
95
115
 
96
- 1. If you’re using [Eyeglass](http://eyeglass.rocks), skip to Step 3. Otherwise, you’ll need to add Neat to your node-sass `includePaths` option. `require("bourbon-neat").includePaths` is an array of directories that you should pass to node-sass. How you do this depends on how node-sass is integrated into your project.
116
+ 1. If you’re using [eyeglass], skip to Step 3. Otherwise, you’ll need to add
117
+ Neat to your node-sass `includePaths` option.
118
+ `require("bourbon-neat").includePaths` is an array of directories that you
119
+ should pass to node-sass. How you do this depends on how node-sass is
120
+ integrated into your project.
97
121
 
98
122
  1. Import Neat into your Sass files:
99
123
 
100
- ```scss
101
- @import "neat";
102
- ```
124
+ ```scss
125
+ @import "neat";
126
+ ```
127
+
128
+ [eyeglass]: http://eyeglass.rocks
103
129
 
104
130
  ### Installing older versions of Neat
105
131
 
106
132
  1. Uninstall any Neat gem versions you already have:
107
133
 
108
- ```bash
109
- gem uninstall neat
110
- ```
134
+ ```bash
135
+ gem uninstall neat
136
+ ```
137
+
138
+ 1. Reinstall the Neat gem, using the `-v` flag to specify the version you need:
111
139
 
112
- 2. Reinstall the Neat gem, using the `-v` flag to specify the version you need:
140
+ ```bash
141
+ gem install neat -v 1.8.1
142
+ ```
113
143
 
114
- ```bash
115
- gem install neat -v 1.8.1
116
- ```
144
+ 1. Follow the [instructions above](#installation) to install Neat into your
145
+ project.
117
146
 
118
- 3. Follow the [instructions above](#installation) to install Neat into your project.
147
+ ## Command Line Interface
148
+
149
+ ```bash
150
+ neat [options]
151
+ ```
152
+
153
+ ### Options
154
+
155
+ | Option | Description |
156
+ | :---------------- | :------------------------ |
157
+ | `-h`, `--help` | Show help |
158
+ | `-v`, `--version` | Show the version number |
159
+ | `--path` | Specify a custom path |
160
+ | `--force` | Force install (overwrite) |
161
+
162
+ ### Commands
163
+
164
+ | Command | Description |
165
+ | :------------- | :------------------------------------------------- |
166
+ | `neat install` | Install Neat into the current directory |
167
+ | `neat update` | Overwrite and update Neat in the current directory |
168
+ | `neat remove` | Removes Neat from the current directory |
169
+ | `neat help` | Show help |
170
+ | `neat version` | Show the version number |
119
171
 
120
172
  ## The Bourbon family
121
173
 
122
- - [Bourbon](https://github.com/thoughtbot/bourbon): A lightweight Sass tool set
123
- - [Neat](https://github.com/thoughtbot/neat): A lightweight and flexible Sass grid
124
- - [Bitters](https://github.com/thoughtbot/bitters): Scaffold styles, variables and structure for Bourbon projects
125
- - [Refills](https://github.com/thoughtbot/refills): Prepackaged patterns and components built with Bourbon, Neat and Bitters
174
+ - [Bourbon]: A lightweight Sass tool set
175
+ - [Bitters]: Scaffold styles, variables and structure for Bourbon projects
176
+ - [Refills]: Components and patterns built with Bourbon and Neat
177
+
178
+ [Bourbon]: https://github.com/thoughtbot/bourbon
179
+ [Bitters]: https://github.com/thoughtbot/bitters
180
+ [Refills]: https://github.com/thoughtbot/refills
126
181
 
127
182
  ## Contributing
128
183
 
@@ -133,17 +188,21 @@ See the [contributing] document. Thank you, [contributors]!
133
188
 
134
189
  ## License
135
190
 
136
- Neat is copyright © 2012 [thoughtbot, inc.][thoughtbot] It is free software, and may be redistributed under the terms specified in the [license].
191
+ Neat is copyright © 2012 [thoughtbot, inc.][thoughtbot] It is free software, and
192
+ may be redistributed under the terms specified in the [license].
137
193
 
138
194
  [license]: LICENSE.md
139
195
 
140
196
  ## About
141
197
 
142
- Neat is maintained by the thoughtbot design team. It is funded by [thoughtbot, inc.][thoughtbot] and the names and logos for thoughtbot are trademarks of thoughtbot, inc.
198
+ Neat is maintained by the thoughtbot design team. It is funded by
199
+ [thoughtbot, inc.][thoughtbot] and the names and logos for thoughtbot are
200
+ trademarks of thoughtbot, inc.
143
201
 
144
202
  [<img src="http://presskit.thoughtbot.com/images/signature.svg" width="250" alt="thoughtbot logo">][thoughtbot]
145
203
 
146
- We love open-source software! See [our other projects][community] or [hire us][hire] to design, develop, and grow your product.
204
+ We love open-source software! See [our other projects][community] or
205
+ [hire us][hire] to design, develop, and grow your product.
147
206
 
148
207
  [thoughtbot]: https://thoughtbot.com?utm_source=github
149
208
  [community]: https://thoughtbot.com/community?utm_source=github
data/bower.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "neat",
3
3
  "description": "A lightweight, semantic grid framework",
4
- "version": "2.0.0",
4
+ "version": "2.1.0",
5
5
  "main": "core/_neat.scss",
6
6
  "license": "MIT",
7
7
  "ignore": [
@@ -54,6 +54,9 @@
54
54
  <div class="grid__column--full">
55
55
  <h3>Push Grid</h3>
56
56
  </div>
57
+ <div class="grid__column--thirds grid-push--3 box"></div>
58
+ <div class="grid__column box"></div>
59
+ <div class="grid__column--thirds box"></div>
57
60
  <div class="grid__column--full">
58
61
  <h3>Shift Grid</h3>
59
62
  </div>
@@ -1,3 +1,8 @@
1
+ $grid--nested: (
2
+ columns: 3,
3
+ gutter: 0,
4
+ );
5
+
1
6
  .grid--nested {
2
7
  @include grid-container($grid--nested);
3
8
  }
@@ -1,3 +1,7 @@
1
+ $grid--rtl: (
2
+ direction: rtl,
3
+ );
4
+
1
5
  .grid {
2
6
  @include grid-container;
3
7
  }
@@ -1,6 +1,5 @@
1
1
  @import "../core/neat";
2
2
 
3
- @import "base/grids";
4
3
  @import "base/variables";
5
4
 
6
5
  @import "patterns/box";
@@ -1,5 +1,5 @@
1
1
  @charset "UTF-8";
2
- // Neat 2.0.0
2
+ // Neat 2.1.0
3
3
  // http://neat.bourbon.io
4
4
  // Copyright 2012 thoughtbot, inc.
5
5
  // MIT License
@@ -1,7 +1,7 @@
1
1
  @charset "UTF-8";
2
2
  /// Determine the ratio of `$columns` to the total column count.
3
3
  /// If `$columns` is more than one value, they are handed to
4
- /// `_neat-parse-columns()` which will detirmine the total columns and use this
4
+ /// `_neat-parse-columns()` which will determine the total columns and use this
5
5
  /// value instead of `total-columns`.
6
6
  ///
7
7
  /// @argument {map} $grid
@@ -17,7 +17,6 @@
17
17
  ///
18
18
  /// @example css
19
19
  /// .element {
20
- /// float: left;
21
20
  /// margin-left: -20px;
22
21
  /// margin-right: -20px;
23
22
  /// width: calc(100% + 40px);
@@ -5,10 +5,6 @@
5
5
  ///
6
6
  /// @name Grid container
7
7
  ///
8
- /// @argument {map} $grid [$neat-grid]
9
- /// The grid to be used to generate the container.
10
- /// By default, the global `$neat-grid` will be used.
11
- ///
12
8
  /// @example scss
13
9
  /// .element {
14
10
  /// @include grid-container;
@@ -22,6 +18,11 @@
22
18
  /// }
23
19
 
24
20
  @mixin grid-container($grid: $neat-grid) {
21
+ @if $grid != $neat-grid {
22
+ @warn "`grid-container` does not use grid propertes.
23
+ Custom grids do not need to be passed in to this mixin.";
24
+ }
25
+
25
26
  &::after {
26
27
  clear: both;
27
28
  content: "";
@@ -9,7 +9,7 @@
9
9
  /// The number of columns to push the column.
10
10
  ///
11
11
  /// @argument {map} $grid [$neat-grid]
12
- /// The grid to be used to detirmine how far to push the column.
12
+ /// The grid to be used to determine how far to push the column.
13
13
  /// By default, the global `$neat-grid` will be used.
14
14
  ///
15
15
  /// @example scss
@@ -10,7 +10,7 @@
10
10
  /// The number of columns to shift the column.
11
11
  ///
12
12
  /// @argument {map} $grid [$neat-grid]
13
- /// The grid to be used to detirmine how far to shift the column.
13
+ /// The grid to be used to determine how far to shift the column.
14
14
  /// By default, the global `$neat-grid` will be used.
15
15
  ///
16
16
  /// @example scss
@@ -19,7 +19,7 @@
19
19
  ///
20
20
  /// @example css
21
21
  /// .element {
22
- /// background-image: linear-gradient( … ) ;
22
+ /// background-image: repeating-linear-gradient( … ) ;
23
23
  /// }
24
24
 
25
25
  @mixin grid-visual($color: null, $grid: $neat-grid) {
@@ -29,39 +29,13 @@
29
29
 
30
30
  $_grid-columns: _retrieve-neat-setting($grid, columns);
31
31
  $_grid-gutter: _retrieve-neat-setting($grid, gutter);
32
- $_grid-visual-object: () !default;
32
+ $_grid-visual-column: "#{_neat-column-width($grid, 1)} + #{$_grid-gutter}";
33
33
  $_grid-visual:
34
- $color,
35
- $color $_grid-gutter,
34
+ transparent,
36
35
  transparent $_grid-gutter,
36
+ $color $_grid-gutter,
37
+ $color calc(#{$_grid-visual-column}),
37
38
  ;
38
39
 
39
- @for $i from 1 to $_grid-columns {
40
- $_grid-visual-local: (
41
- #{$i}: "#{_neat-column-width($grid, $i)} + #{$_grid-gutter}",
42
- );
43
-
44
- $_grid-visual-object: map-merge($_grid-visual-object, $_grid-visual-local);
45
- }
46
-
47
- @each $stop, $location in $_grid-visual-object {
48
- $_grid-visual-loop-list:
49
- transparent calc(#{$location}),
50
- $color calc(#{$location}),
51
- $color calc(#{$location} + #{$_grid-gutter}),
52
- transparent calc(#{$location} + #{$_grid-gutter}),
53
- ;
54
-
55
- $_grid-visual: _neat-append-grid-visual($_grid-visual, $_grid-visual-loop-list);
56
- }
57
-
58
- $_grid-visual-loop-list:
59
- transparent calc(100% - #{$_grid-gutter}),
60
- $color calc(100% - #{$_grid-gutter}),
61
- $color calc(100%),
62
- ;
63
-
64
- $_grid-visual: _neat-append-grid-visual($_grid-visual, $_grid-visual-loop-list);
65
-
66
- background-image: linear-gradient(to right, $_grid-visual);
40
+ background-image: repeating-linear-gradient(to right, $_grid-visual);
67
41
  }
@@ -1,6 +1,6 @@
1
1
  @charset "UTF-8";
2
2
  /// This variable is a sass map that overrides Neat's default grid settings.
3
- /// Use this to define your project's grid properties incluting gutters and
3
+ /// Use this to define your project's grid properties including gutters and
4
4
  /// total column count.
5
5
  ///
6
6
  /// @type map
@@ -47,7 +47,7 @@ $neat-grid: () !default;
47
47
  ///
48
48
  /// @property {number (with unit) | string | null} media [null]
49
49
  /// The `@media` definition that is used by the [`grid-media`](#grid-media)
50
- /// mixin to detirmine the media properties.
50
+ /// mixin to determine the media properties.
51
51
  ///
52
52
  /// @property {color} color [null]
53
53
  /// The color used by [`grid-visual`](#grid-visual) to create the guides.
@@ -1,7 +1,4 @@
1
+ require "sass"
1
2
  require "neat/generator"
2
3
 
3
- neat_path = File.expand_path("../../core", __FILE__)
4
- ENV["SASS_PATH"] = [
5
- ENV["SASS_PATH"],
6
- neat_path,
7
- ].compact.join(File::PATH_SEPARATOR)
4
+ Sass.load_paths << File.expand_path("../../core", __FILE__)
@@ -7,16 +7,18 @@ module Neat
7
7
  map ["-v", "--version"] => :version
8
8
 
9
9
  desc "install", "Install Neat into your project"
10
+ method_options path: :string, force: :boolean
10
11
  def install
11
- if neat_files_already_exist?
12
+ if neat_files_already_exist? && !options[:force]
12
13
  puts "Neat files already installed, doing nothing."
13
14
  else
14
15
  install_files
15
- puts "Neat files installed to neat/"
16
+ puts "Neat files installed to #{install_path}/"
16
17
  end
17
18
  end
18
19
 
19
20
  desc "update", "Update Neat"
21
+ method_options path: :string
20
22
  def update
21
23
  if neat_files_already_exist?
22
24
  remove_neat_directory
@@ -28,6 +30,7 @@ module Neat
28
30
  end
29
31
 
30
32
  desc "remove", "Remove Neat"
33
+ method_options path: :string
31
34
  def remove
32
35
  if neat_files_already_exist?
33
36
  remove_neat_directory
@@ -45,16 +48,32 @@ module Neat
45
48
  private
46
49
 
47
50
  def neat_files_already_exist?
48
- File.directory?("neat")
51
+ install_path.exist?
49
52
  end
50
53
 
51
- def install_files
52
- FileUtils.mkdir_p("neat")
53
- FileUtils.cp_r(all_stylesheets, "neat/")
54
+ def install_path
55
+ @install_path ||= if options[:path]
56
+ Pathname.new(File.join(options[:path], "neat"))
57
+ else
58
+ Pathname.new("neat")
59
+ end
54
60
  end
55
61
 
56
62
  def remove_neat_directory
57
- FileUtils.rm_rf("neat")
63
+ FileUtils.rm_rf(install_path)
64
+ end
65
+
66
+ def install_files
67
+ make_install_directory
68
+ copy_in_scss_files
69
+ end
70
+
71
+ def make_install_directory
72
+ FileUtils.mkdir_p(install_path)
73
+ end
74
+
75
+ def copy_in_scss_files
76
+ FileUtils.cp_r(all_stylesheets, install_path)
58
77
  end
59
78
 
60
79
  def all_stylesheets
@@ -1,3 +1,3 @@
1
1
  module Neat
2
- VERSION = "2.0.0"
2
+ VERSION = "2.1.0"
3
3
  end
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "bourbon-neat",
3
- "version": "2.0.0",
3
+ "version": "2.1.0",
4
4
  "description": "A lightweight, semantic grid framework",
5
5
  "keywords": [
6
6
  "columns",
@@ -25,6 +25,7 @@
25
25
  "url": "http://thoughtbot.com"
26
26
  },
27
27
  "main": "index.js",
28
+ "style": "core/_neat.scss",
28
29
  "repository": {
29
30
  "type": "git",
30
31
  "url": "https://github.com/thoughtbot/neat.git"
@@ -36,8 +37,8 @@
36
37
  "devDependencies": {
37
38
  "gulp": "^3.9",
38
39
  "gulp-autoprefixer": "^3.1",
39
- "gulp-connect": "^2.3",
40
- "gulp-sass": "^2.2"
40
+ "gulp-connect": "^5.0",
41
+ "gulp-sass": "^3.1"
41
42
  },
42
43
  "eyeglass": {
43
44
  "name": "neat",
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: neat
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.0.0
4
+ version: 2.1.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Joel Oliveira
@@ -14,7 +14,7 @@ authors:
14
14
  autorequire:
15
15
  bindir: bin
16
16
  cert_chain: []
17
- date: 2017-02-17 00:00:00.000000000 Z
17
+ date: 2017-06-27 00:00:00.000000000 Z
18
18
  dependencies:
19
19
  - !ruby/object:Gem::Dependency
20
20
  name: aruba
@@ -121,12 +121,15 @@ executables:
121
121
  extensions: []
122
122
  extra_rdoc_files: []
123
123
  files:
124
+ - ".github/ISSUE_TEMPLATE.md"
125
+ - ".github/PULL_REQUEST_TEMPLATE.md"
124
126
  - ".gitignore"
125
127
  - ".hound.yml"
126
128
  - ".npmignore"
127
129
  - ".ruby-version"
128
130
  - ".scss-lint.yml"
129
131
  - CHANGELOG.md
132
+ - CODE_OF_CONDUCT.md
130
133
  - CONTRIBUTING.md
131
134
  - Gemfile
132
135
  - Gulpfile.js
@@ -137,7 +140,6 @@ files:
137
140
  - bin/neat
138
141
  - bower.json
139
142
  - circle.yml
140
- - contrib/base/_grids.scss
141
143
  - contrib/base/_variables.scss
142
144
  - contrib/index.html
143
145
  - contrib/patterns/_box.scss
@@ -229,7 +231,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
229
231
  version: '0'
230
232
  requirements: []
231
233
  rubyforge_project:
232
- rubygems_version: 2.6.8
234
+ rubygems_version: 2.6.12
233
235
  signing_key:
234
236
  specification_version: 4
235
237
  summary: A lightweight Sass grid framework
@@ -1,8 +0,0 @@
1
- $grid--nested: (
2
- columns: 3,
3
- gutter: 0,
4
- );
5
-
6
- $grid--rtl: (
7
- direction: rtl,
8
- );