Merge branch 'master' of https://github.com/caiocutrim/ex-mode into caiocutrim-master

This commit is contained in:
jazzpi 2015-12-28 13:14:50 +01:00
commit d6afe394ef

View file

@ -112,8 +112,13 @@ class Ex
quit: -> quit: ->
atom.workspace.getActivePane().destroyActiveItem() atom.workspace.getActivePane().destroyActiveItem()
quitall: ->
atom.workspace.getPanes()[0].destroy()
q: => @quit() q: => @quit()
qa: => @quitall()
tabedit: (args) => tabedit: (args) =>
if args.args.trim() isnt '' if args.args.trim() isnt ''
@edit(args) @edit(args)
@ -216,20 +221,37 @@ class Ex
deferred.promise deferred.promise
wall: ->
atom.workspace.saveAll()
w: (args) => w: (args) =>
@write(args) @write(args)
wq: (args) => wq: (args) =>
@write(args).then => @quit() @write(args).then => @quit()
wa: =>
@wall()
wqall: =>
atom.workspace.saveAll()
@quitall()
wqa: =>
@wqall()
xall: =>
@wqall()
xa: =>
@wqall()
saveas: (args) => saveas: (args) =>
args.saveas = true args.saveas = true
@write(args) @write(args)
xit: (args) => @wq(args) xit: (args) => @wq(args)
wa: ->
atom.workspace.saveAll()
split: ({ range, args }) -> split: ({ range, args }) ->
args = args.trim() args = args.trim()