Skip to content

Commit

Permalink
Fix command error
Browse files Browse the repository at this point in the history
  • Loading branch information
himynameisjonas committed Jul 21, 2012
1 parent 02243da commit 3f39b08
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 6 deletions.
3 changes: 3 additions & 0 deletions Base File.sublime-settings
@@ -0,0 +1,3 @@
{

}
4 changes: 2 additions & 2 deletions Default.sublime-commands
@@ -1,6 +1,6 @@
[
{
"caption": "iA Writer: Open file in iA Writer",
"command": "open_in_ia_writer_command"
"caption": "iA Writer: Open current file in iA Writer",
"command": "open_in_ia_writer"
}
]
6 changes: 2 additions & 4 deletions ia-writer-opener.py
Expand Up @@ -5,17 +5,15 @@ class OpenInIaWriterCommand(sublime_plugin.WindowCommand):
def get_path(self):
if self.window.active_view():
return self.window.active_view().file_name()
elif self.window.folders():
return self.window.folders()[0]
else:
sublime.status_message(__name__ + ': No place to open GitX to')
sublime.status_message(__name__ + ': No file')
return False

def is_enabled(self):
return True

def run(self, *args):
print "hej"
print "Opening in iA Writer"
path = self.get_path()
if not path:
return
Expand Down

0 comments on commit 3f39b08

Please sign in to comment.