mediawiki-butt 0.10.1 → 0.10.2

Sign up to get free protection for your applications and to get access to all the features.
Files changed (4) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +4 -0
  3. data/lib/mediawiki/constants.rb +130 -128
  4. metadata +8 -9
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: ddfec6f472aa4fe3d28f9f2d8524caa2e0b6eb4c
4
- data.tar.gz: be269251011a8d5b94806bfab13e8e7450813bd9
3
+ metadata.gz: c6cd0d3fee9b80b873fbedeed12ccff083b43cc1
4
+ data.tar.gz: 4435690ca4f67a835b4614ce3227b39465508011
5
5
  SHA512:
6
- metadata.gz: b22a8038e2dee7a8612ed9e2695b370a71e00dfd507799cfe360fa28d748395868c8bd7786826a3cb6594b4a82f292b76a66045fe2a807d9e2b8965975ac7260
7
- data.tar.gz: 1c87b00f96917ca054b624883cd24d482756976d2932b6af63a75d81e05f2407865da74e6be148b4631734323a3a10a3c93ebb8fbc3e0dd252198326572d1467
6
+ metadata.gz: e2b1d77056b00567590ab6ab33b625aac183698a9754a9bdc1672af8eb7804a11e99119d0f88a74c2e516b2bff155c2116499eab8dd89eee81e5cb63fba6cf79
7
+ data.tar.gz: 9eaadab494bf91434b38aae43a4edcd39a8901d7e7229577de383c4bb6ae5af0fe75167a54a96cb66c81e03e2ce0dba22b9fd26928ee2e279680df04ffd35402
data/CHANGELOG.md CHANGED
@@ -1,5 +1,9 @@
1
1
  # Changelog
2
2
  ## Version 0
3
+ ### Version 0.10.2
4
+ * Update to Ruby 2.3 and HTTPClient 2.7
5
+ * All values in Constants, including the keys and values in the NAMESPACES constant, are now frozen objects.
6
+
3
7
  ### Version 0.10.1
4
8
  * Add the accidentally forgotten protect.rb file to the list of files for the gemspec.
5
9
 
@@ -5,220 +5,222 @@ module MediaWiki
5
5
  # @since 0.8.0 as its current state.
6
6
  # @see https://www.mediawiki.org/wiki/Extension_default_namespaces
7
7
  # MediaWiki's list of extension namespace IDs and names.
