Blame SOURCES/50-copy-files

9613bd
function installFile() {
9613bd
	if [ -d $1 ]
9613bd
	then	source='--directory'
9613bd
		msg="Dir. $2"
9613bd
	else 	source=$1
9613bd
		msg="File $2"
9613bd
	fi
9613bd
	owner=$(stat --format %u $1)
9613bd
	group=$(stat --format %g $1)
9613bd
	perms=$(stat --format %a $1)
9613bd
	install \
9613bd
		--mode  $perms \
9613bd
		--owner $owner \
9613bd
		--group $group \
9613bd
		$source $2 && echo $msg
9613bd
}
9613bd
9613bd
find register.content -mindepth 2 -print | while read source
9613bd
do
9613bd
  dest=${source/register.content/}
9613bd
  installFile $source $dest
9613bd
done
9613bd