View | Details | Raw Unified | Return to bug 174860 | Differences between
and this patch

Collapse All | Expand All

(-)files/patch-cmd_commit.in (+67 lines)
Line 0 Link Here
1
--- cmd_commit.in.orig	2009-09-10 04:59:59.000000000 +0900
2
+++ cmd_commit.in	2012-12-31 21:42:13.000000000 +0900
3
@@ -1,6 +1,6 @@
4
 # cmd_commit
5
 # Module for port(1)
6
-# SUMMARY: commit a port into the FreeBSD Ports CVS Repository
7
+# SUMMARY: commit a port into the FreeBSD Ports SVN Repository
8
 #
9
 # $Id: cmd_commit.in,v 1.2 2009/09/09 19:58:30 skolobov Exp $
10
 #
11
@@ -59,13 +59,14 @@
12
 
13
 # Determine if this is a new port
14
 MODE="update"
15
-[ "`grep '\$FreeBSD: ' Makefile`" ] || MODE="new"
16
+svn status Makefile 2>&1 1>/dev/null | grep -qs 'svn: warning: W155007:'
17
+[ $? -eq 0 ] || [ "`grep '\$FreeBSD: ' Makefile`" ] || MODE="new"
18
 
19
 # Run portlint(1) to validate port's sanity
20
 echo "===> Pre-commit portlint check"
21
 FLAGS="-C"
22
 [ "${MODE}" = "new" ] && FLAGS="${FLAGS} -N"
23
-PL_CVS_IGNORE='^\d+$|^pr-patch$|^cvs-msg$' \
24
+PL_SVN_IGNORE='^\d+$|^pr-patch$|^svn-msg$' \
25
 portlint ${FLAGS}
26
 if [ $? -ne 0 ]
27
 then
28
@@ -79,15 +80,12 @@
29
 then
30
 	${PORTSDIR}/Tools/scripts/addport -d `pwd` -u ${FREEFALL_USERNAME}
31
 else
32
-	# Initialize CVS environment
33
-	PCVS="cvs -d ${FREEFALL_USERNAME}@pcvs.FreeBSD.org:/home/pcvs"
34
-
35
 	# Make sure we are working with up-to-date version
36
-	echo "===> Pre-commit CVS update"
37
-	${PCVS} update
38
+	echo "===> Pre-commit SVN update"
39
+	svn update
40
 
41
-	# See if CVS message already exists, and use that for commit log
42
-	MSG="cvs-msg"
43
+	# See if SVN message already exists, and use that for commit log
44
+	MSG="svn-msg"
45
 	FLAGS=""
46
 	if [ -e ${MSG} ]
47
 	then
48
@@ -99,16 +97,16 @@
49
 			echo '============================================='
50
 			cat ${MSG}
51
 			echo '============================================='
52
-			read -p "Is the CVS message above correct? (y/n)" ANSWER
53
+			read -p "Is the SVN message above correct? (y/n)" ANSWER
54
 			[ "${ANSWER}" = "y" ] && break
55
 			${VISUAL:-vi} ${MSG}
56
 		done
57
 	fi 
58
 	# Commit the port update
59
 	echo "===> Committing port update"
60
-	${PCVS} commit ${FLAGS}
61
+	svn commit ${FLAGS}
62
 	
63
-	# Remove CVS message file only if commit was successful
64
+	# Remove SVN message file only if commit was successful
65
 	[ $? -eq 0 -a -e ${MSG} ] && rm ${MSG}
66
 fi
67
 

Return to bug 174860