[Frugalware-darcs] pacman-tools: repoman: git support in srcdel()

VMiklos vmiklos at frugalware.org
Sat Jun 30 18:39:49 CEST 2007


Darcsweb-Url: http://darcs.frugalware.org/darcsweb/darcsweb.cgi?r=pacman-tools;a=darcs_commitdiff;h=20070630163352-e2957-df83eb245f62a47dbb827376c18551affe7c1bea.gz;

[repoman: git support in srcdel()
VMiklos <vmiklos at frugalware.org>**20070630163352] {
hunk ./bumppkg 67
-		for i in `git status .|sed '1,/Untracked files:/d;/^\(#[^\t].\|^[^#]\)/d;s/^#\t\?//'`
-		do
-			rm -rfv $root/$i
-		done
+		git clean .
hunk ./repoman 294
-	if [ "$F_makepkg_scm" = "git" ]; then
-		echo "srcdel() not yet supported" # FIXME
-		return
-	fi
+	mydir=$(pwd|sed "s|$(get_root)||")
hunk ./repoman 305
+	if [ "$F_makepkg_scm" = "git" ]; then
+		check_servers
+		for i in $(ssh $host "cd $path/$mydir; git clean -n ."|sed 's/.* remove //')
+		do
+			if ! echo ${srclocal[@]} |grep -q $i && ! _is_log $i && [ "$i" != "Changelog" ]; then
+				dry_run delete $mydir/$i
+			fi
+		done
+	else
hunk ./repoman 315
-	mydir=$(pwd|sed "s|$(_get_root)||")
hunk ./repoman 333
+	fi
}


More information about the Frugalware-darcs mailing list