Skip to content

Instantly share code, notes, and snippets.

@vprimachenko
Created March 23, 2013 13:16
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save vprimachenko/5227698 to your computer and use it in GitHub Desktop.
Save vprimachenko/5227698 to your computer and use it in GitHub Desktop.
really simple and hacky autoupdater for sublime text 3
import sublime, sublime_plugin
import urllib.request,subprocess,io,json,os
class AutoUpdateCommand(sublime_plugin.ApplicationCommand):
def run(self):
v__ = json.loads(urllib.request.urlopen("http://www.sublimetext.com/updates/3/dev/updatecheck").read().decode("utf8"))['latest_version'];
subprocess.Popen(['update.bat',str(v__)])
sublime.run_command('exit');
[
{
"id": "help",
"children":
[
{
"caption": "Update",
"command": "auto_update",
}
]
}
]
wget "http://c758482.r82.cf2.rackcdn.com/Sublime Text Build %1 x64.zip" -O sublime.zip
unzip -o sublime.zip
start sublime_text.exe
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment