DIR : /home/kozerus/public_html/ka/fb2dirs.sh

/home/kozerus/public_html/ka

# fb2dirs.sh

progid="fb2dirs.sh"
dttm=`date +"%Y%m%d_%H%M%S"`
yyyymmdd=`date +"%Y%m%d"`


dirs=`find ./fb -type d -maxdepth 3 | grep -v "pages"`
dirs=`find ./fb -type d -maxdepth 3 -name "smekal" | grep -v "pages"`

	if [ "$1" == "" ]; then
		echo "dirs=$dirs"
		echo ""
		echo "$progid $dttm"
		echo "./$progid vi" 
		echo ""
		echo "./$progid go" 
		echo "./$progid go go"
		echo ""
		echo "./$progid fb" 
		echo "./$progid fb go"
		echo " "
		echo "./$progid pg" 
		echo "./$progid pg go"
		exit
		fi
	if [ "$1" == "vi" ]; then
		if [ -f $progid ]; then vi $progid
		else 
			echo "ERR NOTFOUND progid=$progid"
			fi
		exit
		fi	


	if [ "$1" == "go" ] || [ "$1" == "fb" ]; then
		j=0; k=0;
		for dir in $dirs; do
			let j=j+1

			echo "$j cp fb.html $dir/fb.html"
			echo "$j cp fb.html $dir/index.html"
			echo "$j cp fb.html $dir/index.htm"


			if [ "$2" == "go" ]; then
				cp fb.html $dir
				cp fb.html $dir/index.html
				cp fb.html $dir/index.htm
				fi
			done
		exit
		fi

	if [ "$1" == "go" ] || [ "$1" == "pg" ]; then
		j=0; k=0;
		for dir in $dirs; do
			let j=j+1
			if [ -d $dir/pages ]; then
				echo "BUGS ___FOUND $dir/pages"
				find $dir/pages -maxdepth 1 -type f -name "?.*"  | sed -e "s:$dir:.:" 
				find $dir/pages -maxdepth 1 -type f -name "??.*"  | sed -e "s:$dir:.:"
				find $dir/pages -maxdepth 1 -type f -name "???.*"  | sed -e "s:$dir:.:"
			else
				echo "BUGS NOTFOUND $dir/pages"
				fi


			if [ "$2" == "go" ]; then
				if [ -d $dir/pages ]; then
				
					echo "BUGS ___FOUND $dir/pages"
					if [ ! -f $dir/pages.txt ]; then
						echo "BUGS NOTFOUND $dir/pages.txt"
						find $dir/pages -maxdepth 1 -type f -name "?.*"  | sed -e "s:$dir:.:" > $dir/pages.txt
						find $dir/pages -maxdepth 1 -type f -name "??.*"  | sed -e "s:$dir:.:" >> $dir/pages.txt
						find $dir/pages -maxdepth 1 -type f -name "???.*"  | sed -e "s:$dir:.:" >> $dir/pages.txt
					else
						echo "BUGS ___FOUND $dir/pages"
						fi
				else
					echo "BUGS NOTFOUND $dir/pages"
					fi
				fi
			done
		exit
		fi

//


koh5_pano



Your browser does not support the HTML5 canvas element.


Drag mouse to navigate.

Navigation





17.Aug.2010, Martin Wengenmayer