Skip to content

Commit

Permalink
build
Browse files Browse the repository at this point in the history
  • Loading branch information
MehVahdJukaar committed Aug 4, 2024
1 parent 2c7f5b6 commit f0fe70e
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 8 deletions.
2 changes: 1 addition & 1 deletion build.properties
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#Sat Aug 03 23:57:31 UTC 2024
#Sun Aug 04 00:22:42 UTC 2024
mapping_version=1.20.1
version=1.0
mod_name=Zeta
Expand Down
15 changes: 8 additions & 7 deletions push_tag.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,20 +15,21 @@ def main():
print('Version:', version)
print('Build Number', build_number)

changelog = '-m "Changelog:" '
changelog = ''
with open('changelog.txt', 'r') as f:
content = f.read()
content = content.replace('"', '\'')
lines = content.splitlines()
for line in lines:
changelog = changelog + '-m "'+line+'" '

content = content.replace('"', '\'');
changelog = changelog + re.sub(r'(- .+)\n?', '-m "\g<1>" ', content)

print('Changelog', changelog)

tag_success = os.system('git tag -a release-{}-{}-{} "{}"'.format(mc_version, version, build_number, changelog))
tag_success = os.system('git tag -a release-{}-{}-{}b {}'.format(mc_version, version, build_number, changelog))

if tag_success != 0:
print('Failed to create tag')
return
else :
print('Created tag')

build['build_number'] = str(int(build_number) + 1)
with open("build.properties", "wb") as f:
Expand Down

0 comments on commit f0fe70e

Please sign in to comment.