This change fixes confusing behaviour of changelog mode. When there are
more than one .spec file in packaging/ directory first one is picked up
for processing. Users were confused, because there was not way to
understand which spec will be used and there was not way to specify spec
to proceed with.
Fixes: #399
Change-Id: I65d546b1c0d2fee93bdad8ed03c39d1588edf7d8
Signed-off-by: Ed Bartosh <eduard.bartosh@intel.com>
% (changes_file_list[0]))
else:
# Create .changes file with the same name as a spec
- spec_file_list = glob.glob("%s/packaging/*.spec" % project_root_dir)
- if spec_file_list:
- fn_changes = os.path.splitext(spec_file_list[0])[0] + ".changes"
- else:
- msger.error("Found no changes nor spec files under packaging dir")
+ specfile = utils.guess_spec(project_root_dir, args.spec)
+ fn_changes = os.path.splitext(specfile)[0] + ".changes"
# get the commit start from the args.since
if args.since:
default=os.getcwd(),
help='path to git repository')
+ parser.add_argument('--spec', help='specify a spec file to use')
parser.add_argument('-s', '--since',
help='commit to start from')
parser.add_argument('-m', '--message',