Skip to content

Commit 82cf362

Browse files
authored
bump version, merge pull request #17 from iterative/devel
search curdir for modules
2 parents f9b0795 + 545b03c commit 82cf362

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

shtab/main.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22

33
import argparse
44
import logging
5+
import os
6+
import sys
57
from importlib import import_module
68

79
from . import __version__, complete
@@ -43,6 +45,8 @@ def main(argv=None):
4345
log.debug(args)
4446

4547
module, other_parser = args.parser.rsplit(".", 1)
48+
if sys.path and sys.path[0]: # not blank so not searching curdir
49+
sys.path.insert(1, os.curdir)
4650
try:
4751
module = import_module(module)
4852
except ImportError as err:

0 commit comments

Comments
 (0)