* enhanced ProjectModel->create() to remove dependency on the external script 'repo.sh'
* enhanced the code_folder view to display properties. * fixed a minor bug in the code_history view. * got rid of websvn totally.
This commit is contained in:
@ -1,7 +1,7 @@
|
||||
|
||||
cfgdir=$(CFGDIR)
|
||||
cfg_DATA = codepot.ini codepot.sql codepot.a2ldap
|
||||
cfg_SCRIPTS = repo.sh start-commit pre-commit post-commit
|
||||
cfg_SCRIPTS = start-commit pre-commit post-commit
|
||||
|
||||
EXTRA_DIST = $(cfg_DATA) $(cfg_SCRIPTS)
|
||||
|
||||
|
@ -169,7 +169,7 @@ top_builddir = @top_builddir@
|
||||
top_srcdir = @top_srcdir@
|
||||
wwwdir = @wwwdir@
|
||||
cfg_DATA = codepot.ini codepot.sql codepot.a2ldap
|
||||
cfg_SCRIPTS = repo.sh start-commit pre-commit post-commit
|
||||
cfg_SCRIPTS = start-commit pre-commit post-commit
|
||||
EXTRA_DIST = $(cfg_DATA) $(cfg_SCRIPTS)
|
||||
all: all-am
|
||||
|
||||
|
@ -41,11 +41,6 @@ ldap_admin_password = ""
|
||||
;------------------------------------------------------------------------------
|
||||
language = "auto"
|
||||
|
||||
;------------------------------------------------------------------------------
|
||||
; Use websvn as a repository browser.
|
||||
;------------------------------------------------------------------------------
|
||||
enable_websvn = "no"
|
||||
|
||||
;------------------------------------------------------------------------------
|
||||
; When set to yes, viewing pages require a user to sign in.
|
||||
;------------------------------------------------------------------------------
|
||||
|
@ -1,83 +0,0 @@
|
||||
#!/bin/sh
|
||||
|
||||
make_repo() {
|
||||
local repodir="$1"
|
||||
local reponame="$2"
|
||||
local cfgdir="$3"
|
||||
local api="$4"
|
||||
|
||||
echo "${reponame}" | grep -qF '/' && {
|
||||
echo "ERROR: invalid repository name - ${reponame}"
|
||||
return 1
|
||||
}
|
||||
|
||||
mkdir -p "${repodir}" >/dev/null 2>&1 || {
|
||||
echo "ERROR: cannot create directory - ${repodir}"
|
||||
return 1
|
||||
}
|
||||
|
||||
[ -d "${repodir}" -a -w "${repodir}" -a -x "${repodir}" ] || {
|
||||
echo "ERROR: directory set with wrong permission - ${repodir}"
|
||||
return 1;
|
||||
}
|
||||
|
||||
#[ -f "${repodir}/start-commit" ] || {
|
||||
sed "s|%API%|${api}|g" "${cfgdir}/start-commit" > "${repodir}/start-commit" || {
|
||||
echo "ERROR: cannot install start-commit to ${repodir}"
|
||||
return 1;
|
||||
}
|
||||
chmod 0755 "${repodir}/start-commit"
|
||||
#}
|
||||
|
||||
#[ -f "${repodir}/pre-commit" ] || {
|
||||
# sed "s|%API%|${api}|g" "${cfgdir}/pre-commit" > "${repodir}/pre-commit" || {
|
||||
# echo "ERROR: cannot install pre-commit to ${repodir}"
|
||||
# return 1;
|
||||
# }
|
||||
# chmod 0755 "${repodir}/pre-commit"
|
||||
#}
|
||||
|
||||
#[ -f "${repodir}/post-commit" ] || {
|
||||
sed "s|%API%|${api}|g" "${cfgdir}/post-commit" > "${repodir}/post-commit" || {
|
||||
echo "ERROR: cannot install post-commit to ${repodir}"
|
||||
return 1;
|
||||
}
|
||||
chmod 0755 "${repodir}/post-commit"
|
||||
#}
|
||||
|
||||
#svnadmin create "${repodir}/${reponame}" && {
|
||||
oldpwd="`pwd`"
|
||||
cd "${repodir}/${reponame}/hooks"
|
||||
ln -sf ../../start-commit start-commit
|
||||
ln -sf ../../post-commit post-commit
|
||||
cd "${oldpwd}"
|
||||
#}
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
delete_repo() {
|
||||
local repodir="$1"
|
||||
local reponame="$2"
|
||||
|
||||
echo "${reponame}" | grep -qF '/' && {
|
||||
echo "ERROR: invalid repository name - ${reponame}"
|
||||
return 1
|
||||
}
|
||||
|
||||
rm -rf "${repodir}/${reponame}"
|
||||
}
|
||||
|
||||
|
||||
case $1 in
|
||||
make)
|
||||
make_repo "$2" "$3" "$4" "$5"
|
||||
;;
|
||||
delete)
|
||||
delete_repo "$2" "$3"
|
||||
;;
|
||||
*)
|
||||
exit 1
|
||||
;;
|
||||
esac
|
||||
|
Reference in New Issue
Block a user