8
+ # @return [Hash<String, Integer>] The upcased namespace names, and their according ID. The keys, values, and
9
+ # return value itself are all immutable.
8
10
  NAMESPACES = {
9
- 'MAIN' => 0,
10
- 'TALK' => 1,
11
- 'USER' => 2,
12
- 'USER_TALK' => 3,
13
- 'PROJECT' => 4,
14
- 'PROJECT_TALK' => 5,
15
- 'FILE' => 6,
16
- 'FILE_TALK' => 7,
17
- 'MEDIAWIKI' => 8,
18
- 'MEDIAWIKI_TALK' => 9,
19
- 'TEMPLATE' => 10,
20
- 'TEMPLATE_TALK' => 11,
21
- 'HELP' => 12,
22
- 'HELP_TALK' => 13,
23
- 'CATEGORY' => 14,
24
- 'CATEGORY_TALK' => 15,
25
- 'SPECIAL' => -1,
26
- 'MEDIA' => -2,
11
+ 'MAIN'.freeze => 0.freeze,
12
+ 'TALK'.freeze => 1.freeze,
13
+ 'USER'.freeze => 2.freeze,
14
+ 'USER_TALK'.freeze => 3.freeze,
15
+ 'PROJECT'.freeze => 4.freeze,
16
+ 'PROJECT_TALK'.freeze => 5.freeze,
17
+ 'FILE'.freeze => 6.freeze,
18
+ 'FILE_TALK'.freeze => 7.freeze,
19
+ 'MEDIAWIKI'.freeze => 8.freeze,
20
+ 'MEDIAWIKI_TALK'.freeze => 9.freeze,
21
+ 'TEMPLATE'.freeze => 10.freeze,
22
+ 'TEMPLATE_TALK'.freeze => 11.freeze,
23
+ 'HELP'.freeze => 12.freeze,
24
+ 'HELP_TALK'.freeze => 13.freeze,
25
+ 'CATEGORY'.freeze => 14.freeze,
26
+ 'CATEGORY_TALK'.freeze => 15.freeze,
27
+ 'SPECIAL'.freeze => -1.freeze,
28
+ 'MEDIA'.freeze => -2.freeze,
27
29
 
28
30
  # Extension:LiquidThreads
29
- 'LQT_THREAD' => 90,
30
- 'LQT_THREAD_TALK' => 91,
31
- 'LQT_SUMMARY' => 92,
32
- 'LQT_SUMMARY_TALK' => 93,
31
+ 'LQT_THREAD'.freeze => 90.freeze,
32
+ 'LQT_THREAD_TALK'.freeze => 91.freeze,
33
+ 'LQT_SUMMARY'.freeze => 92.freeze,
34
+ 'LQT_SUMMARY_TALK'.freeze => 93.freeze,
33
35
 
34
36
  # Extension:Semantic MediaWiki / Extension:Semantic Forms
35
- 'SMW_RELATION' => 100,
36
- 'SMW_RELATION_TALK' => 101,
37
- 'SMW_PROPERTY' => 102,
38
- 'SMW_PROPERTY_TALK' => 103,
39
- 'SMW_TYPE' => 104,
40
- 'SMW_TYPE_TALK' => 105,
41
- 'SMW_FORM' => 106,
42
- 'SMW_FORM_TALK' => 107,
43
- 'SF_CONCEPT' => 108,
44
- 'SF_CONCEPT_TALK' => 109,
37
+ 'SMW_RELATION'.freeze => 100.freeze,
38
+ 'SMW_RELATION_TALK'.freeze => 101.freeze,
39
+ 'SMW_PROPERTY'.freeze => 102.freeze,
40
+ 'SMW_PROPERTY_TALK'.freeze => 103.freeze,
41
+ 'SMW_TYPE'.freeze => 104.freeze,
42
+ 'SMW_TYPE_TALK'.freeze => 105.freeze,
43
+ 'SMW_FORM'.freeze => 106.freeze,
44
+ 'SMW_FORM_TALK'.freeze => 107.freeze,
45
+ 'SF_CONCEPT'.freeze => 108.freeze,
46
+ 'SF_CONCEPT_TALK'.freeze => 109.freeze,
45
47
 
46
48
  # Extension:DPLforum
47
- 'DPLF_FORUM' => 110,
48
- 'DPLF_FORUM_TAlK' => 111,
49
+ 'DPLF_FORUM'.freeze => 110.freeze,
50
+ 'DPLF_FORUM_TAlK'.freeze => 111.freeze,
49
51
 
50
52
  # Extension:RefHelper
51
- 'RFH_CITE' => 120,
52
- 'RFH_CITE_TALK' => 121,
53
+ 'RFH_CITE'.freeze => 120.freeze,
54
+ 'RFH_CITE_TALK'.freeze => 121.freeze,
53
55
 
54
56
  # Extension:SemanticAccessControl
55
- 'ACL_USERGROUP' => 160,
56
- 'ACL_ACL' => 162,
57
+ 'ACL_USERGROUP'.freeze => 160.freeze,
58
+ 'ACL_ACL'.freeze => 162.freeze,
57
59
 
58
60
  # Extension:Semantic Drilldown
59
- 'SED_FILTER' => 170,
60
- 'SED_FILTER_TALK' => 171,
61
+ 'SED_FILTER'.freeze => 170.freeze,
62
+ 'SED_FILTER_TALK'.freeze => 171.freeze,
61
63
 
62
64
  # Extension:SocialProfile
63
- 'SCP_USERWIKI' => 200,
64
- 'SCP_USERWIKI_TALK' => 201,
65
- 'SCP_USERPROFILE' => 202,
66
- 'SCP_USERPROFILE_TALK' => 203,
65
+ 'SCP_USERWIKI'.freeze => 200.freeze,
66
+ 'SCP_USERWIKI_TALK'.freeze => 201.freeze,
67
+ 'SCP_USERPROFILE'.freeze => 202.freeze,
68
+ 'SCP_USERPROFILE_TALK'.freeze => 203.freeze,
67
69
 
68
70
  # Extension:Proofread Page
69
- 'PRP_PAGE' => 250,
70
- 'PRP_PAGE_TALK' => 251,
71
- 'PRP_INDEX' => 252,
72
- 'PRP_INDEX_TALK' => 253,
71
+ 'PRP_PAGE'.freeze => 250.freeze,
72
+ 'PRP_PAGE_TALK'.freeze => 251.freeze,
73
+ 'PRP_INDEX'.freeze => 252.freeze,
74
+ 'PRP_INDEX_TALK'.freeze => 253.freeze,
73
75
 
74
76
  # Extension:TrustedMath
75
- 'TRM_MATH' => 262,
76
- 'TRM_MATH_TALK' => 263,
77
+ 'TRM_MATH'.freeze => 262.freeze,
78
+ 'TRM_MATH_TALK'.freeze => 263.freeze,
77
79
 
78
80
  # Extension:Widgets
79
- 'WID_WIDGET' => 274,
80
- 'WID_WIDGET_TALK' => 275,
81
+ 'WID_WIDGET'.freeze => 274.freeze,
82
+ 'WID_WIDGET_TALK'.freeze => 275.freeze,
81
83
 
82
84
  # Extension:EmbedScript
83
- 'EMS_JSAPPLET' => 280,
84
- 'EMS_JSAPPLET_TALK' => 281,
85
+ 'EMS_JSAPPLET'.freeze => 280.freeze,
86
+ 'EMS_JSAPPLET_TALK'.freeze => 281.freeze,
85
87
 
86
88
  # Extension:PollNY
87
- 'PLN_POLL' => 300,
88
- 'PLN_POLL_TALK' => 301,
89
+ 'PLN_POLL'.freeze => 300.freeze,
90
+ 'PLN_POLL_TALK'.freeze => 301.freeze,
89
91
 
90
92
  # Extension:Semantic Image Annotator
91
- 'SIA_IMAGE_ANNOTATOR' => 380,
93
+ 'SIA_IMAGE_ANNOTATOR'.freeze => 380.freeze,
92
94
 
93
95
  # Extension:Wiki2LaTeX
94
- 'WTL_WIKI2LATEX' => 400,
95
- 'WTL_WIKI2LATEX_TALK' => 401,
96
+ 'WTL_WIKI2LATEX'.freeze => 400.freeze,
97
+ 'WTL_WIKI2LATEX_TALK'.freeze => 401.freeze,
96
98
 
97
99
  # Extension:Workflow
98
- 'WRF_WORKFLOW' => 410,
99
- 'WRF_WORKFLOW_TALK' => 411,
100
+ 'WRF_WORKFLOW'.freeze => 410.freeze,
101
+ 'WRF_WORKFLOW_TALK'.freeze => 411.freeze,
100
102
 
101
103
  # Extension:Maps
102
- 'MAP_LAYER' => 420,
103
- 'MAP_LAYER_TALK' => 421,
104
+ 'MAP_LAYER'.freeze => 420.freeze,
105
+ 'MAP_LAYER_TALK'.freeze => 421.freeze,
104
106
 
105
107
  # Extension:QuizTabulate
106
- 'QTB_QUIZ' => 430,
107
- 'QTB_QUIZ_TALK' => 431,
108
+ 'QTB_QUIZ'.freeze => 430.freeze,
109
+ 'QTB_QUIZ_TALK'.freeze => 431.freeze,
108
110
 
109
111
  # Extension:Education Program
110
- 'EDP_EDUCATION_PROGRAM' => 446,
111
- 'EDP_EDUCATION_PROGRAM_TALK' => 447,
112
+ 'EDP_EDUCATION_PROGRAM'.freeze => 446.freeze,
113
+ 'EDP_EDUCATION_PROGRAM_TALK'.freeze => 447.freeze,
112
114
 
113
115
  # Extension:BoilerRoom
114
- 'BLR_BOILERPLATE' => 450,
115
- 'BLR_BOILERPLATE_TALK' => 451,
116
+ 'BLR_BOILERPLATE'.freeze => 450.freeze,
117
+ 'BLR_BOILERPLATE_TALK'.freeze => 451.freeze,
116
118
 
117
119
  # Extension:UploadWizard
118
- 'UPW_CAMPAIGN' => 460,
119
- 'UPW_CAMPAIGN_TALK' => 461,
120
+ 'UPW_CAMPAIGN'.freeze => 460.freeze,
121
+ 'UPW_CAMPAIGN_TALK'.freeze => 461.freeze,
120
122
 
121
123
  # Extension:EventLogging
122
- 'ELG_SCHEMA' => 470,
123
- 'ELG_SCHEMA_TALK' => 471,
124
+ 'ELG_SCHEMA'.freeze => 470.freeze,
125
+ 'ELG_SCHEMA_TALK'.freeze => 471.freeze,
124
126
 
125
127
  # Extension:ZeroBanner
126
- 'ZRB_ZERO' => 480,
127
- 'ZRB_ZERO_TALK' => 481,
128
+ 'ZRB_ZERO'.freeze => 480.freeze,
129
+ 'ZRB_ZERO_TALK'.freeze => 481.freeze,
128
130
 
129
131
  # Extension:JsonConfig
130
- 'JSC_CONFIG' => 482,
131
- 'JSC_CONFIG_TALK' => 483,
132
- 'JSC_DATA' => 486,
133
- 'JSC_DATA_TALK' => 487,
132
+ 'JSC_CONFIG'.freeze => 482.freeze,
133
+ 'JSC_CONFIG_TALK'.freeze => 483.freeze,
134
+ 'JSC_DATA'.freeze => 486.freeze,
135
+ 'JSC_DATA_TALK'.freeze => 487.freeze,
134
136
 
135
137
  # Extension:Graph
136
- 'GRP_GRAPH' => 484,
137
- 'GRP_GRAPH_TALK' => 485,
138
+ 'GRP_GRAPH'.freeze => 484.freeze,
139
+ 'GRP_GRAPH_TALK'.freeze => 485.freeze,
138
140
 
139
141
  # Extension:OpenStackManager
140
- 'OSM_NOVA_RESOURCE' => 488,
141
- 'OSM_NOVA_RESOURCE_TALK' => 489,
142
+ 'OSM_NOVA_RESOURCE'.freeze => 488.freeze,
143
+ 'OSM_NOVA_RESOURCE_TALK'.freeze => 489.freeze,
142
144
 
143
145
  # Extension:GWToolset
144
- 'GWT_GWTOOLSET' => 490,
145
- 'GWT_GWTOOLSET_TALK' => 491,
146
+ 'GWT_GWTOOLSET'.freeze => 490.freeze,
147
+ 'GWT_GWTOOLSET_TALK'.freeze => 491.freeze,
146
148
 
147
149
  # Extension:BlogPage
148
- 'BLP_BLOG' => 500,
149
- 'BLP_BLOG_TALK' => 501,
150
+ 'BLP_BLOG'.freeze => 500.freeze,
151
+ 'BLP_BLOG_TALK'.freeze => 501.freeze,
150
152
 
151
153
  # Extension:XMLContentExtension
152
- 'XCE_XML' => 580,
153
- 'XCE_XML_TALK' => 581,
154
- 'XCE_SCHEMA' => 582,
155
- 'XCE_SCHEMA_TALK' => 583,
154
+ 'XCE_XML'.freeze => 580.freeze,
155
+ 'XCE_XML_TALK'.freeze => 581.freeze,
156
+ 'XCE_SCHEMA'.freeze => 582.freeze,
157
+ 'XCE_SCHEMA_TALK'.freeze => 583.freeze,
156
158
 
157
159
  # Extension:FanBoxes
158
- 'FNB_USERBOX' => 600,
159
- 'FNB_USERBOX_TALK' => 601,
160
+ 'FNB_USERBOX'.freeze => 600.freeze,
161
+ 'FNB_USERBOX_TALK'.freeze => 601.freeze,
160
162
 
161
163
  # Extension:LinkFilter
162
- 'LFT_LINK' => 700,
163
- 'LFT_LINK_TALK' => 701,
164
+ 'LFT_LINK'.freeze => 700.freeze,
165
+ 'LFT_LINK_TALK'.freeze => 701.freeze,
164
166
 
165
167
  # Extension:TimedMediaHandler
166
- 'TMH_TIMEDTEXT' => 710,
167
- 'TMH_TIMEDTEXT_TALK' => 711,
168
+ 'TMH_TIMEDTEXT'.freeze => 710.freeze,
169
+ 'TMH_TIMEDTEXT_TALK'.freeze => 711.freeze,
168
170
 
169
171
  # Extension:QPoll
170
- 'QPL_INTERPRETATION' => 800,
171
- 'QPL_INTERPRETATION_TALK' => 801,
172
+ 'QPL_INTERPRETATION'.freeze => 800.freeze,
173
+ 'QPL_INTERPRETATION_TALK'.freeze => 801.freeze,
172
174
 
173
- # Extension:SemanticMustacheFormat :3,
174
- 'SMF_MUSTACHE' => 806,
175
- 'SMF_MUSTACHE_TALK' => 807,
175
+ # Extension:SemanticMustacheFormat :3
176
+ 'SMF_MUSTACHE'.freeze => 806.freeze,
177
+ 'SMF_MUSTACHE_TALK'.freeze => 807.freeze,
176
178
 
177
179
  # Extension:R
178
- 'R_R' => 814,
179
- 'R_R_TALK' => 815,
180
+ 'R_R'.freeze => 814.freeze,
181
+ 'R_R_TALK'.freeze => 815.freeze,
180
182
 
181
183
  # Extension:Scribunto
182
- 'SCR_MODULE' => 828,
183
- 'SCR_MODULE_TALK' => 829,
184
+ 'SCR_MODULE'.freeze => 828.freeze,
185
+ 'SCR_MODULE_TALK'.freeze => 829.freeze,
184
186
 
185
187
  # Extension:SecurePoll
186
- 'SEP_SECUREPOLL' => 830,
187
- 'SEP_SECUREPOLL_TALK' => 831,
188
+ 'SEP_SECUREPOLL'.freeze => 830.freeze,
189
+ 'SEP_SECUREPOLL_TALK'.freeze => 831.freeze,
188
190
 
189
191
  # Extension:CentralNotice
190
- 'CNT_CNBANNER' => 866,
191
- 'CNT_CNBANNER_TALK' => 867,
192
+ 'CNT_CNBANNER'.freeze => 866.freeze,
193
+ 'CNT_CNBANNER_TALK'.freeze => 867.freeze,
192
194
 
193
195
  # Extension:Translate
194
- 'TRN_TRANSLATIONS' => 1198,
195
- 'TRN_TRANSLATIOTALK' => 1199,
196
+ 'TRN_TRANSLATIONS'.freeze => 1198.freeze,
197
+ 'TRN_TRANSLATIOTALK'.freeze => 1199.freeze,
196
198
 
197
199
  # Extension:PackageForce
198
- 'PKF_PACKAGEFORCE' => 1300,
199
- 'PKF_PACKAGEFORCE_TALK' => 1301,
200
+ 'PKF_PACKAGEFORCE'.freeze => 1300.freeze,
201
+ 'PKF_PACKAGEFORCE_TALK'.freeze => 1301.freeze,
200
202
 
201
203
  # Extension:BlueSpice
202
- 'BLS_BLOG' => 1502,
203
- 'BLS_BLOG_TALK' => 1503,
204
- 'BLS_BOOK' => 1504,
205
- 'BLS_BOOK_TALK' => 1505,
204
+ 'BLS_BLOG'.freeze => 1502.freeze,
205
+ 'BLS_BLOG_TALK'.freeze => 1503.freeze,
206
+ 'BLS_BOOK'.freeze => 1504.freeze,
207
+ 'BLS_BOOK_TALK'.freeze => 1505.freeze,
206
208
 
207
209
  # Extension:Gadgets
208
- 'GDG_GADGET' => 2300,
209
- 'GDG_GADGET_TALK' => 2301,
210
- 'GDG_GADGET_DEFININTION' => 2302,
211
- 'GDG_GADGET_DEFININTION_TALK' => 2303,
210
+ 'GDG_GADGET'.freeze => 2300.freeze,
211
+ 'GDG_GADGET_TALK'.freeze => 2301.freeze,
212
+ 'GDG_GADGET_DEFININTION'.freeze => 2302.freeze,
213
+ 'GDG_GADGET_DEFININTION_TALK'.freeze => 2303.freeze,
212
214
 
213
215
  # Extension:VisualEditor
214
- 'VSE_VISUALEDITOR' => 2500,
215
- 'VSE_VISUALEDITOR_TALK' => 2501,
216
+ 'VSE_VISUALEDITOR'.freeze => 2500.freeze,
217
+ 'VSE_VISUALEDITOR_TALK'.freeze => 2501.freeze,
216
218
 
217
219
  # Extension:Flow
218
- 'FLW_TOPIC' => 2600
219
- }
220
+ 'FLW_TOPIC'.freeze => 2600.freeze
221
+ }.freeze
220
222
 
