Skip to content

Commit 195529a

Browse files
committed
add parameters for lua and themepark path
1 parent b2765ac commit 195529a

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

scripts/osm2pgsql-test-style

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -501,6 +501,10 @@ def execute_osm2pgsql(context, output):
501501
data_stdin = None
502502

503503
env = {}
504+
if context.user_args.lua_path:
505+
env['LUA_PATH'] = context.user_args.lua_path
506+
if context.user_args.themepark_path:
507+
env['THEMEPARK_PATH'] = context.user_args.themepark_path
504508

505509
proc = Popen(cmdline, cwd=str(context.workdir),
506510
stdin=PIPE, stdout=PIPE, stderr=PIPE, env=env)
@@ -786,6 +790,10 @@ def get_parser():
786790
help='(optional) directory to search for test data')
787791
parser.add_argument('--style-data-dir', type=Path,
788792
help='(optional) directory to search for style files')
793+
parser.add_argument('--lua-path',
794+
help='Additional paths to take into account for finding lua modules')
795+
parser.add_argument('--themepark-path',
796+
help='Additional paths to take into account for finding themepark themes')
789797
parser.add_argument('--test-db', default='osm2pgsql-test',
790798
help='Name of database to use for testing (default: osm2pgsql-test)')
791799
parser.add_argument('--template-test-db', default='osm2pgsql-test-template',

0 commit comments

Comments
 (0)