diff options
author | CaselIT <cfederico87@gmail.com> | 2021-05-11 20:17:00 +0200 |
---|---|---|
committer | CaselIT <cfederico87@gmail.com> | 2021-05-11 21:26:10 +0200 |
commit | b729cbbce1fc643557e7d68b31b77090dab082a5 (patch) | |
tree | 1bc38664a3dbe90b5329e1295c73a41bc339076e /alembic/script | |
parent | 017eed1ed8ee2ad0f5e038f68a851ccaf9334a43 (diff) | |
download | alembic-b729cbbce1fc643557e7d68b31b77090dab082a5.tar.gz |
Fixed a bug where paths defined in post-write hook options
would be wrongly escaped in non posix environment (Windows).
Fixes: #841
Change-Id: Ife74d9291523378da113c259e3c173a8bc054e47
Diffstat (limited to 'alembic/script')
-rw-r--r-- | alembic/script/write_hooks.py | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/alembic/script/write_hooks.py b/alembic/script/write_hooks.py index 133bf04..c69ce5a 100644 --- a/alembic/script/write_hooks.py +++ b/alembic/script/write_hooks.py @@ -99,7 +99,9 @@ def _parse_cmdline_options(cmdline_options_str, path): """ if REVISION_SCRIPT_TOKEN not in cmdline_options_str: cmdline_options_str = REVISION_SCRIPT_TOKEN + " " + cmdline_options_str - cmdline_options_list = shlex.split(cmdline_options_str) + cmdline_options_list = shlex.split( + cmdline_options_str, posix=compat.is_posix + ) cmdline_options_list = [ option.replace(REVISION_SCRIPT_TOKEN, path) for option in cmdline_options_list |