Merge lp:~lig/gwibber/slkiru into lp:gwibber

Proposed by Serge Matveenko
Status: Rejected
Rejected by: Ken VanDine
Proposed branch: lp:~lig/gwibber/slkiru
Merge into: lp:gwibber
Diff against target: 46 lines
2 files modified
gwibber/urlshorter/__init__.py (+2/-0)
gwibber/urlshorter/slkiru.py (+24/-0)
To merge this branch: bzr merge lp:~lig/gwibber/slkiru
Reviewer Review Type Date Requested Status
Ken VanDine Disapprove
Review via email: mp+13812@code.launchpad.net
To post a comment you must log in.
Revision history for this message
Serge Matveenko (lig) wrote :

Support for slki.ru url shortener service added (resubmit)

Revision history for this message
Ken VanDine (ken-vandine) wrote :

Sorry this took so long to get reviewed, this no longer applies to trunk.

Thanks for your submission.

review: Disapprove

Unmerged revisions

466. By Serge Matveenko

Add slki.ru url shortener support

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file 'gwibber/urlshorter/__init__.py'
--- gwibber/urlshorter/__init__.py 2009-04-15 22:56:03 +0000
+++ gwibber/urlshorter/__init__.py 2009-10-22 23:00:33 +0000
@@ -1,6 +1,7 @@
11
2import cligs, isgd, tinyurlcom, trim, ur1ca2import cligs, isgd, tinyurlcom, trim, ur1ca
3#import snipurlcom, zima3#import snipurlcom, zima
4import slkiru
45
5PROTOCOLS = {6PROTOCOLS = {
6 "cli.gs": cligs,7 "cli.gs": cligs,
@@ -10,4 +11,5 @@
10 "tr.im": trim,11 "tr.im": trim,
11 "ur1.ca": ur1ca,12 "ur1.ca": ur1ca,
12 #"zi.ma": zima,13 #"zi.ma": zima,
14 "slki.ru": slkiru,
13}15}
1416
=== added file 'gwibber/urlshorter/slkiru.py'
--- gwibber/urlshorter/slkiru.py 1970-01-01 00:00:00 +0000
+++ gwibber/urlshorter/slkiru.py 2009-10-22 23:00:33 +0000
@@ -0,0 +1,24 @@
1
2"""
3
4slki.ru interface for Gwibber
5lig (Serge Matveenko) - 2009
6
7"""
8
9import urllib2
10
11PROTOCOL_INFO = {
12
13 "name": "slki.ru",
14 "version": 0.1,
15 "fqdn" : "http://slki.ru",
16
17}
18
19class URLShorter:
20
21 def short(self, text):
22 short = urllib2.urlopen("http://slki.ru/api/add/?url=%s" % urllib2.quote(text)).read().rstrip("\n")
23 return short
24