Added PowerShell Script
This commit is contained in:
1 parent
c4274d1d14
commit
928e50e08f
2 files changed
+10
-9
No files matched your search
+7
-7
@@ -11,13 +11,13 @@ log = logging.getLogger(__name__)
|
||||
def envUpdate():
|
||||
if path.exists(".env.template"):
|
||||
if platform == "win32" or platform == "cygwin":
|
||||
#envTemplate = subprocess.run(
|
||||
# [r'C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe',
|
||||
# r'.\envUpdateWin.ps1'],
|
||||
# stdout=subprocess.PIPE, stderr=subprocess.STDOUT,
|
||||
# shell=True
|
||||
#)
|
||||
print("Updating is not yet supported on Windows.")
|
||||
envTemplate = subprocess.run(
|
||||
[r'C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe',
|
||||
r'.\envUpdateWin.ps1'],
|
||||
stdout=subprocess.PIPE, stderr=subprocess.STDOUT,
|
||||
shell=True
|
||||
print("Updating .env is unsupported on Windows.")
|
||||
)
|
||||
return
|
||||
elif platform == "darwin" or platform == "linux":
|
||||
envTemplate = subprocess.check_output(
|
||||
|
||||
@@ -1,2 +1,3 @@
|
||||
$envVars = Get-Content '.\.env'
|
||||
$envVars -split "="
|
||||
#$envVars = Get-Content '.\.env'
|
||||
#$envVars -split "="
|
||||
Write-Host 'Updating the env is unsupported on Windows.'
|
||||
Reference in new issue
Block a user