puma_dynamic_tags 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/CHANGELOG.md +4 -0
- data/README.md +14 -7
- data/lib/puma/plugin/dynamic_tags/puma_patches.rb +8 -0
- data/puma_dynamic_tags.gemspec +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 529dc06aeb20f634932e05a5dfad386636e6cbad19784a31d15e4809f5ff4a98
|
4
|
+
data.tar.gz: ca79679e00c56b4146a66160ea8764153978552c116326dff7be08c84e4dcc31
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 5dc990399d3987517ad107770c56cfcd7d365e908c0fe9bd359e64ccae52312a33e0c796b79de186e9ffb3360e287aa275932beee6c3fa12b95876bc1838c538
|
7
|
+
data.tar.gz: 688a90958b586a5913e69892840dff2ac346a5f0a9ee20c1f33945623c37283302bc9a1d510404d86f6e1dc9b81ebcfff912d76ff50ca37e65fe66664e61dcc8
|
data/CHANGELOG.md
CHANGED
data/README.md
CHANGED
@@ -19,20 +19,27 @@ bundle install
|
|
19
19
|
|
20
20
|
## Usage
|
21
21
|
|
22
|
-
```ruby
|
23
|
-
# in your gem requirements
|
24
|
-
require "puma_dynamic_tags"
|
25
|
-
```
|
26
|
-
|
27
22
|
```ruby
|
28
23
|
# config/puma.rb
|
29
|
-
plugin
|
24
|
+
plugin "puma_dynamic_tags"
|
30
25
|
|
31
26
|
tag do
|
32
|
-
# your dynamic code
|
27
|
+
"some_dynamic_result" # your dynamic code
|
33
28
|
end
|
34
29
|
```
|
35
30
|
|
31
|
+
and then:
|
32
|
+
|
33
|
+
```shell
|
34
|
+
puma
|
35
|
+
```
|
36
|
+
|
37
|
+
and then:
|
38
|
+
|
39
|
+
```shell
|
40
|
+
pas aux | grep puma
|
41
|
+
```
|
42
|
+
|
36
43
|
## Contributing
|
37
44
|
|
38
45
|
- Fork it ( https://github.com/0exp/puma_dynamic_tags )
|
@@ -10,6 +10,12 @@ module Puma::Plugin::DuynamicTags
|
|
10
10
|
tag_option
|
11
11
|
end
|
12
12
|
end
|
13
|
+
|
14
|
+
module DSLTagExtension
|
15
|
+
def tag(string = nil, &block)
|
16
|
+
@options[:tag] = block_given? ? block : string.to_s
|
17
|
+
end
|
18
|
+
end
|
13
19
|
end
|
14
20
|
|
15
21
|
Puma::Launcher.prepend(Module.new do
|
@@ -21,3 +27,5 @@ Puma::Launcher.prepend(Module.new do
|
|
21
27
|
@options
|
22
28
|
end
|
23
29
|
end)
|
30
|
+
|
31
|
+
Puma::DSL.prepend(Puma::Plugin::DuynamicTags::DSLTagExtension)
|
data/puma_dynamic_tags.gemspec
CHANGED
@@ -4,7 +4,7 @@ Gem::Specification.new do |spec|
|
|
4
4
|
spec.required_ruby_version = '>= 2.6.0'
|
5
5
|
|
6
6
|
spec.name = 'puma_dynamic_tags'
|
7
|
-
spec.version = '0.1.
|
7
|
+
spec.version = '0.1.1'
|
8
8
|
spec.authors = ['Rustam Ibragimov']
|
9
9
|
spec.email = ['exfivedaiver@gmail.com']
|
10
10
|
spec.homepage = 'https://github.com/0exp/puma_dynamic_tags'
|