Apr-01-2020, 02:52 AM
I am making multiple applications that I want to update over time. Instead of forcing my users to redownload from a file hosting website or (if I set it up) my own website.
I am using tkinter as a GUI, so I could just have a "Check for updates" button. But I want to discuss the code necessary to make this happen.
I would be using cx_Freeze to compile my program, which probably makes it harder to do it.
So here is an example of what I want.
I would have a folder (let's call it update.py). From this file, I will select another file/group of files and this will be the "update". update.py will then send some sort of message to cause the main application (main.py) to run a subprogram which reinstalls the program (this means it will delete the files, then reinstall them).
An alternative thing that I could do is have another update.py on the clients end, this will run and do the same as what the subprogram would do in main.py.
The first test I would probably do is just updating a file that replaces a
to a
, or something similar.
I am using tkinter as a GUI, so I could just have a "Check for updates" button. But I want to discuss the code necessary to make this happen.
I would be using cx_Freeze to compile my program, which probably makes it harder to do it.
So here is an example of what I want.
I would have a folder (let's call it update.py). From this file, I will select another file/group of files and this will be the "update". update.py will then send some sort of message to cause the main application (main.py) to run a subprogram which reinstalls the program (this means it will delete the files, then reinstall them).
An alternative thing that I could do is have another update.py on the clients end, this will run and do the same as what the subprogram would do in main.py.
The first test I would probably do is just updating a file that replaces a
1 |
print ( "Hello World" ) |
1 |
print ( "Hello Update" ) |