Skip to content

Commit

Permalink
correct order
Browse files Browse the repository at this point in the history
  • Loading branch information
Delwing committed Apr 7, 2022
1 parent ef6bd1b commit 03b594c
Showing 1 changed file with 10 additions and 12 deletions.
22 changes: 10 additions & 12 deletions .github/workflows/release.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,18 +4,6 @@
import sys
from datetime import datetime

def addDirToZip(zipObj, dirName):
for folderName, subfolders, filenames in os.walk(dirName):
for filename in filenames:
filePath = os.path.join(folderName, filename)
basePath = os.path.relpath(filePath, dirName)
zipObj.write(filePath, "mudlet-release/" + dirName + "/" + basePath)

with ZipFile("mudlet-release.zip", "w") as zipObj:
addDirToZip(zipObj, "vendor")
zipObj.write("mudlet-release.php", "mudlet-release/mudlet-release.php")


version = sys.argv[1]
now = datetime.now()

Expand All @@ -35,3 +23,13 @@ def addDirToZip(zipObj, dirName):
with open('mudlet-release.php', "w") as text_file:
text_file.write(texts)

def addDirToZip(zipObj, dirName):
for folderName, subfolders, filenames in os.walk(dirName):
for filename in filenames:
filePath = os.path.join(folderName, filename)
basePath = os.path.relpath(filePath, dirName)
zipObj.write(filePath, "mudlet-release/" + dirName + "/" + basePath)

with ZipFile("mudlet-release.zip", "w") as zipObj:
addDirToZip(zipObj, "vendor")
zipObj.write("mudlet-release.php", "mudlet-release/mudlet-release.php")

0 comments on commit 03b594c

Please sign in to comment.