Skip to content

Commit

Permalink
blockProg
Browse files Browse the repository at this point in the history
  • Loading branch information
DavidCruciani committed Jun 1, 2021
1 parent 66a8af1 commit 0e8ed6f
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 2 deletions.
15 changes: 13 additions & 2 deletions bin/Generator.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,20 @@ def runningVms():

def readFile():
f = open(str(pathProg) + "/tmp","r")
f1 = open(allVariables.blockProg, "r")

l = f.readline().rstrip()
l1 = f1.readlines()

f.close()
return l
f1.close()

listTmp = [l.split(":")[0],l.split(":")[1]]

for line in l1:
if line.split(":")[0] == listTmp[1]:
return [listTmp[0], line.split(":")[1]]
return listTmp

def create_rule(ext, hexa, product_version, l_app):
app = ""
Expand Down Expand Up @@ -104,7 +115,7 @@ def runAuto(s):
partage = allVariables.pathToConvert
status = readFile()

convert_file = "%s%s_%s.img" %(partage, status.split(":")[1], status.split(":")[0])
convert_file = "%s%s_%s.img" %(partage, status[1], status[0])

print("## Convertion ##")
############### Mettre plutot le nom de l'exe pour la machine linux pour faire un grep -i direct en fonction du nom
Expand Down
3 changes: 3 additions & 0 deletions etc/allVariables.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
#Path to the list that contains software to install: "nameOfPackage":"nameOfExe"
applist = "tests/listapp.txt"

#Path to list of special software
blockProg = ""

#Settings for server flask
host = "0.0.0.0"
port = "5000"
Expand Down

0 comments on commit 0e8ed6f

Please sign in to comment.