Skip to content

Commit 48b854e

Browse files
committed
Correcao do choco install
1 parent 82ee06a commit 48b854e

File tree

1 file changed

+8
-2
lines changed

1 file changed

+8
-2
lines changed

install_coops_python.py

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,11 @@
1818
}
1919

2020

21+
#executa instalacao de programas
22+
def installprograma(programa):
23+
env = os.environ.copy()
24+
subprocess.call("choco install -y " + programa, env=env, shell=True)
25+
2126
#Cria Diretorio Arcom
2227
def createdirarcom(diretorioarcom):
2328
if not os.path.exists(diretorioarcom):
@@ -67,12 +72,13 @@ def executarscripts(values):
6772
for descricao, comando in programas.items():
6873
if values[comando]:
6974
print("Instalando " + descricao )
70-
subprocess.call("powershell.exe choco install -y " + comando, shell=True)
75+
installprograma(comando)
76+
7177

7278
if values['programsinstall']:
7379
print("Executando instalacao de todos os programas")
7480
for descricao, comando in programas.items():
75-
subprocess.call("powershell.exe choco install -y " + comando, shell=True)
81+
installprograma(comando)
7682

7783
if values['sisbrinstall']:
7884
createdirarcom(diretorioarcom)

0 commit comments

Comments
 (0)