Am trying to push using JGit. However my PushResults never has the messages assosiated with Push. For example how do I get the message "Everything-up-to-date" when my push has nohing new. Basically I want to get the result messages from JGit. Any help would be greatly appreciated.
I kind of figured from the code that those messages are written by Push.java under the option that Verbose is set to true. But I couldn't find a way to set verbose on.
PushResult#getMessages() returns additional messages sent from the remote. Gerrit for example would send a message that explains why a push was rejected.
In order to obtain the result of a push operation you can call PushResult#getRemoteUpdates(). It returns a RemoteRefUpdate that holds the status for each ref that was to be updated.
Does that answer your question?
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With