lb-project 0.1.0 → 0.1.1

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
  SHA256:
3
- metadata.gz: 5277950049547e259c4a214d9ca156e97609a8c0d0977783bd1de8f1b615cc1a
4
- data.tar.gz: 292b0bedc18ac29e6df8f23428da5ec7f83d9b2e185574bfb7aae3b487627568
3
+ metadata.gz: 9f1933319af3ce3333456607636bcc90c5bdef86ff4f566564bcddb87f04d5bf
4
+ data.tar.gz: 1324cbf4adfe901a4daca6717a018844f7545c6f17b598ffdfee528e3c3667fd
5
5
  SHA512:
6
- metadata.gz: 97272185aeb10d66d3b4ef61c89a05805c77667f5ad936448e1848f4735ef1232138fe3ca45c8b2954b563711b8ea6b68935be0e0412913f4e9b1b02d12e001f
7
- data.tar.gz: 496cceee927c6a3d3608424064abae94c0ed105ef6fd80ac0d49d3e23aca6093f64c25cce9a5be07e6211cc9d85c4782c2067fd5c610d3d8e11606f1951dcde0
6
+ metadata.gz: 7ffbba086fb2ab6171d9cf8deb20f443cb78aa6b60e544bec681c7c1719a950b387a8db820e62e972269d498de4bf03d82c1f966174a747069642e7e3da71417
7
+ data.tar.gz: f97fd83b3efc966484ca78d599140069081863fe8335528deb71a7aa657af65c94ceabaf5fc2f4843cde065ed625844663fbce1e8b680ed449566772e0a5d1b6
@@ -129,6 +129,9 @@ module LB
129
129
  end
130
130
  end
131
131
 
132
+ # API
133
+ require 'lb/project/api'
134
+
132
135
  # Site
133
136
  require 'lb/project/site'
134
137
 
@@ -0,0 +1,70 @@
1
+ # frozen_string_literal: true
2
+
3
+ module LB
4
+ module Project
5
+ # LB::Project API
6
+ module API
7
+ # Get root path
8
+ #
9
+ # @return [dir_name]
10
+ #
11
+ # @api private
12
+ #
13
+ def root
14
+ LB::Project.root
15
+ end
16
+
17
+ # Get root path for file
18
+ #
19
+ # @param [File] file The file to get the root path from
20
+ # @param [File] depth The depth of the given file relative from the root
21
+ # directory
22
+ #
23
+ # @return [dir_name]
24
+ #
25
+ # @api private
26
+ #
27
+ def root_for(file, depth = 2)
28
+ LB::Project.root_for(file, depth)
29
+ end
30
+
31
+ # Get template path
32
+ #
33
+ # @return [dir_name]
34
+ #
35
+ # @api private
36
+ #
37
+ def self.template_path
38
+ LB::Project.template_path
39
+ end
40
+
41
+ # Get public path
42
+ #
43
+ # @return [dir_name]
44
+ #
45
+ # @api private
46
+ #
47
+ def self.public_path
48
+ LB::Project.public_path
49
+ end
50
+
51
+ # Get main configuration
52
+ #
53
+ # @return [Config]
54
+ #
55
+ # @api private
56
+ #
57
+ def self.config
58
+ LB::Project.config
59
+ end
60
+
61
+ def self.t(*params)
62
+ LB::Project.t(*params)
63
+ end
64
+
65
+ def self.logger
66
+ LB::Project.logger
67
+ end
68
+ end
69
+ end
70
+ end
@@ -3,6 +3,6 @@
3
3
  module LB
4
4
  module Project
5
5
  # Version
6
- VERSION = '0.1.0'
6
+ VERSION = '0.1.1'
7
7
  end
8
8
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: lb-project
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.1.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Firas Zaidan
@@ -227,6 +227,7 @@ files:
227
227
  - lb-project.gemspec
228
228
  - lib/lb-project.rb
229
229
  - lib/lb/project.rb
230
+ - lib/lb/project/api.rb
230
231
  - lib/lb/project/app.rb
231
232
  - lib/lb/project/config.rb
232
233
  - lib/lb/project/page.rb