Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

version string in Mac not updated for 1.2.42 #30

Open
luckman212 opened this issue Feb 26, 2022 · 13 comments
Open

version string in Mac not updated for 1.2.42 #30

luckman212 opened this issue Feb 26, 2022 · 13 comments

Comments

@luckman212
Copy link

Hi @ic005k and thank you for this amazing tool. I saw the new name today, nice 馃殌

small issue: latest tag on API == 1.2.42 but Version string in Mac bundle is still at 1.2.40 so my auto update script is broken. Hope you can fix. Thank you 馃檹

@ic005k
Copy link
Owner

ic005k commented Feb 26, 2022

Sorry, I remember making the same mistake once before. Thanks for reminding me. I believe I won't make this mistake again, thank you.

@luckman212
Copy link
Author

Hmm. Sorry to bother you again, but it looks like the same thing has happened.

latest release tag == 1.2.44
mac version string == 1.2.43

@ic005k
Copy link
Owner

ic005k commented Feb 28, 2022

This problem will never happen again, because the current method of writing the Mac version number automatically is used, so there is no mistake, it is written automatically.
I don't know where you are looking at the Mac version number, you should open the Info.plist inside the app to check the version number.

@ic005k
Copy link
Owner

ic005k commented Feb 28, 2022

Please don't check the Info.plist file in the source code, it is just a demo, it doesn't represent the Info.plist inside the final APP, and this Info.plist is not updated, it is only for testing APP use.

https://github.com/ic005k/Xplist/blob/main/Info.plist

@ic005k
Copy link
Owner

ic005k commented Feb 28, 2022

If your script uses a grab of Info.plist from the source code to determine the Mac version number, that would be very unscientific and inaccurate. Because it is a temporary file and does not represent the Info.plist inside the final app.

@luckman212
Copy link
Author

I don't know ... this is a fresh download from the 1.2.44 release ...

CleanShot 2022-02-27 at 19 52 13

@ic005k
Copy link
Owner

ic005k commented Feb 28, 2022

Oh, APP will update this version number automatically when you run it, you copy APP to normal working directory and when you run it, APP will refresh the version number automatically, please don't worry.

@ic005k
Copy link
Owner

ic005k commented Feb 28, 2022

So here's your confusion, I understand it now.
Please copy this app to the application directory or desktop, etc., run it and you will find the version number refreshed automatically.

@luckman212
Copy link
Author

Huh. Been around a while and have to say I've never seen an app do that (self-update its own Info.plist in-place). But - yes you're right it worked after launching the app. The version string updated. I'll just need to change my script to run the app before re-checking the version.

@ic005k
Copy link
Owner

ic005k commented Feb 28, 2022

The GitHub API of the app is attached at the bottom of Readme, you only need to detect the "tag_name" in this API to get the version number of the app.
I don't know what your script is for, why do you need to get the version number of the app statically?

@ic005k
Copy link
Owner

ic005k commented Feb 28, 2022

In any case, please feel free to leave a comment with any questions or suggestions.

@luckman212
Copy link
Author

Script I wrote is part of a system I have that keeps my apps updated automatically. It queries Github API to get latest tag and then compares it to local app version (by looking at Info.plist) to see if it's newer. If it is, the it downloads and copies it to the /Applications folder.

So, this kind of breaks that system because, although new version is detected, even after downloading and installing it, the bundle version remains stuck at 1.2.43 until the app is launched. Kind of a weird system but I will try to work around it.

@luckman212
Copy link
Author

I was able to modify my script to work around this. Thanks again.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants