mirror of
https://github.com/peridotbuild/pv2.git
synced 2024-11-27 07:26:31 +00:00
preconv name support for git imports
This commit is contained in:
parent
0913ae912f
commit
236f18412b
@ -620,6 +620,7 @@ class GitImport(Import):
|
|||||||
scl_mode: bool = False,
|
scl_mode: bool = False,
|
||||||
scl_package: str = '',
|
scl_package: str = '',
|
||||||
alternate_spec_name: str = '',
|
alternate_spec_name: str = '',
|
||||||
|
preconv_names: bool = False,
|
||||||
dest_lookaside: str = '/var/www/html/sources',
|
dest_lookaside: str = '/var/www/html/sources',
|
||||||
source_git_protocol: str = 'https',
|
source_git_protocol: str = 'https',
|
||||||
dest_branch: str = '',
|
dest_branch: str = '',
|
||||||
@ -644,6 +645,9 @@ class GitImport(Import):
|
|||||||
if source_git_protocol == 'ssh':
|
if source_git_protocol == 'ssh':
|
||||||
full_source_git_url_path = f'{source_git_user}@{source_git_url_path}'
|
full_source_git_url_path = f'{source_git_user}@{source_git_url_path}'
|
||||||
|
|
||||||
|
if preconv_names:
|
||||||
|
package = package.replace('+', 'plus')
|
||||||
|
|
||||||
self.__source_git_url = f'{source_git_protocol}://{full_source_git_url_path}/{source_git_org_path}/{package}.git'
|
self.__source_git_url = f'{source_git_protocol}://{full_source_git_url_path}/{source_git_org_path}/{package}.git'
|
||||||
self.__dest_git_url = f'ssh://{dest_git_user}@{dest_git_url_path}/{dest_org}/{package}.git'
|
self.__dest_git_url = f'ssh://{dest_git_user}@{dest_git_url_path}/{dest_org}/{package}.git'
|
||||||
self.__dist_prefix = distprefix
|
self.__dist_prefix = distprefix
|
||||||
@ -654,6 +658,7 @@ class GitImport(Import):
|
|||||||
self.__upstream_lookaside = upstream_lookaside
|
self.__upstream_lookaside = upstream_lookaside
|
||||||
self.__upstream_lookaside_url = self.get_lookaside_template_path(upstream_lookaside)
|
self.__upstream_lookaside_url = self.get_lookaside_template_path(upstream_lookaside)
|
||||||
self.__alternate_spec_name = alternate_spec_name
|
self.__alternate_spec_name = alternate_spec_name
|
||||||
|
self.__preconv_names = preconv_names
|
||||||
self.__aws_access_key_id = aws_access_key_id
|
self.__aws_access_key_id = aws_access_key_id
|
||||||
self.__aws_access_key = aws_access_key
|
self.__aws_access_key = aws_access_key
|
||||||
self.__aws_bucket = aws_bucket
|
self.__aws_bucket = aws_bucket
|
||||||
|
@ -39,6 +39,7 @@ git_parser.add_argument('--dest-giturl', type=str, required=True)
|
|||||||
git_parser.add_argument('--dest-gitorg', type=str, required=False, default='rpms')
|
git_parser.add_argument('--dest-gitorg', type=str, required=False, default='rpms')
|
||||||
git_parser.add_argument('--dest-branch', type=str, required=False, default='')
|
git_parser.add_argument('--dest-branch', type=str, required=False, default='')
|
||||||
git_parser.add_argument('--release', type=str, required=False, default='')
|
git_parser.add_argument('--release', type=str, required=False, default='')
|
||||||
|
git_parser.add_argument('--preconv-names', action='store_true', help='Convert + to plus first')
|
||||||
git_parser.add_argument('--distprefix', type=str, required=False, default='el')
|
git_parser.add_argument('--distprefix', type=str, required=False, default='el')
|
||||||
git_parser.add_argument('--dest-lookaside', type=str, required=False, default='/var/www/html/sources')
|
git_parser.add_argument('--dest-lookaside', type=str, required=False, default='/var/www/html/sources')
|
||||||
git_parser.add_argument('--upstream-lookaside',
|
git_parser.add_argument('--upstream-lookaside',
|
||||||
|
Loading…
Reference in New Issue
Block a user