-
Notifications
You must be signed in to change notification settings - Fork 43
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
Embed BuildInfo in plugin. #395
Conversation
8e10564
to
bb5ca13
Compare
Actually - please ignore this for a bit. Let me use the actual git build info plugin instead of dupe-ing the code. |
Sure thing On Sun, Aug 23, 2015 at 2:57 PM Advay Mengle [email protected]
|
bb5ca13
to
e84ef15
Compare
ptal, now using a real plugin. |
e84ef15
to
6a82d4e
Compare
@@ -9,3 +9,4 @@ j2objc-gradle.iml | |||
gradlew.bat | |||
|
|||
local.properties | |||
src-gen/ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why doesn't git-build-info output to the build
directory?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
it does. this is old. reverting.
6a82d4e
to
b4e9304
Compare
// Based on https://plugins.gradle.org/docs/publish-plugin | ||
|
||
plugins { | ||
id "com.gradle.plugin-publish" version "0.9.0" | ||
// Outputs a BuildInfo.java file with information about the git repo; | ||
// also fails plugin publishing if your git working directory is unclean. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If accurate, this would be more helpful as an explanation:
...if your git doesn't match a public commit merged in to master
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No. A git working directory being clean is pretty standard wording.
Also it isn't enforcing whether your commits are public or on master.
People often use release branches not called master, and the code is currently not tied to github either (or you might have a private repo, etc.).
The goal is to enforce that you know that state of your repo; if GIT_IS_CLEAN is true and you have a commit SHA, chances are pretty good you do know the state. It isn't guaranteeing that others know the state of the repo.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
i did clarify the above in the comment though
LGTM with one suggestion on plugin comment |
thanks. the plugin doesn't enforce the additional comment you made, but you're more than welcome to add that functionality as optional :) |
- Display version, etc. info on startup - Warn if using an unofficial release - Determine whether build was clean (git-wise) - Prevents publishing from unclean working dir Fixes j2objc-contrib#394 Uses https://github.com/madvay/git-build-info plugin
b4e9304
to
ce7d22e
Compare
Fixes #394
Based on:
https://gist.github.com/advayDev1/56ac2d57d072364adc79