Merge lp://qastaging/~jejones/do-plugins/pastebin-fix into lp://qastaging/do-plugins
- pastebin-fix
- Merge into trunk
Proposed by
Jason Jones
Status: | Merged |
---|---|
Approved by: | Alex Launi |
Approved revision: | not available |
Merged at revision: | not available |
Proposed branch: | lp://qastaging/~jejones/do-plugins/pastebin-fix |
Merge into: | lp://qastaging/do-plugins |
Diff against target: |
480 lines (+4/-409) 6 files modified
Pastebin/Makefile.am (+1/-3) Pastebin/Pastebin.mdp (+1/-3) Pastebin/Resources/Monoport.xml (+0/-315) Pastebin/src/Providers/LodgeIt.cs (+1/-0) Pastebin/src/Providers/Monoport.cs (+0/-88) Pastebin/src/Providers/Paste2.cs (+1/-0) |
To merge this branch: | bzr merge lp://qastaging/~jejones/do-plugins/pastebin-fix |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Alex Launi (community) | Approve | ||
Review via email:
|
Commit message
Description of the change
To post a comment you must log in.
Revision history for this message
![](/+icing/build/overlay/assets/skins/sam/images/close.gif)
Jason Jones (jejones) wrote : | # |
Preview Diff
[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1 | === modified file 'Pastebin/Makefile.am' |
2 | --- Pastebin/Makefile.am 2009-06-22 04:05:16 +0000 |
3 | +++ Pastebin/Makefile.am 2010-01-24 19:51:16 +0000 |
4 | @@ -11,7 +11,6 @@ |
5 | src/Providers/IPastebinProvider.cs \ |
6 | src/Providers/AbstractPastebinProvider.cs \ |
7 | src/Providers/LodgeIt.cs \ |
8 | - src/Providers/Monoport.cs \ |
9 | src/Providers/Paste2.cs \ |
10 | src/Providers/PastebinCA.cs \ |
11 | src/Providers/PastebinProviderFactory.cs \ |
12 | @@ -24,8 +23,7 @@ |
13 | Resources/Pastebin.addin.xml \ |
14 | Resources/LodgeIt.xml \ |
15 | Resources/Paste2.xml \ |
16 | - Resources/PastebinCA.xml \ |
17 | - Resources/Monoport.xml |
18 | + Resources/PastebinCA.xml |
19 | |
20 | REFERENCES = \ |
21 | System \ |
22 | |
23 | === modified file 'Pastebin/Pastebin.mdp' |
24 | --- Pastebin/Pastebin.mdp 2009-06-23 00:52:54 +0000 |
25 | +++ Pastebin/Pastebin.mdp 2010-01-24 19:51:16 +0000 |
26 | @@ -33,10 +33,8 @@ |
27 | <File name="src/TextSyntax/TextSyntaxItem.cs" subtype="Code" buildaction="Compile" /> |
28 | <File name="src/Providers/LodgeIt.cs" subtype="Code" buildaction="Compile" /> |
29 | <File name="Resources/Pastebin.addin.xml" subtype="Code" buildaction="EmbedAsResource" /> |
30 | - <File name="src/Providers/Monoport.cs" subtype="Code" buildaction="Compile" /> |
31 | <File name="src/Providers/AbstractPastebinProvider.cs" subtype="Code" buildaction="Compile" /> |
32 | <File name="Resources/LodgeIt.xml" subtype="Code" buildaction="EmbedAsResource" /> |
33 | - <File name="Resources/Monoport.xml" subtype="Code" buildaction="EmbedAsResource" /> |
34 | <File name="Resources/Paste2.xml" subtype="Code" buildaction="EmbedAsResource" /> |
35 | <File name="Resources/PastebinCA.xml" subtype="Code" buildaction="EmbedAsResource" /> |
36 | </Contents> |
37 | @@ -53,4 +51,4 @@ |
38 | <ProjectReference type="Gac" localcopy="True" refto="Do.Platform, Version=0.9.0.0, Culture=neutral" /> |
39 | </References> |
40 | <GtkDesignInfo gettextClass="Mono.Addins.AddinManager.CurrentLocalizer" /> |
41 | -</Project> |
42 | \ No newline at end of file |
43 | +</Project> |
44 | |
45 | === removed file 'Pastebin/Resources/Monoport.xml' |
46 | --- Pastebin/Resources/Monoport.xml 2009-01-23 05:47:18 +0000 |
47 | +++ Pastebin/Resources/Monoport.xml 1970-01-01 00:00:00 +0000 |
48 | @@ -1,315 +0,0 @@ |
49 | -<?xml version="1.0" encoding="utf-8"?> |
50 | -<ArrayOfTextSyntaxItem xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema"> |
51 | - <TextSyntaxItem> |
52 | - <SerializableName>ASM</SerializableName> |
53 | - <SerializableDescription>ASM (NASM based)</SerializableDescription> |
54 | - <SerializableIcon>text-x-generic</SerializableIcon> |
55 | - <Syntax>ASM</Syntax> |
56 | - </TextSyntaxItem> |
57 | - <TextSyntaxItem> |
58 | - <SerializableName>ASP</SerializableName> |
59 | - <SerializableDescription>ASP</SerializableDescription> |
60 | - <SerializableIcon>text-x-generic</SerializableIcon> |
61 | - <Syntax>asp</Syntax> |
62 | - </TextSyntaxItem> |
63 | - <TextSyntaxItem> |
64 | - <SerializableName>ActionScript</SerializableName> |
65 | - <SerializableDescription>ActionScript</SerializableDescription> |
66 | - <SerializableIcon>text-x-generic</SerializableIcon> |
67 | - <Syntax>actionscript</Syntax> |
68 | - </TextSyntaxItem> |
69 | - <TextSyntaxItem> |
70 | - <SerializableName>Ada</SerializableName> |
71 | - <SerializableDescription>Ada</SerializableDescription> |
72 | - <SerializableIcon>text-x-generic</SerializableIcon> |
73 | - <Syntax>ada</Syntax> |
74 | - </TextSyntaxItem> |
75 | - <TextSyntaxItem> |
76 | - <SerializableName>Apache Log</SerializableName> |
77 | - <SerializableDescription>Apache Log</SerializableDescription> |
78 | - <SerializableIcon>text-x-generic</SerializableIcon> |
79 | - <Syntax>apache</Syntax> |
80 | - </TextSyntaxItem> |
81 | - <TextSyntaxItem> |
82 | - <SerializableName>AppleScript</SerializableName> |
83 | - <SerializableDescription>AppleScript</SerializableDescription> |
84 | - <SerializableIcon>text-x-generic</SerializableIcon> |
85 | - <Syntax>applescript</Syntax> |
86 | - </TextSyntaxItem> |
87 | - <TextSyntaxItem> |
88 | - <SerializableName>Bash</SerializableName> |
89 | - <SerializableDescription>Bash</SerializableDescription> |
90 | - <SerializableIcon>text-x-generic</SerializableIcon> |
91 | - <Syntax>bash</Syntax> |
92 | - </TextSyntaxItem> |
93 | - <TextSyntaxItem> |
94 | - <SerializableName>C for Macs</SerializableName> |
95 | - <SerializableDescription>C for Macs</SerializableDescription> |
96 | - <SerializableIcon>text-x-generic</SerializableIcon> |
97 | - <Syntax>c_mac</Syntax> |
98 | - </TextSyntaxItem> |
99 | - <TextSyntaxItem> |
100 | - <SerializableName>C</SerializableName> |
101 | - <SerializableDescription>C</SerializableDescription> |
102 | - <SerializableIcon>text-x-generic</SerializableIcon> |
103 | - <Syntax>c</Syntax> |
104 | - </TextSyntaxItem> |
105 | - <TextSyntaxItem> |
106 | - <SerializableName>C</SerializableName> |
107 | - <SerializableDescription>C</SerializableDescription> |
108 | - <SerializableIcon>text-x-generic</SerializableIcon> |
109 | - <Syntax>c</Syntax> |
110 | - </TextSyntaxItem> |
111 | - <TextSyntaxItem> |
112 | - <SerializableName>C#</SerializableName> |
113 | - <SerializableDescription>C#</SerializableDescription> |
114 | - <SerializableIcon>text-x-generic</SerializableIcon> |
115 | - <Syntax>csharp</Syntax> |
116 | - </TextSyntaxItem> |
117 | - <TextSyntaxItem> |
118 | - <SerializableName>C++</SerializableName> |
119 | - <SerializableDescription>C++</SerializableDescription> |
120 | - <SerializableIcon>text-x-generic</SerializableIcon> |
121 | - <Syntax>cpp</Syntax> |
122 | - </TextSyntaxItem> |
123 | - <TextSyntaxItem> |
124 | - <SerializableName>CAD DCL</SerializableName> |
125 | - <SerializableDescription>CAD DCL</SerializableDescription> |
126 | - <SerializableIcon>text-x-generic</SerializableIcon> |
127 | - <Syntax>caddcl</Syntax> |
128 | - </TextSyntaxItem> |
129 | - <TextSyntaxItem> |
130 | - <SerializableName>CAD Lisp</SerializableName> |
131 | - <SerializableDescription>CAD Lisp</SerializableDescription> |
132 | - <SerializableIcon>text-x-generic</SerializableIcon> |
133 | - <Syntax>cadlisp</Syntax> |
134 | - </TextSyntaxItem> |
135 | - <TextSyntaxItem> |
136 | - <SerializableName>CSS</SerializableName> |
137 | - <SerializableDescription>CSS</SerializableDescription> |
138 | - <SerializableIcon>text-x-generic</SerializableIcon> |
139 | - <Syntax>css</Syntax> |
140 | - </TextSyntaxItem> |
141 | - <TextSyntaxItem> |
142 | - <SerializableName>ColdFusion</SerializableName> |
143 | - <SerializableDescription>ColdFusion</SerializableDescription> |
144 | - <SerializableIcon>text-x-generic</SerializableIcon> |
145 | - <Syntax>cfm</Syntax> |
146 | - </TextSyntaxItem> |
147 | - <TextSyntaxItem> |
148 | - <SerializableName>D</SerializableName> |
149 | - <SerializableDescription>D</SerializableDescription> |
150 | - <SerializableIcon>text-x-generic</SerializableIcon> |
151 | - <Syntax>d</Syntax> |
152 | - </TextSyntaxItem> |
153 | - <TextSyntaxItem> |
154 | - <SerializableName>DOS</SerializableName> |
155 | - <SerializableDescription>DOS</SerializableDescription> |
156 | - <SerializableIcon>text-x-generic</SerializableIcon> |
157 | - <Syntax>dos</Syntax> |
158 | - </TextSyntaxItem> |
159 | - <TextSyntaxItem> |
160 | - <SerializableName>Delphi</SerializableName> |
161 | - <SerializableDescription>Delphia</SerializableDescription> |
162 | - <SerializableIcon>text-x-generic</SerializableIcon> |
163 | - <Syntax>delphi</Syntax> |
164 | - </TextSyntaxItem> |
165 | - <TextSyntaxItem> |
166 | - <SerializableName>Diff</SerializableName> |
167 | - <SerializableDescription>Diff</SerializableDescription> |
168 | - <SerializableIcon>text-x-generic</SerializableIcon> |
169 | - <Syntax>diff</Syntax> |
170 | - </TextSyntaxItem> |
171 | - <TextSyntaxItem> |
172 | - <SerializableName>Eiffel</SerializableName> |
173 | - <SerializableDescription>Eiffel</SerializableDescription> |
174 | - <SerializableIcon>text-x-generic</SerializableIcon> |
175 | - <Syntax>eiffel</Syntax> |
176 | - </TextSyntaxItem> |
177 | - <TextSyntaxItem> |
178 | - <SerializableName>Fortran</SerializableName> |
179 | - <SerializableDescription>Fortrain</SerializableDescription> |
180 | - <SerializableIcon>text-x-generic</SerializableIcon> |
181 | - <Syntax>fortran</Syntax> |
182 | - </TextSyntaxItem> |
183 | - <TextSyntaxItem> |
184 | - <SerializableName>FreeBasic</SerializableName> |
185 | - <SerializableDescription>FreeBasic</SerializableDescription> |
186 | - <SerializableIcon>text-x-generic</SerializableIcon> |
187 | - <Syntax>freebasic</Syntax> |
188 | - </TextSyntaxItem> |
189 | - <TextSyntaxItem> |
190 | - <SerializableName>Game Maker</SerializableName> |
191 | - <SerializableDescription>Game Maker</SerializableDescription> |
192 | - <SerializableIcon>text-x-generic</SerializableIcon> |
193 | - <Syntax>gml</Syntax> |
194 | - </TextSyntaxItem> |
195 | - <TextSyntaxItem> |
196 | - <SerializableName>HTML 4</SerializableName> |
197 | - <SerializableDescription>HTML 4 Strict</SerializableDescription> |
198 | - <SerializableIcon>text-x-generic</SerializableIcon> |
199 | - <Syntax>html4strict</Syntax> |
200 | - </TextSyntaxItem> |
201 | - <TextSyntaxItem> |
202 | - <SerializableName>Java</SerializableName> |
203 | - <SerializableDescription>Java</SerializableDescription> |
204 | - <SerializableIcon>text-x-generic</SerializableIcon> |
205 | - <Syntax>java</Syntax> |
206 | - </TextSyntaxItem> |
207 | - <TextSyntaxItem> |
208 | - <SerializableName>Javascript</SerializableName> |
209 | - <SerializableDescription>JavaScript</SerializableDescription> |
210 | - <SerializableIcon>text-x-generic</SerializableIcon> |
211 | - <Syntax>javascript</Syntax> |
212 | - </TextSyntaxItem> |
213 | - <TextSyntaxItem> |
214 | - <SerializableName>Lua</SerializableName> |
215 | - <SerializableDescription>Lua</SerializableDescription> |
216 | - <SerializableIcon>text-x-generic</SerializableIcon> |
217 | - <Syntax>lua</Syntax> |
218 | - </TextSyntaxItem> |
219 | - <TextSyntaxItem> |
220 | - <SerializableName>MPASM</SerializableName> |
221 | - <SerializableDescription>MPASM</SerializableDescription> |
222 | - <SerializableIcon>text-x-generic</SerializableIcon> |
223 | - <Syntax>mpasm</Syntax> |
224 | - </TextSyntaxItem> |
225 | - <TextSyntaxItem> |
226 | - <SerializableName>Matlab</SerializableName> |
227 | - <SerializableDescription>Matlab</SerializableDescription> |
228 | - <SerializableIcon>text-x-generic</SerializableIcon> |
229 | - <Syntax>matlab</Syntax> |
230 | - </TextSyntaxItem> |
231 | - <TextSyntaxItem> |
232 | - <SerializableName>MySQL</SerializableName> |
233 | - <SerializableDescription>MySQL</SerializableDescription> |
234 | - <SerializableIcon>text-x-generic</SerializableIcon> |
235 | - <Syntax>mysql</Syntax> |
236 | - </TextSyntaxItem> |
237 | - <TextSyntaxItem> |
238 | - <SerializableName>NullSoft Installer</SerializableName> |
239 | - <SerializableDescription>NullSoft Installer</SerializableDescription> |
240 | - <SerializableIcon>text-x-generic</SerializableIcon> |
241 | - <Syntax>nsis</Syntax> |
242 | - </TextSyntaxItem> |
243 | - <TextSyntaxItem> |
244 | - <SerializableName>OCaml</SerializableName> |
245 | - <SerializableDescription>OCaml</SerializableDescription> |
246 | - <SerializableIcon>text-x-generic</SerializableIcon> |
247 | - <Syntax>ocaml</Syntax> |
248 | - </TextSyntaxItem> |
249 | - <TextSyntaxItem> |
250 | - <SerializableName>Objective-C</SerializableName> |
251 | - <SerializableDescription>Objective-C</SerializableDescription> |
252 | - <SerializableIcon>text-x-generic</SerializableIcon> |
253 | - <Syntax>cobjc</Syntax> |
254 | - </TextSyntaxItem> |
255 | - <TextSyntaxItem> |
256 | - <SerializableName>OpenOffice.org BASIC</SerializableName> |
257 | - <SerializableDescription>OpenOffice.org BASIC</SerializableDescription> |
258 | - <SerializableIcon>text-x-generic</SerializableIcon> |
259 | - <Syntax>oobas</Syntax> |
260 | - </TextSyntaxItem> |
261 | - <TextSyntaxItem> |
262 | - <SerializableName>Oracle 8</SerializableName> |
263 | - <SerializableDescription>Oracle 8</SerializableDescription> |
264 | - <SerializableIcon>text-x-generic</SerializableIcon> |
265 | - <Syntax>oracle8</Syntax> |
266 | - </TextSyntaxItem> |
267 | - <TextSyntaxItem> |
268 | - <SerializableName>PHP</SerializableName> |
269 | - <SerializableDescription>PHP</SerializableDescription> |
270 | - <SerializableIcon>text-x-generic</SerializableIcon> |
271 | - <Syntax>php</Syntax> |
272 | - </TextSyntaxItem> |
273 | - <TextSyntaxItem> |
274 | - <SerializableName>Pascal</SerializableName> |
275 | - <SerializableDescription>Pascal</SerializableDescription> |
276 | - <SerializableIcon>text-x-generic</SerializableIcon> |
277 | - <Syntax>pascal</Syntax> |
278 | - </TextSyntaxItem> |
279 | - <TextSyntaxItem> |
280 | - <SerializableName>Perl</SerializableName> |
281 | - <SerializableDescription>Perl</SerializableDescription> |
282 | - <SerializableIcon>text-x-generic</SerializableIcon> |
283 | - <Syntax>perl</Syntax> |
284 | - </TextSyntaxItem> |
285 | - <TextSyntaxItem> |
286 | - <SerializableName>Plain Text</SerializableName> |
287 | - <SerializableDescription>Plain Text</SerializableDescription> |
288 | - <SerializableIcon>text-x-generic</SerializableIcon> |
289 | - <Syntax>text</Syntax> |
290 | - </TextSyntaxItem> |
291 | - <TextSyntaxItem> |
292 | - <SerializableName>Python</SerializableName> |
293 | - <SerializableDescription>Python</SerializableDescription> |
294 | - <SerializableIcon>text-x-generic</SerializableIcon> |
295 | - <Syntax>python</Syntax> |
296 | - </TextSyntaxItem> |
297 | - <TextSyntaxItem> |
298 | - <SerializableName>QuickBASIC</SerializableName> |
299 | - <SerializableDescription>QuickBASIC</SerializableDescription> |
300 | - <SerializableIcon>text-x-generic</SerializableIcon> |
301 | - <Syntax>qbasic</Syntax> |
302 | - </TextSyntaxItem> |
303 | - <TextSyntaxItem> |
304 | - <SerializableName>Robots</SerializableName> |
305 | - <SerializableDescription>Robots</SerializableDescription> |
306 | - <SerializableIcon>text-x-generic</SerializableIcon> |
307 | - <Syntax>robots</Syntax> |
308 | - </TextSyntaxItem> |
309 | - <TextSyntaxItem> |
310 | - <SerializableName>Ruby</SerializableName> |
311 | - <SerializableDescription>Ruby</SerializableDescription> |
312 | - <SerializableIcon>text-x-generic</SerializableIcon> |
313 | - <Syntax>ruby</Syntax> |
314 | - </TextSyntaxItem> |
315 | - <TextSyntaxItem> |
316 | - <SerializableName>SQL</SerializableName> |
317 | - <SerializableDescription>SQL</SerializableDescription> |
318 | - <SerializableIcon>text-x-generic</SerializableIcon> |
319 | - <Syntax>sql</Syntax> |
320 | - </TextSyntaxItem> |
321 | - <TextSyntaxItem> |
322 | - <SerializableName>Scheme</SerializableName> |
323 | - <SerializableDescription>Scheme</SerializableDescription> |
324 | - <SerializableIcon>text-x-generic</SerializableIcon> |
325 | - <Syntax>scheme</Syntax> |
326 | - </TextSyntaxItem> |
327 | - <TextSyntaxItem> |
328 | - <SerializableName>Smarrty</SerializableName> |
329 | - <SerializableDescription>Smarty</SerializableDescription> |
330 | - <SerializableIcon>text-x-generic</SerializableIcon> |
331 | - <Syntax>smarty</Syntax> |
332 | - </TextSyntaxItem> |
333 | - <TextSyntaxItem> |
334 | - <SerializableName>Tcl</SerializableName> |
335 | - <SerializableDescription>Tcl</SerializableDescription> |
336 | - <SerializableIcon>text-x-generic</SerializableIcon> |
337 | - <Syntax>tcl</Syntax> |
338 | - </TextSyntaxItem> |
339 | - <TextSyntaxItem> |
340 | - <SerializableName>VB.NET</SerializableName> |
341 | - <SerializableDescription>VB.NET</SerializableDescription> |
342 | - <SerializableIcon>text-x-generic</SerializableIcon> |
343 | - <Syntax>vbnet</Syntax> |
344 | - </TextSyntaxItem> |
345 | - <TextSyntaxItem> |
346 | - <SerializableName>VisualBasic</SerializableName> |
347 | - <SerializableDescription>VisualBasic</SerializableDescription> |
348 | - <SerializableIcon>text-x-generic</SerializableIcon> |
349 | - <Syntax>vb</Syntax> |
350 | - </TextSyntaxItem> |
351 | - <TextSyntaxItem> |
352 | - <SerializableName>VisualFoxPro</SerializableName> |
353 | - <SerializableDescription>VisualFoxPro</SerializableDescription> |
354 | - <SerializableIcon>text-x-generic</SerializableIcon> |
355 | - <Syntax>visualfoxpro</Syntax> |
356 | - </TextSyntaxItem> |
357 | - <TextSyntaxItem> |
358 | - <SerializableName>XML</SerializableName> |
359 | - <SerializableDescription>XML</SerializableDescription> |
360 | - <SerializableIcon>text-x-generic</SerializableIcon> |
361 | - <Syntax>xml</Syntax> |
362 | - </TextSyntaxItem> |
363 | -</ArrayOfTextSyntaxItem> |
364 | |
365 | === modified file 'Pastebin/src/Providers/LodgeIt.cs' |
366 | --- Pastebin/src/Providers/LodgeIt.cs 2009-06-22 04:05:16 +0000 |
367 | +++ Pastebin/src/Providers/LodgeIt.cs 2010-01-24 19:51:16 +0000 |
368 | @@ -41,6 +41,7 @@ |
369 | Name = "paste.pocoo.org"; |
370 | BaseUrl = url_root; |
371 | ShouldAllowAutoRedirect = false; |
372 | + Expect100Continue = false; |
373 | |
374 | Parameters[content_key] = ""; |
375 | Parameters[syntax_key] = "text"; |
376 | |
377 | === removed file 'Pastebin/src/Providers/Monoport.cs' |
378 | --- Pastebin/src/Providers/Monoport.cs 2009-01-23 05:47:18 +0000 |
379 | +++ Pastebin/src/Providers/Monoport.cs 1970-01-01 00:00:00 +0000 |
380 | @@ -1,88 +0,0 @@ |
381 | -/* Monoport.cs |
382 | - * |
383 | - * GNOME Do is the legal property of its developers. Please refer to the |
384 | - * COPYRIGHT file distributed with this |
385 | - * source distribution. |
386 | - * |
387 | - * This program is free software: you can redistribute it and/or modify |
388 | - * it under the terms of the GNU General Public License as published by |
389 | - * the Free Software Foundation, either version 3 of the License, or |
390 | - * (at your option) any later version. |
391 | - * |
392 | - * This program is distributed in the hope that it will be useful, |
393 | - * but WITHOUT ANY WARRANTY; without even the implied warranty of |
394 | - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
395 | - * GNU General Public License for more details. |
396 | - * |
397 | - * You should have received a copy of the GNU General Public License |
398 | - * along with this program. If not, see <http://www.gnu.org/licenses/>. |
399 | - */ |
400 | - |
401 | -using System; |
402 | -using System.Collections.Generic; |
403 | -using System.Collections.Specialized; |
404 | -using System.IO; |
405 | -using System.Net; |
406 | -using System.Text.RegularExpressions; |
407 | - |
408 | -using Do.Platform; |
409 | - |
410 | -namespace Pastebin |
411 | -{ |
412 | - public class Monoport : AbstractPastebinProvider |
413 | - { |
414 | - const string url_root = "http://monoport.com"; |
415 | - const string syntax_key = "format"; |
416 | - const string content_key = "code2"; |
417 | - |
418 | - public Monoport () |
419 | - { |
420 | - Name = "Monoport"; |
421 | - BaseUrl = url_root + "/pastebin.php"; |
422 | - |
423 | - Parameters = new NameValueCollection (); |
424 | - Parameters ["poster"] = System.Environment.UserName; |
425 | - Parameters [syntax_key] = "text"; |
426 | - Parameters ["parent_pid"] = ""; |
427 | - Parameters ["paste"] = "send"; |
428 | - Parameters ["expiry_day"] = "d"; |
429 | - Parameters [content_key] = ""; |
430 | - |
431 | - UserAgent = "monoporter"; |
432 | - |
433 | - SupportedLanguages = PopulateTextSyntaxItemsFromXml ("Monoport.xml"); |
434 | - } |
435 | - |
436 | - public Monoport (string content) : this () |
437 | - { |
438 | - Parameters [content_key] = content; |
439 | - } |
440 | - |
441 | - public Monoport (string content, string syntax) : this () |
442 | - { |
443 | - Parameters [syntax_key] = syntax; |
444 | - Parameters [content_key] = content; |
445 | - } |
446 | - |
447 | - public override string GetPasteUrlFromResponse (HttpWebResponse response) |
448 | - { |
449 | - string responseText; |
450 | - using (Stream responseStream = response.GetResponseStream ()) { |
451 | - using (StreamReader reader = new StreamReader (responseStream)) { |
452 | - responseText = reader.ReadToEnd (); |
453 | - } |
454 | - } |
455 | - |
456 | - Regex urlPattern = new Regex ("<a href=\"\\/pastebin\\.php\\?dl=[0-9]*"); |
457 | - Match urlMatch = urlPattern.Match (responseText); |
458 | - string url = urlMatch.Value; |
459 | - |
460 | - if (url == string.Empty) { |
461 | - Log<Monoport>.Debug (responseText); |
462 | - throw new Exception ("Parsed url was empty. Monoport may have changed their format."); |
463 | - } |
464 | - |
465 | - return url_root + "/" + url.Substring (url.LastIndexOf ('=') + 1); |
466 | - } |
467 | - } |
468 | -} |
469 | |
470 | === modified file 'Pastebin/src/Providers/Paste2.cs' |
471 | --- Pastebin/src/Providers/Paste2.cs 2009-01-23 05:47:18 +0000 |
472 | +++ Pastebin/src/Providers/Paste2.cs 2010-01-24 19:51:16 +0000 |
473 | @@ -37,6 +37,7 @@ |
474 | BaseUrl = url_root + "/new-paste"; |
475 | |
476 | ShouldAllowAutoRedirect = false; |
477 | + Expect100Continue = false; |
478 | |
479 | Parameters[syntax_key] = "text"; |
480 | Parameters["description"] = ""; |
Branch updates my Pastebin plugin, fixing the LodgeIt and Paste2 providers and removing the Monoport provider.