[git-review/el6] Update to 1.24
Pete Zaitcev
zaitcev at fedoraproject.org
Sat Mar 7 01:59:24 UTC 2015
commit 4d621c6b7cb4a26a42d0c2245bce3e075505fefc
Author: Pete Zaitcev <zaitcev at kotori.zaitcev.us>
Date: Fri Mar 6 18:58:39 2015 -0700
Update to 1.24
This is a big step for RHEL 6, but should be fine. It was in use
in Fedora for a while.
Keeping Requires: python-argparse.
.gitignore | 1 +
git-review-1.24-main.patch | 48 +++++++++++++++++++
git-review-1.24-man.patch | 113 +++++++++++++++++++++++++++++++++++++++++++++
git-review.spec | 58 +++++++++++++++++------
sources | 2 +-
5 files changed, 208 insertions(+), 14 deletions(-)
---
diff --git a/.gitignore b/.gitignore
index 140e9ac..d77315d 100644
--- a/.gitignore
+++ b/.gitignore
@@ -2,3 +2,4 @@
/openstack-ci-git-review-1.15-0-gf719a31.tar.gz
/openstack-ci-git-review-1.16-0-gda19131.tar.gz
/openstack-ci-git-review-1.17-0-g776e800.tar.gz
+/git-review-1.24.tar.gz
diff --git a/git-review-1.24-main.patch b/git-review-1.24-main.patch
new file mode 100644
index 0000000..e64ddfb
--- /dev/null
+++ b/git-review-1.24-main.patch
@@ -0,0 +1,48 @@
+(cherry-picked with corrections)
+
+commit 856ccd958bd4c47158aae574b6211f7da2b57be7
+Author: Cedric Brandily <zzelle at gmail.com>
+Date: Thu Sep 4 14:24:59 2014 +0200
+
+ Align git-review and python -m git_review.cmd behaviors
+
+ Currently, python -m git_review.cmd wraps git_review.cmd.main call to
+ handle correctly unicode in python2 where git-review calls directly
+ git_review.cmd.main. This change embeds the wrapper inside main in
+ order to align git-review and python -m git_review.cmd behaviors.
+
+ Change-Id: I390e2d68b851299c3b07292b89dee8198068e6aa
+
+diff --git a/git_review/cmd.py b/git_review/cmd.py
+index a1c655a..2619989 100755
+--- a/git_review/cmd.py
++++ b/git_review/cmd.py
+@@ -1033,7 +1043,7 @@ def convert_bool(one_or_zero):
+ return one_or_zero in ["1", "true", "True"]
+
+
+-def main():
++def _main():
+ usage = "git review [OPTIONS] ... [BRANCH]"
+
+ import argparse
+@@ -1256,9 +1262,9 @@ def main():
+ sys.exit(status)
+
+
+-if __name__ == "__main__":
++def main():
+ try:
+- main()
++ _main()
+ except GitReviewException as e:
+ # If one does unguarded print(e) here, in certain locales the implicit
+ # str(e) blows up with familiar "UnicodeEncodeError ... ordinal not in
+@@ -1269,3 +1277,7 @@ if __name__ == "__main__":
+ else:
+ print(u.encode('utf-8'))
+ sys.exit(e.EXIT_CODE)
++
++
++if __name__ == "__main__":
++ main()
diff --git a/git-review-1.24-man.patch b/git-review-1.24-man.patch
new file mode 100644
index 0000000..7bd181b
--- /dev/null
+++ b/git-review-1.24-man.patch
@@ -0,0 +1,113 @@
+--- 1/xxx.1 2014-12-03 22:50:21.318837161 -0700
++++ 2/git-review.1 2014-12-03 22:49:44.698420742 -0700
+@@ -63,7 +63,7 @@
+ In that case local branch name will have a \-patch[patchsetNumber] suffix.
+ .Pp
+ The following options are available:
+-.Bl \-tag \-width indent
++.Bl -tag -width indent
+ .It Fl d Ar change , Fl \-download= Ns Ar change
+ Download
+ .Ar change
+@@ -165,7 +165,7 @@
+ This utility can be configured by adding entries to Git configuration.
+ .Pp
+ The following configuration keys are supported:
+-.Bl \-tag
++.Bl -tag
+ .It gitreview.username
+ Default username used to access the repository. If not specified
+ in the Git configuration, Git remote or
+@@ -175,7 +175,7 @@
+ Example entry in the
+ .Pa .gitconfig
+ file:
+-.Bd \-literal \-offset indent
++.Bd -literal -offset indent
+ [gitreview]
+ username=\fImygerrituser\fP
+ .Ed
+@@ -184,7 +184,7 @@
+ be rebased to the newest state of the branch.
+ .Pp
+ A value of 'true' or 'false' should be specified.
+-.Bl \-tag
++.Bl -tag
+ .It false
+ Do not rebase changes on submit \- equivalent to setting
+ .Fl R
+@@ -208,7 +208,7 @@
+ a file at the root of the repository named
+ .Pa .gitreview
+ and place information about your gerrit installation in it. The format is similar to the Windows .ini file format:
+-.Bd \-literal \-offset indent
++.Bd -literal -offset indent
+ [gerrit]
+ host=\fIhostname\fP
+ port=\fITCP port number of gerrit\fP
+@@ -228,7 +228,7 @@
+ not to rebase changes by default (same as the
+ .Fl R
+ command line option)
+-.Bd \-literal \-offset indent
++.Bd -literal -offset indent
+ [gerrit]
+ host=review.example.com
+ port=29418
+@@ -243,7 +243,7 @@
+ Normally, exit status is 0 if executed successfully.
+ Exit status 1 indicates general error, sometimes more
+ specific error codes are available:
+-.Bl \-tag \-width 999
++.Bl -tag -width 999
+ .It 2
+ Gerrit
+ .Ar commit\-msg
+@@ -289,14 +289,14 @@
+ communication with Gerrit or remote Git repository,
+ exit status larger than 63 means there was a problem with
+ a local repository or a working copy.
+-
++.Pp
+ Exit status larger than or equal to 128 means internal
+ error in running the "git" command.
+ .Pp
+ .Sh EXAMPLES
+ To fetch a remote change number 3004:
+ .Pp
+-.Bd \-literal \-offset indent
++.Bd -literal -offset indent
+ $ git\-review \-d 3004
+ Downloading refs/changes/04/3004/1 from gerrit into
+ review/someone/topic_name
+@@ -311,7 +311,7 @@
+ .Pp
+ To fetch a remote patchset number 5 from change number 3004:
+ .Pp
+-.Bd \-literal \-offset indent
++.Bd -literal -offset indent
+ $ git\-review \-d 3004,5
+ Downloading refs/changes/04/3004/5 from gerrit into
+ review/someone/topic_name\-patch5
+@@ -322,10 +322,10 @@
+ .Ed
+ .Pp
+ To send a change for review and delete local branch afterwards:
+-.Bd \-literal \-offset indent
++.Bd -literal -offset indent
+ $ git\-review \-f
+ remote: Resolving deltas: 0% (0/8)
+-To ssh://username@review.example.com/departement/project.git
++To ssh://username@review.example.com/department/project.git
+ * [new branch] HEAD \-> refs/for/master/topic_name
+ Switched to branch 'master'
+ Deleted branch 'review/someone/topic_name'
+@@ -344,7 +344,7 @@
+ in the branch
+ .Cm master
+ :
+-.Bd \-literal \-offset indent
++.Bd -literal -offset indent
+ [gerrit]
+ host=review.example.com
+ port=29418
diff --git a/git-review.spec b/git-review.spec
index 60567dc..4b1ba7a 100644
--- a/git-review.spec
+++ b/git-review.spec
@@ -1,30 +1,34 @@
Name: git-review
-Version: 1.17
-Release: 2%{?dist}
-Summary: A git helper for integration with Gerrit
+Version: 1.24
+Release: 4%{?dist}
+Summary: A Git helper for integration with Gerrit
Group: Development/Tools
License: ASL 2.0
-URL: https://github.com/openstack-ci/git-review
-# Source URL is https://github.com/openstack-ci/git-review/tarball/{version},
-# which produces Content-Disposition: attachment; filename=XXXXXX.tar.gz.
-# But wait! The extracted directory name is different from tarball name.
-Source0: openstack-ci-git-review-1.17-0-g776e800.tar.gz
+URL: https://github.com/openstack-infra/git-review
+Source0: http://tarballs.openstack.org/git-review/git-review-%{version}.tar.gz
Source1: git-review.conf
+Patch1: git-review-1.24-man.patch
+Patch2: git-review-1.24-main.patch
BuildArch: noarch
BuildRequires: python2-devel
+BuildRequires: python-pbr
BuildRequires: python-setuptools
Requires: git
Requires: python-argparse
+Requires: python-requests
%description
-An extension for source control system git that creates and manages review
+An extension for source control system Git that creates and manages review
requests in the patch management system Gerrit. It replaces the rfc.sh script.
%prep
-%setup -q -n openstack-ci-git-review-776e800
+%setup -q
+
+%patch1 -p1
+%patch2 -p1
%build
%{__python} setup.py build
@@ -40,6 +44,8 @@ cp %{SOURCE1} %{buildroot}%{_sysconfdir}/git-review/
# We do not save ".gitreview" as dot.gitreview because the man page has it too.
# cp .gitreview #{buildroot}/usr/share/doc/dot.gitreview
+install -p -m 0644 -D git-review.1 %{buildroot}%{_mandir}/man1/git-review.1
+
%clean
rm -rf %{buildroot}
@@ -48,16 +54,42 @@ rm -rf %{buildroot}
%{_bindir}/git-review
%{_mandir}/man1/git-review.1.gz
# Our package name is git-review, but setup.py installs with underscore.
-#{python_sitelib}/#{name}-#{version}-*.egg-info/
+%{python_sitelib}/git_review/
%{python_sitelib}/git_review-%{version}-*.egg-info/
+
%dir %{_sysconfdir}/git-review/
%config(noreplace) %{_sysconfdir}/git-review/git-review.conf
# License is required in percent-doc according to Packaging:LicensingGuidelines
%doc AUTHORS LICENSE
-# How about transforming README.md into HTML or something?
-%doc README.md
+%doc README.rst
%changelog
+* Thu Feb 05 2015 Pete Zaitcev <zaitcev at redhat.com> - 1.24-4
+- Catch internal exceptions properly, avoid tripping abrtd (#1188913)
+
+* Thu Dec 11 2014 Pete Zaitcev <zaitcev at redhat.com> - 1.24-3
+- Fix up the man page (#1170410)
+
+* Tue Nov 11 2014 Pete Zaitcev <zaitcev at redhat.com> - 1.24-2
+- Require python-requests (#1162709)
+
+* Wed Oct 29 2014 Pete Zaitcev <zaitcev at redhat.com> - 1.24-1
+- Upstream 1.24: better deal w/ proxies, https; bugfixes (e.g. unicode crash)
+- Checking for updates is out, other configuration options are in
+
+* Fri Aug 09 2013 Pete Zaitcev <zaitcev at redhat.com>
+- 1.22-1
+- Upstream 1.22: per-user configurations, tweaks to gerrit branch search
+
+* Thu Mar 21 2013 Pete Zaitcev <zaitcev at redhat.com>
+- 1.20-0.1
+- Upstream 1.20: can have a file called "HEAD"; add -d option
+- Patch the breakage with manpage in setup.py (temporarily - upstream pending)
+
+* Thu Sep 13 2012 Pete Zaitcev <zaitcev at redhat.com>
+- 1.18-1
+- Upstream 1.18: list actions
+
* Thu Aug 2 2012 Pete Zaitcev <zaitcev at redhat.com>
- 1.17-2
- Add Requires: python-argparse for el6 per Trond Amundsen, bz#840826
diff --git a/sources b/sources
index dae3118..9bed851 100644
--- a/sources
+++ b/sources
@@ -1 +1 @@
-f2b343a5eeba9b43ff705146143f449b openstack-ci-git-review-1.17-0-g776e800.tar.gz
+537c78591e74853c204c5b3d88c0c4fd git-review-1.24.tar.gz
More information about the scm-commits
mailing list