Permalink
Browse files

Merge pull request #31 from abudden/devel

Fixes for paths with spaces and support for opening notes at the right.
  • Loading branch information...
2 parents 66d2f47 + 6b1aca0 commit c5796e759c7e5322ee330db8e68a6e5dcea70413 @fmoralesc committed Aug 28, 2012
Showing with 6 additions and 3 deletions.
  1. +4 −1 plugin/padlib/handler.py
  2. +2 −2 plugin/padlib/vim_globals.py
@@ -34,7 +34,10 @@ def open_pad(path=None, first_line=None): #{{{1
path = join(get_save_dir(), timestamp())
if bool(int(vim.eval("g:pad_open_in_split"))):
- vim.command("silent! botright" + str(vim.eval("g:pad_window_height")) + "split " + path)
+ if vim.eval('g:pad_position') == 'right':
+ vim.command("silent! rightbelow" + str(vim.eval("g:pad_window_width")) + "vsplit " + path)
+ else:
+ vim.command("silent! botright" + str(vim.eval("g:pad_window_height")) + "split " + path)
else:
vim.command("silent! edit " + path)
@@ -28,6 +28,6 @@ def set_vim_globals():
# we forbid writing backups of the notes
orig_backupskip = vim.eval("&backupskip")
- vim.command("set backupskip=" +
- ",".join([orig_backupskip, join(get_save_dir(), "*")]))
+ vim.command("let &backupskip='" +
+ ",".join([orig_backupskip, join(get_save_dir(), "*")])+"'")

0 comments on commit c5796e7

Please sign in to comment.