Permalink
Browse files

show author names

  • Loading branch information...
1 parent 3f059f3 commit 0522fabf68a1863b6b7c666135babf20eb0a3c40 @s2b committed Oct 18, 2012
Showing with 9 additions and 1 deletion.
  1. +3 −0 Gist.sublime-settings
  2. +6 −1 gist.py
View
@@ -17,6 +17,9 @@
"include_users": false,
// "include_users": ["user1", "user2"],
+ // Show the authors of Gists
+ "show_authors": false,
+
// Proxy server
// Format: "http://user:pass@proxy:port"
"https_proxy": "",
View
@@ -272,7 +272,12 @@ def get_user_gists(user):
return api_request(USER_GISTS_URL % user)
def gist_title(gist):
- return gist.get('description') or gist.get('id')
+ title = gist.get('description') or gist.get('id')
+
+ if settings.get('show_authors'):
+ return [title, gist.get('user').get('login')]
+ else:
+ return title
def api_request_native(url, data=None, method=None):
request = urllib2.Request(url)

0 comments on commit 0522fab

Please sign in to comment.