Update to git-1.6.6.1

- Use %{gitcoredir}/git-daemon as xinetd server option, for SELinux
    (#529682)
- Make %{_var}/lib/git the default gitweb projectroot (#556299)
- Include gitweb/INSTALL file as documentation, the gitweb README refers to
    it
- Ship a short example gitweb config file (%{_sysconfdir}/gitweb.conf)
- Remove long fixed xinetd IPv6 workaround on Fedora (#557528)
- Install missing gitweb.js (#558740)
This commit is contained in:
Todd Zullinger 2010-01-31 21:05:27 +00:00
parent 64dae55e57
commit 68affad567
4 changed files with 98 additions and 24 deletions

View File

@ -6,7 +6,7 @@
%endif
Name: git
Version: 1.6.6
Version: 1.6.6.1
Release: 1%{?dist}
Summary: Fast Version Control System
License: GPLv2
@ -14,9 +14,10 @@ Group: Development/Tools
URL: http://git-scm.com/
Source0: http://kernel.org/pub/software/scm/git/%{name}-%{version}.tar.bz2
Source1: git-init.el
Source2: git.xinetd
Source2: git.xinetd.in
Source3: git.conf.httpd
Source4: git-gui.desktop
Source5: gitweb.conf.in
Patch0: git-1.5-gitweb-home-link.patch
# https://bugzilla.redhat.com/490602
Patch1: git-cvsimport-Ignore-cvsps-2.2b1-Branches-output.patch
@ -229,6 +230,7 @@ BLK_SHA1 = 1
ETC_GITCONFIG = %{_sysconfdir}/gitconfig
DESTDIR = %{buildroot}
INSTALL = install -p
GITWEB_PROJECTROOT = %{_var}/lib/git
htmldir = %{_docdir}/%{name}-%{version}
prefix = %{_prefix}
EOF
@ -281,10 +283,12 @@ install -Dpm 644 %{SOURCE1} \
%endif
mkdir -p %{buildroot}%{_var}/www/git
install -pm 644 gitweb/*.png gitweb/*.css %{buildroot}%{_var}/www/git
install -pm 644 gitweb/*.{css,js,png} %{buildroot}%{_var}/www/git
install -pm 755 gitweb/gitweb.cgi %{buildroot}%{_var}/www/git
mkdir -p %{buildroot}/%{_sysconfdir}/httpd/conf.d
install -pm 0644 %{SOURCE3} %{buildroot}/%{_sysconfdir}/httpd/conf.d/git.conf
mkdir -p %{buildroot}%{_sysconfdir}/httpd/conf.d
install -pm 0644 %{SOURCE3} %{buildroot}%{_sysconfdir}/httpd/conf.d/git.conf
sed "s|@PROJECTROOT@|%{_var}/lib/git|g" \
%{SOURCE5} > %{buildroot}%{_sysconfdir}/gitweb.conf
find %{buildroot} -type f -name .packlist -exec rm -f {} ';'
find %{buildroot} -type f -name '*.bs' -empty -exec rm -f {} ';'
@ -304,7 +308,16 @@ rm -rf %{buildroot}%{_mandir}
mkdir -p %{buildroot}%{_var}/lib/git
mkdir -p %{buildroot}%{_sysconfdir}/xinetd.d
install -pm 0644 %{SOURCE2} %{buildroot}%{_sysconfdir}/xinetd.d/git
# On EL <= 5, xinetd does not enable IPv6 by default
enable_ipv6=" # xinetd does not enable IPv6 by default
flags = IPv6"
perl -p \
-e "s|\@GITCOREDIR\@|%{gitcoredir}|g;" \
-e "s|\@BASE_PATH\@|%{_var}/lib/git|g;" \
%if 0%{?rhel} && 0%{?rhel} <= 5
-e "s|^}|$enable_ipv6\n$&|;" \
%endif
%{SOURCE2} > %{buildroot}%{_sysconfdir}/xinetd.d/git
mkdir -p %{buildroot}%{_sysconfdir}/bash_completion.d
install -pm 644 contrib/completion/git-completion.bash %{buildroot}%{_sysconfdir}/bash_completion.d/git
@ -418,15 +431,25 @@ rm -rf %{buildroot}
%files -n gitweb
%defattr(-,root,root)
%doc gitweb/README
%{_var}/www/git/
%doc gitweb/INSTALL gitweb/README
%config(noreplace)%{_sysconfdir}/gitweb.conf
%config(noreplace)%{_sysconfdir}/httpd/conf.d/git.conf
%{_var}/www/git/
%files all
# No files for you!
%changelog
* Tue Jan 26 2010 Todd Zullinger <tmz@pobox.com> - 1.6.6.1-1
- git-1.6.6.1
- Use %%{gitcoredir}/git-daemon as xinetd server option, for SELinux (#529682)
- Make %%{_var}/lib/git the default gitweb projectroot (#556299)
- Include gitweb/INSTALL file as documentation, the gitweb README refers to it
- Ship a short example gitweb config file (%%{_sysconfdir}/gitweb.conf)
- Remove long fixed xinetd IPv6 workaround on Fedora (#557528)
- Install missing gitweb.js (#558740)
* Wed Dec 23 2009 Todd Zullinger <tmz@pobox.com> - 1.6.6-1
- git-1.6.6

View File

@ -1,16 +0,0 @@
# default: off
# description: The git dæmon allows git repositories to be exported using \
# the git:// protocol.
service git
{
disable = yes
socket_type = stream
wait = no
user = nobody
server = /usr/bin/git
server_args = daemon --base-path=/var/lib/git --export-all --user-path=public_git --syslog --inetd --verbose
log_on_failure += USERID
# xinetd doesn't do this by default. bug #195265
flags = IPv6
}

14
git.xinetd.in Normal file
View File

@ -0,0 +1,14 @@
# default: off
# description: The git dæmon allows git repositories to be exported using \
# the git:// protocol.
service git
{
disable = yes
socket_type = stream
wait = no
user = nobody
server = @GITCOREDIR@/git-daemon
server_args = --base-path=@BASE_PATH@ --export-all --user-path=public_git --syslog --inetd --verbose
log_on_failure += USERID
}

53
gitweb.conf.in Normal file
View File

@ -0,0 +1,53 @@
# The gitweb config file is a fragment of perl code. You can set variables
# using "our $variable = value"; text from "#" character until the end of a
# line is ignored. See perlsyn(1) man page for details.
#
# See /usr/share/doc/gitweb-*/README and /usr/share/doc/gitweb-*/INSTALL for
# more details and available configuration variables.
# Set the path to git projects. This is an absolute filesystem path which will
# be prepended to the project path.
#our $projectroot = "@PROJECTROOT@";
# Set the list of git base URLs used for URL to where fetch project from, i.e.
# the full URL is "$git_base_url/$project". By default this is empty
#our @git_base_url_list = qw(git://git.example.com
# ssh://git.example.com@PROJECTROOT@);
# Enable the 'blame' blob view, showing the last commit that modified
# each line in the file. This can be very CPU-intensive. Disabled by default
#$feature{'blame'}{'default'} = [1];
#
# Allow projects to override the default setting via git config file.
# Example: gitweb.blame = 0|1;
#$feature{'blame'}{'override'} = 1;
# Disable the 'snapshot' link, providing a compressed archive of any tree. This
# can potentially generate high traffic if you have large project. Enabled for
# .tar.gz snapshots by default.
#
# Value is a list of formats defined in %known_snapshot_formats that you wish
# to offer.
#$feature{'snapshot'}{'default'} = [];
#
# Allow projects to override the default setting via git config file.
# Example: gitweb.snapshot = tbz2,zip; (use "none" to disable)
#$feature{'snapshot'}{'override'} = 1;
# Disable grep search, which will list the files in currently selected tree
# containing the given string. This can be potentially CPU-intensive, of
# course. Enabled by default.
#$feature{'grep'}{'default'} = [0];
#
# Allow projects to override the default setting via git config file.
# Example: gitweb.grep = 0|1;
#$feature{'grep'}{'override'} = 1;
# Disable the pickaxe search, which will list the commits that modified a given
# string in a file. This can be practical and quite faster alternative to
# 'blame', but still potentially CPU-intensive. Enabled by default.
#$feature{'pickaxe'}{'default'} = [0];
#
# Allow projects to override the default setting via git config file.
# Example: gitweb.pickaxe = 0|1;
#$feature{'pickaxe'}{'override'} = 1;