221
- # This is the most common time format that MediaWiki uses.
222
- TIME_FORMAT = '%Y-%m-%dT%H:%M:%SZ'
223
+ # @return [String] MediaWiki's timestamp format as an immutable string for DateTime uses.
224
+ TIME_FORMAT = '%Y-%m-%dT%H:%M:%SZ'.freeze
223
225
  end
224
226
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: mediawiki-butt
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.10.1
4
+ version: 0.10.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Eli Foster
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2016-01-02 00:00:00.000000000 Z
12
+ date: 2016-01-23 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: httpclient
@@ -17,17 +17,17 @@ dependencies:
17
17
  requirements:
18
18
  - - ">="
19
19
  - !ruby/object:Gem::Version
20
- version: 2.6.0.1
20
+ version: 2.7.1
21
21
  type: :runtime
22
22
  prerelease: false
23
23
  version_requirements: !ruby/object:Gem::Requirement
24
24
  requirements:
25
25
  - - ">="
26
26
  - !ruby/object:Gem::Version
27
- version: 2.6.0.1
28
- description: |2+
29
- MediaWiki::Butt provides a fully-featured interface to the MediaWiki API. It includes methods for changing wiki content, authentication, and queries.
30
-
27
+ version: 2.7.1
28
+ description: " MediaWiki::Butt provides a fully-featured interface to the MediaWiki
29
+ API. It includes methods for changing wiki content, authentication, and
30
+ queries.\n\n"
31
31
  email: elifosterwy@gmail.com
32
32
  executables: []
33
33
  extensions: []
@@ -91,9 +91,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
91
91
  version: '0'
92
92
  requirements: []
93
93
  rubyforge_project:
94
- rubygems_version: 2.4.5.1
94
+ rubygems_version: 2.5.1
95
95
  signing_key:
96
96
  specification_version: 4
97
97
  summary: Interacting with the MediaWiki API
98
98
  test_files: []
99
- has_rdoc: