Git-Url:
http://git.frugalware.org/gitweb/gitweb.cgi?p=frugalware-current.git;a=commitdiff;h=5eab36c9e746e4af35b6fe401580adf73d62dd0c
commit 5eab36c9e746e4af35b6fe401580adf73d62dd0c
Author: Miklos Vajna <[EMAIL PROTECTED]>
Date: Sat Oct 13 19:46:19 2007 +0200
git-1.5.3.4-2-i686
added an init script for git-daemon
diff --git a/source/devel-extra/git/FrugalBuild
b/source/devel-extra/git/FrugalBuild
index b5f9ba0..571f4c2 100644
--- a/source/devel-extra/git/FrugalBuild
+++ b/source/devel-extra/git/FrugalBuild
@@ -6,7 +6,7 @@ USE_DEVEL=${USE_DEVEL:-"n"}
pkgname=git
pkgver=1.5.3.4
Fuse $USE_DEVEL && pkgver=1.5.3.rc7.30.g947ad2
-pkgrel=1
+pkgrel=2
pkgdesc="A fast, scalable, distributed revision control system."
url="http://www.kernel.org/pub/software/scm/git/"
depends=('curl>=7.16.0' 'openssl')
@@ -16,9 +16,9 @@ archs=('i686' 'x86_64')
up2date="lynx -dump '$url/?C=M;O=D'|grep 'git-[0-9.]*.tar.bz2$'|sed -n
's/.*-\(.*\)\.t.*/\1/;1 p'"
if ! Fuse $USE_DEVEL; then
source=($url/$pkgname-$pkgver.tar.bz2)
- signatures=(${source[0]}.sign '' '' '')
+ signatures=(${source[0]}.sign '' '' '' '' '')
fi
-source=([EMAIL PROTECTED] gitweb.modules.d gitweb.conf README.Frugalware)
+source=([EMAIL PROTECTED] gitweb.modules.d gitweb.conf README.Frugalware
rc.git git.sysconfig)
options=('scriptlet')
subpkgs=('gitweb' 'git-gui' 'gitk')
@@ -77,6 +77,10 @@ build()
Fsplit gitweb /etc /var
Fdoc README.Frugalware
+ # git-daemon
+ Ffile git.sysconfig /etc/sysconfig/git
+ Fexe /etc/rc.d/rc.git
+
# git-gui
Fsplit git-gui usr/bin/git-{gui,citool}
Fsplit git-gui usr/share/git-gui
diff --git a/source/devel-extra/git/git.sysconfig
b/source/devel-extra/git/git.sysconfig
new file mode 100644
index 0000000..324b90c
--- /dev/null
+++ b/source/devel-extra/git/git.sysconfig
@@ -0,0 +1,18 @@
+#
+# /etc/sysconfig/git
+#
+# confiugation file for the git daemon
+#
+
+# remap all the path requests as relative to this path
+BASE_PATH="/home/ftp"
+
+# allow pulling from all directories that look like git repositories, even if
+# they do not have the git-daemon-export-ok file
+EXPORT="--export-all"
+
+# translate ~user to $HOME/git/public
+USER_PATH="--user-path=git/public"
+
+# the fun part
+GIT_OPTIONS="--reuseaddr --base-path=$BASE_PATH $EXPORT $USER_PATH --detach
--pid-file=/var/run/gitd.pid"
diff --git a/source/devel-extra/git/rc.git b/source/devel-extra/git/rc.git
new file mode 100644
index 0000000..a4f3d24
--- /dev/null
+++ b/source/devel-extra/git/rc.git
@@ -0,0 +1,43 @@
+#!/bin/bash
+
+# (c) 2007 Miklos Vajna <[EMAIL PROTECTED]>
+# rc.git for Frugalware
+# distributed under GPL License
+
+# chkconfig: 2345 99 01
+# description: Git daemon
+
+source /lib/initscripts/functions
+TEXTDOMAIN=git
+TEXTDOMAINDIR=/lib/initscripts/messages
+
+actions=(restart status start stop)
+daemon=$"GIT daemon"
+
+pid="cat /var/run/gitd.pid 2> /dev/null" # Change me! :)
+source /etc/sysconfig/git
+
+rc_start()
+{
+ start_msg
+ if [[ "$(eval $pid)" == "" ]] ; then
+ git daemon $GIT_OPTIONS
+ ok $?
+ else
+ ok 999
+ fi
+}
+
+rc_stop()
+{
+ stop_msg
+ if [[ "$(eval $pid)" != "" ]] ; then
+ kill $(eval $pid)
+ ok $?
+ rm /var/run/gitd.pid
+ else
+ ok 999
+ fi
+}
+
+rc_exec $1
_______________________________________________
Frugalware-git mailing list
[email protected]
http://frugalware.org/mailman/listinfo/frugalware-git