Comments (7)
Thanks for your report and the hint. I will look into it asap.
from gradle-release-plugin.
Your right! Sorry for the false alarm.
from gradle-release-plugin.
I think changing ReleaseTask Line 76 to this should do the trick:
}.assertNormalExitValue()
See org.gradle.api.Project:exec and ExecResult
from gradle-release-plugin.
Fixed in 1.2.1 (available on Bintray and Gradle plugin central).
from gradle-release-plugin.
@netzwerg Great! That was impressively fast!
Unfortunately, I just realized something about what I suggested and what you implemented: if the git command fails, then no output from the command will be logged, which would make it pretty hard to figure out why it failed.
Should be another pretty easy fix:
def result = project.exec { //stuff }
// print out the output (if any)
result.assertNormalExitValue()
from gradle-release-plugin.
I tested it with a repo for which I removed all remotes but still have a release { push = true }
configuration. The underlying git error is then written to the console:
:release
fatal: 'origin' does not appear to be a git repository
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.
:release FAILED
It's not pretty, but should be sufficient to figure out why the build failed.
But you are correct, the output should also be logged – thanks for the pointer!
from gradle-release-plugin.
Actually I do get log entries:
20:59:16.934 [ERROR] [system.err] fatal: 'origin' does not appear to be a git repository
20:59:16.935 [ERROR] [system.err] fatal: Could not read from remote repository.
20:59:16.936 [ERROR] [system.err]
20:59:16.936 [ERROR] [system.err] Please make sure you have the correct access rights
20:59:16.936 [ERROR] [system.err] and the repository exists.
no output from the command will be logged
Do you really see nothing at all?
from gradle-release-plugin.
Related Issues (20)
- Should it be mentioned it works only with git?
- Push to current branch rather than master
- Multi-project setup: `release.dependsOn` configuration should not be mandatory HOT 7
- Clarify docs about the version pattern
- Provide different release tasks for upgrading different parts of the version HOT 1
- All tasks only increment patch version (in submodules) HOT 7
- Version.txt in subprojects HOT 2
- Stop relying on `project.afterEvaluate` for project version initialization
- Wrong message upon version parsing exception
- Could not determine the dependencies of task ':release' HOT 2
- Master branch is moved after pushing with the plugin HOT 2
- pass in authentication credential and patch release HOT 2
- Add `releasePatchVersion` task (identical to current `release` task)
- Hook to publish release HOT 6
- git executable output needs to be logged before exiting HOT 10
- Support usage of abbreviated task names
- Issue with Single Quotes on Windows HOT 3
- Add support for flavor based version.txt HOT 1
- Unable the push tags HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from gradle-release-plugin.