sass-scaffold 0.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +7 -0
- data/bin/sass-scaffold +4 -0
- data/lib/sass-scaffold.rb +36 -0
- metadata +46 -0
checksums.yaml
ADDED
@@ -0,0 +1,7 @@
|
|
1
|
+
---
|
2
|
+
SHA1:
|
3
|
+
metadata.gz: eab42ac20e9a1ccdd4b504c97d6166043499db60
|
4
|
+
data.tar.gz: 86d243ca3e9d3cfc20bea55a2a9ff568b5df5456
|
5
|
+
SHA512:
|
6
|
+
metadata.gz: 25613c173964777a6b3626f049af245ada0664590fec8358772e62ff25341143f1475b3b01c5316e068a792b43a799595f28ae8cc08d172a402c9f4c83a62371
|
7
|
+
data.tar.gz: 0f8bb0ad83274da57cbd3dea15ef0dfcaf1729593b25979d9d2e2a0207f455dfeda9bc20c5f0bcb258df61406067ade4b6b7e008348f5bbb5a56f5022446336f
|
data/bin/sass-scaffold
ADDED
@@ -0,0 +1,36 @@
|
|
1
|
+
class SassScaffold
|
2
|
+
SETTINGS_DIR = "settings"
|
3
|
+
SECTIONS_DIR = "sections"
|
4
|
+
SETTINGS_FILES = ["sizes", "fonts", "colors", "mixins", "breakpoints"]
|
5
|
+
SECTION_FILES = ["base", "header", "footer"]
|
6
|
+
BASE_FILE_NAME = "style"
|
7
|
+
def self.build
|
8
|
+
#build settings directory
|
9
|
+
Dir.mkdir SETTINGS_DIR
|
10
|
+
Dir.chdir SETTINGS_DIR
|
11
|
+
SETTINGS_FILES.each do |f|
|
12
|
+
File.new("_#{f}.scss", "w").close
|
13
|
+
end
|
14
|
+
File.open("_#{SETTINGS_DIR}.scss", "w+") do |file|
|
15
|
+
SETTINGS_FILES.each do |f|
|
16
|
+
file.write("@import '#{f}';\n")
|
17
|
+
end
|
18
|
+
end
|
19
|
+
#move out of settings dir
|
20
|
+
Dir.chdir ".."
|
21
|
+
Dir.mkdir SECTIONS_DIR
|
22
|
+
Dir.chdir SECTIONS_DIR
|
23
|
+
#build basic sections
|
24
|
+
SECTION_FILES.each do |f|
|
25
|
+
File.new("#{f}.scss", "w").close
|
26
|
+
end
|
27
|
+
#move back out and build base file
|
28
|
+
Dir.chdir ".."
|
29
|
+
File.open("#{BASE_FILE_NAME}.scss", "w+") do |file|
|
30
|
+
file.write("@import '#{SETTINGS_DIR}/#{SETTINGS_DIR}';\n\n")
|
31
|
+
SECTION_FILES.each do |f|
|
32
|
+
file.write("@import '#{SECTIONS_DIR}/#{f}';\n")
|
33
|
+
end
|
34
|
+
end
|
35
|
+
end
|
36
|
+
end
|
metadata
ADDED
@@ -0,0 +1,46 @@
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
|
+
name: sass-scaffold
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 0.0.1
|
5
|
+
platform: ruby
|
6
|
+
authors:
|
7
|
+
- Ben Potter
|
8
|
+
autorequire:
|
9
|
+
bindir: bin
|
10
|
+
cert_chain: []
|
11
|
+
date: 2014-03-10 00:00:00.000000000 Z
|
12
|
+
dependencies: []
|
13
|
+
description: Gem for scaffolding a SASS folder structure
|
14
|
+
email: benjamin.potter@live.com
|
15
|
+
executables:
|
16
|
+
- sass-scaffold
|
17
|
+
extensions: []
|
18
|
+
extra_rdoc_files: []
|
19
|
+
files:
|
20
|
+
- lib/sass-scaffold.rb
|
21
|
+
- bin/sass-scaffold
|
22
|
+
homepage: http://rubygems.org/gems/sass-scaffold
|
23
|
+
licenses:
|
24
|
+
- MIT
|
25
|
+
metadata: {}
|
26
|
+
post_install_message:
|
27
|
+
rdoc_options: []
|
28
|
+
require_paths:
|
29
|
+
- lib
|
30
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
31
|
+
requirements:
|
32
|
+
- - ">="
|
33
|
+
- !ruby/object:Gem::Version
|
34
|
+
version: '0'
|
35
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
36
|
+
requirements:
|
37
|
+
- - ">="
|
38
|
+
- !ruby/object:Gem::Version
|
39
|
+
version: '0'
|
40
|
+
requirements: []
|
41
|
+
rubyforge_project:
|
42
|
+
rubygems_version: 2.0.14
|
43
|
+
signing_key:
|
44
|
+
specification_version: 4
|
45
|
+
summary: SASS Scaffold
|
46
|
+
test_files: []
|