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’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Set Microsoft Windows Version Information on Windows executable #484

Open
karel26 opened this issue Jan 11, 2025 · 6 comments
Open

Set Microsoft Windows Version Information on Windows executable #484

karel26 opened this issue Jan 11, 2025 · 6 comments

Comments

@karel26
Copy link

karel26 commented Jan 11, 2025

Hi mate, great work! I am working on integrating your solution into DCSServerBot atm, and I would prefer to have a version number at least in the skyeye.exe. That lets me handle autoupdates for people.
Should be a small step for you, but a big for mankind ;).

Cheers

Special K

@dharmab
Copy link
Owner

dharmab commented Jan 12, 2025

Hi, does ./skyeye.exe --version report the correct version? I know it's busted in the Docker container but I thought it was working for the native binaries.

@dharmab
Copy link
Owner

dharmab commented Jan 12, 2025

Downloaded the version from GitHub and it seems to work?
image

@karel26
Copy link
Author

karel26 commented Jan 12, 2025

Yes, that is what I use atm. I just like it better, if the exe itself has the version information in its metadata.
It is ok, I can work with it. My extension is ready btw., will be in the next release of my bot!

@karel26
Copy link
Author

karel26 commented Jan 12, 2025

That is what I do, just in case:

info = win32api.GetFileVersionInfo(os.path.expandvars(cmd), '\\')
        version = "%d.%d.%d.%d" % (info['FileVersionMS'] / MS_LSB_MULTIPLIER,
                                   info['FileVersionMS'] % MS_LSB_MULTIPLIER,
                                   info['FileVersionLS'] / MS_LSB_MULTIPLIER,
                                   info['FileVersionLS'] % MS_LSB_MULTIPLIER)

@dharmab
Copy link
Owner

dharmab commented Jan 13, 2025

Ah, looks like there's a module to help with that in Go: https://github.com/josephspurrier/goversioninfo

My graphics card in my Windows PC broke and I'm waiting for the RMA process to complete, I can look at it after that.

@dharmab dharmab changed the title Add version information to skyeye.exe Set Microsoft Windows Version Information on Windows executable Jan 13, 2025
@karel26
Copy link
Author

karel26 commented Jan 14, 2025

Yeah, you can have a look at my sneaker fork, I added it in there also. You just need to create a simple versioninfo.json
It is low priority though, my extensions is working without it already, as long as you keep the -v also.

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

No branches or pull requests

2 participants