mirror of
https://repo.dactyloidae.xyz/Dactyloidae/UXP.git
synced 2026-08-15 08:53:07 +09:00
Shell quote environment variable values when dumping them in dump_env.py
The mozconfig output parsing code already (mostly) handles shell quoted strings, because that's what `set` outputs. By quoting environment variable values, we avoid a bunch of problems with "weird" values.
This commit is contained in:
parent
37bb4f9108
commit
cfdaeb9645
1 changed files with 7 additions and 1 deletions
|
|
@ -6,5 +6,11 @@
|
|||
# native paths printed on Windows so that these paths can be incorporated
|
||||
# into Python configure's environment.
|
||||
import os
|
||||
import sys
|
||||
|
||||
sys.path.append(os.path.join(os.path.dirname(__file__), '..'))
|
||||
|
||||
from shellutil import quote
|
||||
|
||||
for key, value in os.environ.items():
|
||||
print('%s=%s' % (key, value))
|
||||
print('%s=%s' % (key, quote(value)))
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue