예제 #1
0
def on_install_done(c):
	s = output_str(c)
	x = c.exception()
	if x:
		tpl = 'Error while installing dependencies\nCommand: %s\nException: %s\nOutput: %s'
		gs.show_output(DOMAIN, tpl % (c.cmd, x, s), merge_domain=True)

	js, _, _ = gsshell.run(cmd=BUNDLE_GOSUBLIME9, shell=True)
	js = json.loads(js)
	for k,v in js.iteritems():
		if v:
			gs.environ9[k] = v

	print_install_log(c, s)

	c = gsshell.Command(cmd=[
		BUNDLE_MARGO,
		"-d",
		"-call", "replace",
		"-addr", gs.setting('margo_addr', '')
	])
	c.on_done = on_margo_done
	c.start()

	gsshell.run(cmd=[BUNDLE_GOCODE, 'close'])
예제 #2
0
		def cb():
			aso = gs.aso()
			old_rev = aso.get('changelog.rev', '')
			new_rev = changes[0][0]
			if new_rev > old_rev:
				aso.set('changelog.rev', new_rev)
				gs.save_aso()

				new_changes = [
					'GoSublime: Recent Updates (you may need to restart Sublime Text for changes to take effect)',
					'------------------------------------------------------------------------------------------',
				]

				for change in changes:
					rev, msg = change
					if rev > old_rev:
						new_changes.append('\n%s\n\t%s' % (rev, msg))
					else:
						break

				new_changes.append('\nSee %s for the full CHANGELOG\n' % changelog_fn)
				new_changes = '\n'.join(new_changes)
				gs.show_output(DOMAIN, new_changes, print_output=False)
예제 #3
0
def on_install_done(c):
    s = output_str(c)
    x = c.exception()
    if x:
        tpl = 'Error while installing dependencies\nCommand: %s\nException: %s\nOutput: %s'
        gs.show_output(DOMAIN, tpl % (c.cmd, x, s), merge_domain=True)

    js, _, _ = gsshell.run(cmd=BUNDLE_GOSUBLIME9, shell=True)
    js = json.loads(js)
    for k, v in js.iteritems():
        if v:
            gs.environ9[k] = v

    print_install_log(c, s)

    c = gsshell.Command(cmd=[
        BUNDLE_MARGO, "-d", "-call", "replace", "-addr",
        gs.setting('margo_addr', '')
    ])
    c.on_done = on_margo_done
    c.start()

    gsshell.run(cmd=[BUNDLE_GOCODE, 'close'])
예제 #4
0
	def show_hint(self, s):
		dmn = '%s.completion-hint' % DOMAIN
		gs.show_output(dmn, s, print_output=False, syntax_file='GsDoc')
예제 #5
0
	def show_output(self, s):
		gs.show_output(DOMAIN+'-output', s, False, 'Packages/Go/Go.tmLanguage')
예제 #6
0
	def run(self):
		s = 'GoSublime Sanity Check\n\n%s' % '\n'.join(['%7s: %s' % ln for ln in _sanity_check()])
		gs.show_output(DOMAIN, s, print_output=False)
예제 #7
0
	def show_output(self, s):
		gs.show_output(DOMAIN+'-output', s, False, 'GsDoc')
예제 #8
0
 def show_hint(self, s):
     dmn = '%s.completion-hint' % DOMAIN
     gs.show_output(dmn, s, print_output=False, syntax_file='GsDoc')
예제 #9
0
파일: gsdoc.py 프로젝트: timicx/GoSublime
 def show_output(self, s):
     gs.show_output(DOMAIN + "-output", s, False, "GsDoc")
예제 #10
0
파일: gscomplete.py 프로젝트: ski/GoSublime
 def show_hint(self, s):
     dmn = "%s.completion-hint" % DOMAIN
     gs.show_output(dmn, s, print_output=False, syntax_file="GsDoc")
예제 #11
0
 def run(self):
     s = 'GoSublime Sanity Check\n\n%s' % '\n'.join(
         ['%7s: %s' % ln for ln in _sanity_check()])
     gs.show_output(DOMAIN, s, print_output=False)
예제 #12
0
 def run(self):
     s = "GoSublime Sanity Check\n\n%s" % "\n".join(["%7s: %s" % ln for ln in _sanity_check()])
     gs.show_output(DOMAIN, s, print_output=False)