HEX
Server: Apache
System: Linux msm5694.mjhst.com 3.10.0-1160.119.1.el7.x86_64 #1 SMP Tue Jun 4 14:43:51 UTC 2024 x86_64
User: camjab_ssh (1000)
PHP: 5.3.29
Disabled: NONE
Upload Files
File: //usr/share/doc/dialog-1.2/samples/rotated-data
#!/bin/sh
# $Id: rotated-data,v 1.1 2004/12/19 16:43:47 tom Exp $
# Rotate the second parameter's data by the given shift count.
if test $# != 0
then
	case $1 in
	[1-9]*)
		left=$1
		next=`expr $left + 1`
		shift 1
		;;
	*)
		left=1
		next=2
		;;
	esac
	char=`echo "$@" | cut -b -${left}`
	data=`echo "$@" | cut -b ${next}-`

	printf "%s%s\n" $data $char
else
	echo
fi