documentation-test 0.4.0 → 0.4.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/my_module_handler.rb +17 -0
- data/yard_extentions.rb +1 -0
- metadata +3 -1
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 92b2b4085e90814d2d5b094c6b6976a060fed08a2aac5866e7c1666ffdf3ddab
|
|
4
|
+
data.tar.gz: ce76f8f2817b4c8547b7397093541ca03cba92308987b90607f00da0d27b9225
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 29ae02a5f01f95f7fd7efde277cd045c3f294a65ec91d624f086d0b40a3be6fddc88daadf309041f479678bdb1fcd04f0d5e60761d3cd67a64cc9df178ab7e66
|
|
7
|
+
data.tar.gz: ad01ac18c7c8f4cf40f856280b3e9b3008e58e687fdd560de7317ef99cadfe37ad611ebe38f2d32b3d16a5a40014147da2d822e5afd671c33ff7083671be68c8
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
class MethodifyHandler < YARD::Handlers::Ruby::Base
|
|
2
|
+
handles method_call(:methodify)
|
|
3
|
+
namespace_only
|
|
4
|
+
|
|
5
|
+
process do
|
|
6
|
+
name = statement.parameters.first.jump(:tstring_content, :ident).source
|
|
7
|
+
object = YARD::CodeObjects::MethodObject.new(namespace, name + "lololol")
|
|
8
|
+
register(object)
|
|
9
|
+
parse_block(statement.last.last, :owner => object)
|
|
10
|
+
|
|
11
|
+
# modify the object
|
|
12
|
+
object.dynamic = true
|
|
13
|
+
|
|
14
|
+
# add custom metadata to the object
|
|
15
|
+
object['custom_field'] = 'Generated by Methodify'
|
|
16
|
+
end
|
|
17
|
+
end
|
data/yard_extentions.rb
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
require_relative './doc/scripts/my_module_handler'
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: documentation-test
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.4.
|
|
4
|
+
version: 0.4.1
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Jojo the fripouille
|
|
@@ -22,6 +22,8 @@ files:
|
|
|
22
22
|
- README.md
|
|
23
23
|
- doc/read-this.md
|
|
24
24
|
- lib/documentation-test.rb
|
|
25
|
+
- my_module_handler.rb
|
|
26
|
+
- yard_extentions.rb
|
|
25
27
|
homepage: https://github.com/klaxit/documentation-test
|
|
26
28
|
licenses:
|
|
27
29
|
- BSD-3-Clause
|