rails-lineman 0.1.0 → 0.1.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 +4 -4
- data/README.md +36 -2
- data/lib/rails_lineman/lineman_doer.rb +2 -3
- data/lib/rails_lineman/version.rb +1 -1
- data/rails-lineman.gemspec +1 -1
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 6790909aea1e6314f0f4921f925d6d7e2c54f461
|
4
|
+
data.tar.gz: 5af34142f627fc34fb0622614d6af9aa650cb188
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 0aa9f969c8c098b687533f461c9c52849d76707705a8b0928df86ff856654b9bbf657bbef7e5cda6ed1d9d1e0e7f03711ebdf8e03a91902cc176d1a8af716443
|
7
|
+
data.tar.gz: 4fd7bcb19b3c025444dc1c3c3c54ce6c0344f8b3417c5c83da34ea44122885b0fa07699dd0b52df287a6f25a909b566b93671498a5be1ede486c4d2d45bf6ebc
|
data/README.md
CHANGED
@@ -5,9 +5,43 @@ assets.
|
|
5
5
|
|
6
6
|
Wraps the `assets:precompile` rake task by building a specified lineman project.
|
7
7
|
|
8
|
-
|
8
|
+
## Pointing at your lineman project
|
9
9
|
|
10
|
-
|
10
|
+
In `config/application.rb`, tell the gem where to find your Lineman project:
|
11
|
+
|
12
|
+
```
|
13
|
+
config.rails_lineman.lineman_project_location = "some-directory"
|
14
|
+
```
|
15
|
+
|
16
|
+
You can also set an environment variable named `LINEMAN_PROJECT_LOCATION`
|
17
|
+
|
18
|
+
## Specifying asset types
|
19
|
+
|
20
|
+
By default, rails-lineman will only copy `dist/js` and `dist/css` from your Lineman
|
21
|
+
build to your Rails assets. To include other assets, like `dist/webfonts`, just add
|
22
|
+
them like so:
|
23
|
+
|
24
|
+
```
|
25
|
+
config.rails_lineman.lineman_assets = [:webfonts, :css, :js]
|
26
|
+
```
|
27
|
+
|
28
|
+
You can also set an environment variable named `LINEMAN_ASSETS`
|
29
|
+
|
30
|
+
**Heads up:** if you add additional asset directories like above, you'll want to set up
|
31
|
+
the same directories as static routes for Lineman's development server. For example,
|
32
|
+
in your `config/application.js` file:
|
33
|
+
|
34
|
+
```
|
35
|
+
//...
|
36
|
+
server: {
|
37
|
+
staticRoutes: {
|
38
|
+
'/assets/webfonts': 'webfonts'
|
39
|
+
}
|
40
|
+
}
|
41
|
+
//...
|
42
|
+
```
|
43
|
+
|
44
|
+
## Referencing Lineman assets from your Rails views
|
11
45
|
|
12
46
|
From your templates you'll be able to require lineman-built JS & CSS like so:
|
13
47
|
|
@@ -72,8 +72,7 @@ module RailsLineman
|
|
72
72
|
end
|
73
73
|
|
74
74
|
def destroy
|
75
|
-
|
76
|
-
delete
|
75
|
+
delete_some_assets_for_whatever_reason if @remove_lineman_assets_after_asset_pipeline_precompilation
|
77
76
|
delete_tmp_dir
|
78
77
|
end
|
79
78
|
|
@@ -165,7 +164,7 @@ module RailsLineman
|
|
165
164
|
@assets.map(&:add_if_precompilable)
|
166
165
|
end
|
167
166
|
|
168
|
-
def
|
167
|
+
def delete_some_assets_for_whatever_reason
|
169
168
|
@assets.map(&:delete)
|
170
169
|
end
|
171
170
|
|
data/rails-lineman.gemspec
CHANGED
@@ -10,7 +10,7 @@ Gem::Specification.new do |spec|
|
|
10
10
|
spec.email = ["searls@gmail.com"]
|
11
11
|
spec.description = %q{Helps Rails apps integrate a Lineman into their build by wrapping rake assets:precompile}
|
12
12
|
spec.summary = %q{Helps Rails apps integrate a Lineman into their build by wrapping rake assets:precompile.}
|
13
|
-
spec.homepage = ""
|
13
|
+
spec.homepage = "https://github.com/linemanjs/rails-lineman"
|
14
14
|
spec.license = "MIT"
|
15
15
|
|
16
16
|
spec.files = `git ls-files`.split($/)
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: rails-lineman
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Justin Searls
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2014-
|
11
|
+
date: 2014-04-12 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rake
|
@@ -59,7 +59,7 @@ files:
|
|
59
59
|
- lib/rails_lineman/version.rb
|
60
60
|
- lib/tasks/assets_precompile.rake
|
61
61
|
- rails-lineman.gemspec
|
62
|
-
homepage:
|
62
|
+
homepage: https://github.com/linemanjs/rails-lineman
|
63
63
|
licenses:
|
64
64
|
- MIT
|
65
65
|
metadata: {}
|