mirror of
https://github.com/whyour/qinglong.git
synced 2026-12-01 09:45:36 +08:00
修复环境变量中单引号转义
This commit is contained in:
1 parent
461fa8e131
commit
fe934fa4af
4 files changed
+8
-35
No files matched your search
@@ -202,9 +202,7 @@ export default class EnvService {
|
||||
let value = group
|
||||
.map((x) => x.value)
|
||||
.join('&')
|
||||
.replace(/(\\)[^n]/g, '\\\\')
|
||||
.replace(/(\\$)/, '\\\\')
|
||||
.replace(/'/g, "\\'")
|
||||
.replace(/'/g, "'\\''")
|
||||
.trim();
|
||||
env_string += `export ${key}='${value}'\n`;
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user