#!/bin/sh ##################################################################################### ### ADD ### ##################################################################################### INDADDALL="n"; ADDANS="n"; for CURRENT in `/opt/subversion/bin/svn st | grep ? | awk -F " " '{print $2}'`; do if [ $INDADDALL = "n" ] then echo "### ADD #####################################################"; echo "??? Are you want to add $CURRENT file ? (y/n/yesall/skip)..."; read ADDANS; fi if [ $ADDANS = "n" ] then echo "!!! $CURRENT...not added!" fi if [ $ADDANS = "yesall" ] then INDADDALL="y"; fi if [ $ADDANS = "skip" ] then break fi if [ $ADDANS = "y" ] then /opt/subversion/bin/svn add $CURRENT #echo "svn add $CURRENT...added!"; fi if [ $INDADDALL = "y" ] then /opt/subversion/bin/svn add $CURRENT #echo "svn add $CURRENT...added!"; fi sleep 1 done ##################################################################################### ### UPDATE ### ##################################################################################### echo "### UPDATE ########################################################"; echo "??? Are you want to UPDATE your working directory..........(y/skip)" read UPDATEANS if [ $UPDATEANS = "y" ] then /opt/subversion/bin/svn update #echo "svn Updated" fi if [ $UPDATEANS = "skip" ] then break fi ##################################################################################### ### COMMIT ### ##################################################################################### echo "### COMMIT #############################################################"; echo "??? Are you want to COMMIT whith a comitment message..........(y/n/skip)" read COMMITANS if [ $COMMITANS = "y" ] then echo "??? Enter your commitment MESSAGE....... " read MSG /opt/subversion/bin/svn commit -m "$MSG_`date +%F`" # echo "svn Commited with message :- $MSG `date +%F`" fi if [ $COMMITANS = "n" ] then /opt/subversion/bin/svn commit -m "without_message_commited_on_`date +%F`" fi if [ $COMMITANS = "skip" ] then break fi
Never been to CodeSnippets before?
Snippets is a public source code repository. Easily build up your personal collection of code snippets, categorize them with tags / keywords, and share them with the world (or not, you can keep them private!)
svn ADD and COMMIT in one command (See related posts)
You need to create an account or log in to post comments to this site.
Related Posts
» Clean Textpattern install fr... in installation textpattern svn
» Forcing an SVN export to ove... in svn export force sitemanagement
» Add all new files to svn rep... in svn
» Using a pre-commit script (w... in svn pre-commit precommit
» Recursively remove all .svn ... in shell svn bash
» knowning how many commits it... in svn subversion
Snippets (source code soon to be available) developed by Peter Cooper and powered by Ruby On Rails