Skip to content
Browse files

Merge pull request #37 from UncleBill/master

If max_gists is greater than 100, set it 100
Move the error message to status bar, avoiding a noisy dialog window
Saperate menu for Gist
  • Loading branch information...
2 parents 7104328 + c1a022f commit e9ce1295b7e3fc745f40ae89b1c3c32fbd812ef8 @condemil committed Oct 6, 2012
Showing with 19 additions and 22 deletions.
  1. +17 −21 Main.sublime-menu
  2. +2 −1 gist.py
View
38 Main.sublime-menu
@@ -1,29 +1,25 @@
[
{
- "caption": "Tools",
+ "caption": "Gist",
"mnemonic": "T",
- "id": "tools",
+ "id": "root",
"children":
[
- {
- "caption": "Gist",
- "children":
- [
- { "command": "gist", "caption": "Create Public Gist…" },
- { "command": "gist_private", "caption": "Create Private Gist…" },
- { "command": "gist_list", "caption": "Open Gist…" },
- { "command": "insert_gist_list", "caption": "Insert Gist…" },
- { "command": "gist_add_file", "caption": "Add File to Gist…" },
- { "caption": "-" },
- { "command": "gist_copy_url", "caption": "Copy Gist URL" },
- { "command": "gist_open_browser", "caption": "Open Gist in Browser"},
- { "command": "gist_update_file", "caption": "Update File" },
- { "command": "gist_rename_file", "caption": "Rename File…" },
- { "command": "gist_delete_file", "caption": "Delete File" },
- { "command": "gist_change_description", "caption": "Change Gist Description…" },
- { "command": "gist_delete", "caption": "Delete Gist" }
- ]
- }
+
+ { "command": "gist", "caption": "Create Public Gist…" },
+ { "command": "gist_private", "caption": "Create Private Gist…" },
+ { "command": "gist_list", "caption": "Open Gist…" },
+ { "command": "insert_gist_list", "caption": "Insert Gist…" },
+ { "command": "gist_add_file", "caption": "Add File to Gist…" },
+ { "caption": "-" },
+ { "command": "gist_copy_url", "caption": "Copy Gist URL" },
+ { "command": "gist_open_browser", "caption": "Open Gist in Browser"},
+ { "command": "gist_update_file", "caption": "Update File" },
+ { "command": "gist_rename_file", "caption": "Rename File…" },
+ { "command": "gist_delete_file", "caption": "Delete File" },
+ { "command": "gist_change_description", "caption": "Change Gist Description…" },
+ { "command": "gist_delete", "caption": "Delete Gist" }
+
]
},
View
3 gist.py
@@ -30,7 +30,8 @@
if settings.get('max_gists') <= 100:
GISTS_URL += '?per_page=%d' % settings.get('max_gists');
else:
- sublime.error_message("Gist: GitHub API does not support a value of higher than 100")
+ settings.set( "max_gists",100 )
+ sublime.status_message("Gist: GitHub API does not support a value of higher than 100")
class MissingCredentialsException(Exception):
pass

0 comments on commit e9ce129

Please sign in to comment.
Something went wrong with that request. Please try again.