Permalink
Browse files

Merge branch 'master' of github.com:baverman/snaked

  • Loading branch information...
baverman committed May 23, 2012
2 parents ab99d9a + 7c104b7 commit 52a9146eae4a91d3776311d9c632682d55c307b2
Showing with 1 addition and 22 deletions.
  1. +1 −1 snaked/core/plugins.py
  2. +0 −21 snaked/plugins/goto_dir/__init__.py
View
@@ -9,7 +9,7 @@
default_enabled_plugins = ['save_positions', 'edit_and_select',
'python', 'complete_words', 'hash_comment', 'python_flakes', 'goto_line',
- 'goto_dir', 'search']
+ 'search']
enabled_plugins = []
@@ -1,21 +0,0 @@
-author = 'Anton Bobrov<bobrov@vl.ru>'
-name = 'Goto dir'
-desc = "Opens file's directory"
-
-def init(injector):
- injector.bind_accel('editor-active', 'goto-dir', 'File/Open file\'s directory#30',
- '<ctrl><alt>l', goto_dir)
-
-def goto_dir(editor):
- import gio
- import os.path
-
- f = gio.file_parse_name(os.path.dirname(editor.uri))
- ct = f.query_info(gio.FILE_ATTRIBUTE_STANDARD_CONTENT_TYPE).get_content_type()
- ai = gio.app_info_get_default_for_type(ct, False)
-
- if ai:
- ai.launch([f])
- editor.message('File manager started', 1000)
- else:
- editor.message('Unknown content type for launch %s' % ct)

0 comments on commit 52a9146

Please sign in to comment.