Skip to content

Commit

Permalink
v1.2.1 update
Browse files Browse the repository at this point in the history
  • Loading branch information
Jakads committed Oct 15, 2019
1 parent 6cf6250 commit 72308bc
Show file tree
Hide file tree
Showing 3 changed files with 34 additions and 19 deletions.
16 changes: 11 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,16 +19,22 @@ Supports all keys (4K~9K)
* Various color output using Colorama
* More user-friendly GUI using Tkinter... maybe?
# Changelog
### v1.2.1
* This update partially is to check if the auto-download feature implemented in v1.2 works as intended.
* Better wording (Press any key to turn off the program. → Press any key to exit.)
* Opens this page(changelog) after finishing update
* Bug fixes
* #3 - Unable to deny the update
## v1.2
* Downloads new .exe automatically and then replaces the current one after detecting available update
* **Downloads new .exe automatically and then replaces the current one after detecting available update**
* Bug fixes
* Can't detect files with uppercase extensions (e.g. '.MC', '.MCZ', '.ZIP')
## v1.1
* Automatically ignores unsupported files
* Supports .mcz/.zip files
* **Automatically ignores unsupported files**
* **Supports .mcz/.zip files**
* **Supports multiple BG/Audio files**
* Waits until user's keyboard input using msvcrt.getch() instead of waiting 7 seconds using time.sleep(7)
* Auto-Update feature ~~(temporary, might make it optional or create a seperate Update.exe program)~~\
Made it optional
* Supports multiple BG/Audio files
## v1.0
* Initial Release
* **Initial Release**
35 changes: 22 additions & 13 deletions convert.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,34 +10,44 @@
import string
import random

version = "1.2.1"
date = "October 16th, 2019"

if getattr(sys, 'frozen', False):
os.chdir(os.path.split(sys.executable)[0])
#https://codeday.me/ko/qa/20190316/78831.html

print("Malody to osu!mania Converter v1.2.1")
print("October 16th, 2019")
print(f"Malody to osu!mania Converter v{version}")
print(date)
print("by Jakads\n\n")

version = "1.2.1"
def choose():
choice = getch().decode()
while choice not in 'yYnN':
choice = getch().decode()

if choice in 'nN':
return 0

else:
return 1

if '--:update' in sys.argv: #added ":" to disallow user to view this message by dragging in files
print(f"[O] Successfully updated to v{version}! :D\n\n")
print(f"[O] Successfully updated to v{version}! :D\n[!] Would you like to check out the changelog? (Y/N)\n")
if choose():
webbrowser.open('https://github.com/jakads/Malody-to-Osumania#changelog')
sys.argv.remove('--:update')

print("(i) Checking for updates . . .")
print("(i) Checking new updates . . .")
try:
latest = requests.get('https://github.com/jakads/Malody-to-Osumania/raw/master/version.txt')
latest.raise_for_status()
print(f"\n(i) Latest Version = v{latest.text}")

if latest.text != version:
print("\n[!] New update is available! Would you like to download? (Y/N)")
choice = getch().decode()
while choice not in 'yYnN':
choice = getch().decode()

if choice in 'nN':
print("(i) Skipping the update.")
if not choose():
print("(i) Skipping the update.\n\n")

else:
print("(i) Downloading . . .")
Expand All @@ -63,8 +73,7 @@
f'del {rand}.bat']))
os.startfile(f'{rand}.bat')
sys.exit()
#webbrowser.open('https://github.com/jakads/Malody-to-Osumania#changelog')


else:
print("\n[O] Your program is as good as new! We're good to go.\n\n")
except Exception as e:
Expand Down
2 changes: 1 addition & 1 deletion version.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
1.2
1.2.1

0 comments on commit 72308bc

Please sign in to comment.