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

Add methods to UI::Application to return app build number and version number #58

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

hboon
Copy link
Collaborator

@hboon hboon commented Dec 13, 2016

(main)> UI::Application.instance.build_number
=> "27"
(main)> UI::Application.instance.version_number
=> "1.0.0"

@Watson1978
Copy link
Member

I like version_string instead of version_number because version_number returns String object.

@hboon
Copy link
Collaborator Author

hboon commented Dec 14, 2016

What about build_number? It is a String on iOS, but Fixnum in Android.

@jjaffeux
Copy link
Contributor

@hboon I feel it weird to have this under the UI namespace, how is this related to UI?

@andrewhavens
Copy link
Collaborator

I think build_number and version_number are fine. I think most people think of "version number" as something like 1.0.0, not as a literal integer or float. The fact that it is represented as a string is secondary. I don't think version_string is as obvious or necessary.

@Watson1978
Copy link
Member

What about build_number? It is a String on iOS, but Fixnum in Android.

@hboon it may not be a problem, because CFBundleShortVersionString allow only numbers.
However, I think that it is necessary to clarify it in the document that these methods return string.

@hboon
Copy link
Collaborator Author

hboon commented Dec 15, 2016

@jjaffeux I thought of that yesterday too. It is a little out of place. I added it there originally because I'd only used UI Flow at the moment and it has a UI:Application class. Any suggestion for a better place? The other "modules" don't seem suitable either.

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

Successfully merging this pull request may close these issues.

None yet

4 participants