Skip to content

Commit d06235b

Browse files
committed
automatically load _before.py and _after.py to allow hooking into GS initialisation
1 parent f8adbc8 commit d06235b

File tree

4 files changed

+12
-0
lines changed

4 files changed

+12
-0
lines changed

.gitignore

+2
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
_before.py
2+
_after.py
13
bin/**
24
pkg/**
35
!.keep

GoSublime.py

+4
Original file line numberDiff line numberDiff line change
@@ -22,16 +22,20 @@
2222
print("GoSublime: %s" % execErr)
2323

2424
def loadable_mods():
25+
from . import _before
26+
from . import _after
2527
from .gosubl import gs
2628
from .gosubl import sh
2729
from .gosubl import margo
2830
from .gosubl import mg9
2931

3032
return [
33+
('_before', _before),
3134
('gs', gs),
3235
('sh', sh),
3336
('margo', margo),
3437
('mg9', mg9),
38+
('_after', _after),
3539
]
3640

3741
def plugin_loaded():

_after.py

+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
2+
def gs_init(m={}):
3+
pass

_before.py

+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
2+
def gs_init(m={}):
3+
pass

0 commit comments

Comments
 (0)