| |
@@ -138,9 +138,12 @@
|
| |
self._distunset = 'rhel'
|
| |
# If we don't match one of the above, punt
|
| |
else:
|
| |
- raise pyrpkg.rpkgError('Could not find the release/dist from branch name '
|
| |
- '%s\nPlease specify with --release' %
|
| |
- self.branch_merge)
|
| |
+ if self.dist:
|
| |
+ msg = 'Invalid release \'%s\'.' % self.branch_merge
|
| |
+ else:
|
| |
+ msg = 'Could not find release from branch name \'%s\'. Please specify with --release.' % self.branch_merge
|
| |
+ raise pyrpkg.rpkgError(msg)
|
| |
+
|
| |
self._rpmdefines = ["--define", "_sourcedir %s" % self.layout.sourcedir,
|
| |
"--define", "_specdir %s" % self.layout.specdir,
|
| |
"--define", "_builddir %s" % self.layout.builddir,
|
| |
Currently, if the resolved release name does not match any supported pattern (
rawhide'
,f38
or so),the following error is printed:
This is fine when the current Git branch name was used when resolving the release.
However, the exact same error is printed even if the
--release
option was used, like this:The error message is split into two cases depending on if
--release
was used(detected by checking if
self.dist
is truthy):Signed-off-by: Otto Liljalaakso otto.liljalaakso@iki.fi