diff options
| author | Łukasz Gardoń <garjack555@gmail.com> | 2017-08-08 10:18:11 +0200 |
|---|---|---|
| committer | Łukasz Gardoń <garjack555@gmail.com> | 2017-08-23 14:06:14 +0200 |
| commit | bed59cec5e5a9a5668cf2c7df3a24545b1e76c09 (patch) | |
| tree | f7569ff48632187517e5df8dd2d3cb5850691593 /project.py | |
| parent | c94d6eb90233421b431adbd5a01b7ec24729a285 (diff) | |
| download | git-repo-bed59cec5e5a9a5668cf2c7df3a24545b1e76c09.tar.gz | |
Add option '--no-cert-checks' for 'upload' sub command.
This option allow to bypass verification ssl certification while
establishing connection with Gerrit to upload review.
Change-Id: If2e15f5a273c18a700eb5093ca8a4d5a4cbf80cd
Diffstat (limited to 'project.py')
| -rw-r--r-- | project.py | 11 |
1 files changed, 7 insertions, 4 deletions
| @@ -178,14 +178,16 @@ class ReviewableBranch(object): | |||
| 178 | draft=False, | 178 | draft=False, |
| 179 | private=False, | 179 | private=False, |
| 180 | wip=False, | 180 | wip=False, |
| 181 | dest_branch=None): | 181 | dest_branch=None, |
| 182 | validate_certs=True): | ||
| 182 | self.project.UploadForReview(self.name, | 183 | self.project.UploadForReview(self.name, |
| 183 | people, | 184 | people, |
| 184 | auto_topic=auto_topic, | 185 | auto_topic=auto_topic, |
| 185 | draft=draft, | 186 | draft=draft, |
| 186 | private=private, | 187 | private=private, |
| 187 | wip=wip, | 188 | wip=wip, |
| 188 | dest_branch=dest_branch) | 189 | dest_branch=dest_branch, |
| 190 | validate_certs=validate_certs) | ||
| 189 | 191 | ||
| 190 | def GetPublishedRefs(self): | 192 | def GetPublishedRefs(self): |
| 191 | refs = {} | 193 | refs = {} |
| @@ -1113,7 +1115,8 @@ class Project(object): | |||
| 1113 | draft=False, | 1115 | draft=False, |
| 1114 | private=False, | 1116 | private=False, |
| 1115 | wip=False, | 1117 | wip=False, |
| 1116 | dest_branch=None): | 1118 | dest_branch=None, |
| 1119 | validate_certs=True): | ||
| 1117 | """Uploads the named branch for code review. | 1120 | """Uploads the named branch for code review. |
| 1118 | """ | 1121 | """ |
| 1119 | if branch is None: | 1122 | if branch is None: |
| @@ -1138,7 +1141,7 @@ class Project(object): | |||
| 1138 | branch.remote.projectname = self.name | 1141 | branch.remote.projectname = self.name |
| 1139 | branch.remote.Save() | 1142 | branch.remote.Save() |
| 1140 | 1143 | ||
| 1141 | url = branch.remote.ReviewUrl(self.UserEmail) | 1144 | url = branch.remote.ReviewUrl(self.UserEmail, validate_certs) |
| 1142 | if url is None: | 1145 | if url is None: |
| 1143 | raise UploadError('review not configured') | 1146 | raise UploadError('review not configured') |
| 1144 | cmd = ['push'] | 1147 | cmd = ['push'] |
