lono 7.2.0 → 7.2.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +3 -0
- data/lib/lono/extensions/loader.rb +7 -10
- data/lib/lono/extensions/preparer.rb +2 -3
- data/lib/lono/template/strategy/dsl/builder.rb +2 -0
- data/lib/lono/version.rb +1 -1
- data/lib/templates/blueprint/Gemfile +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: c17c7945bfc25050f4bba832aa84181fa3dbe5936b7091dbb9e229439ee791e7
|
4
|
+
data.tar.gz: 9e70a07cf9b49154af4c35895e9168a8b044aeed73ed9ffab19d648727a2f5aa
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: e8d2c8de40d9b10801fad58420696d8bc0ce40d831b84bd2d9a060c25295c8a0eba29084a12071c96c5347366811581ebc8004319b07be2049f6cc8811f12ca0
|
7
|
+
data.tar.gz: '08fcdb268f588cf77f16c4c684940727533665c00e868a1f1c6251325a974987c92feeb68983e105288b21d47ff3db14bdad61e10a9fa84d66793f20b4e1dd07'
|
data/CHANGELOG.md
CHANGED
@@ -3,6 +3,9 @@
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
4
4
|
This project *tries* to adhere to [Semantic Versioning](http://semver.org/), even before v1.0.
|
5
5
|
|
6
|
+
## [7.2.1]
|
7
|
+
- #51 fix extensions helpers loading and cleanup
|
8
|
+
|
6
9
|
## [7.2.0]
|
7
10
|
- #48 fix codebuild and circleci
|
8
11
|
- #49 lono extensions
|
@@ -1,16 +1,17 @@
|
|
1
1
|
class Lono::Extensions
|
2
|
-
|
2
|
+
module Loader
|
3
3
|
include Lono::Template::Context::Loader::LoadFiles
|
4
4
|
|
5
|
-
def
|
5
|
+
def load_all_extension_helpers
|
6
6
|
Lono::Jade::Registry.tracked_extensions.each do |registry|
|
7
7
|
load_extension_helpers(registry)
|
8
8
|
end
|
9
9
|
end
|
10
10
|
|
11
11
|
def load_extension_helpers(registry)
|
12
|
-
root =
|
12
|
+
root = find_extensions_root_path(registry)
|
13
13
|
helpers_path = "#{root}/lib/#{registry.name}/helpers"
|
14
|
+
|
14
15
|
load_files(helpers_path)
|
15
16
|
end
|
16
17
|
|
@@ -19,14 +20,10 @@ class Lono::Extensions
|
|
19
20
|
# 2. normal gem
|
20
21
|
# 3. materialized gem
|
21
22
|
#
|
22
|
-
def
|
23
|
-
|
23
|
+
def find_extensions_root_path(registry)
|
24
|
+
@finder ||= Lono::Finder::Extension.new
|
25
|
+
jadespec = @finder.find(registry.name)
|
24
26
|
jadespec.root
|
25
27
|
end
|
26
|
-
|
27
|
-
def finder
|
28
|
-
Lono::Finder::Extension.new
|
29
|
-
end
|
30
|
-
memoize :finder
|
31
28
|
end
|
32
29
|
end
|
@@ -3,14 +3,13 @@ class Lono::Extensions
|
|
3
3
|
def initialize(options={})
|
4
4
|
super
|
5
5
|
@register = Register.new(options)
|
6
|
-
@loader = Loader.new(options)
|
7
6
|
end
|
8
7
|
|
9
8
|
def run
|
10
9
|
@register.run
|
11
10
|
materialize
|
12
|
-
#
|
13
|
-
|
11
|
+
# loading happens in Lono::Extensions::Loader load_all_extension_helpers module
|
12
|
+
# so it has the proper self.class include scope
|
14
13
|
end
|
15
14
|
|
16
15
|
def materialize
|
@@ -2,6 +2,7 @@ class Lono::Template::Strategy::Dsl
|
|
2
2
|
class Builder
|
3
3
|
include Lono::Template::Util
|
4
4
|
include Lono::Template::Context::Loader
|
5
|
+
include Lono::Extensions::Loader
|
5
6
|
|
6
7
|
include Syntax
|
7
8
|
extend Memoist
|
@@ -27,6 +28,7 @@ class Lono::Template::Strategy::Dsl
|
|
27
28
|
# load_extensions and evaluate extend_with methods earlier than load_context so project helpers can override extensions
|
28
29
|
def load_extensions # evaluates extend_with
|
29
30
|
Lono::Extensions::Preparer.new(@options).run
|
31
|
+
load_all_extension_helpers # after Extensions::Preparer#run
|
30
32
|
end
|
31
33
|
|
32
34
|
def finalize
|
data/lib/lono/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: lono
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 7.2.
|
4
|
+
version: 7.2.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Tung Nguyen
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2020-02-
|
11
|
+
date: 2020-02-27 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activesupport
|