slitaz-forge rev 47

taztank: Add profile.php as a file into /usr/share/taztank folder. The current method will not work since dollar sign versions in php are blank.
author Christopher Rogers <slaxemulator@gmail.com>
date Sun Apr 03 04:11:27 2011 +0000 (2011-04-03)
parents 444d36a84ce8
children 5c348f41a718
files tank/Makefile tank/profile.php tank/taztank
line diff
     1.1 --- a/tank/Makefile	Sun Apr 03 00:01:32 2011 +0000
     1.2 +++ b/tank/Makefile	Sun Apr 03 04:11:27 2011 +0000
     1.3 @@ -7,13 +7,15 @@
     1.4  all:
     1.5  
     1.6  install:
     1.7 -	mkdir -p $(DESTDIR)$(PREFIX)/bin
     1.8 +	mkdir -p $(DESTDIR)$(PREFIX)/bin \
     1.9 +		$(DESTDIR)$(PREFIX)/share/taztank
    1.10  	cp -f taztank $(DESTDIR)$(PREFIX)/bin
    1.11 +	cp -f profile.php $(DESTDIR)$(PREFIX)/share/taztank
    1.12  
    1.13  install-files:
    1.14  	cp -a files/var $(DESTDIR)/
    1.15  	chmod 0600 -p $(DESTDIR)/var/spool/cron/crontabs/root
    1.16  	cp -a files/etc $(DESTDIR)/
    1.17 -
    1.18 +	cp -a files/usr $(DESTDIR}/
    1.19  clean:
    1.20  	rm -rf _pkg
     2.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     2.2 +++ b/tank/profile.php	Sun Apr 03 04:11:27 2011 +0000
     2.3 @@ -0,0 +1,13 @@
     2.4 +<?php
     2.5 +
     2.6 +// Your custom SliTaz profile at http://people.slitaz.org/. This file must
     2.7 +// be located at ~/Public/profile.php. You must at least provide your real
     2.8 +// name and you can use the $wall variable for a personnal message.
     2.9 +
    2.10 +$name = "Real Name";
    2.11 +$location = "";
    2.12 +$scn_user = "";
    2.13 +$skills = "";
    2.14 +$wall = "";
    2.15 +
    2.16 +?>
     3.1 --- a/tank/taztank	Sun Apr 03 00:01:32 2011 +0000
     3.2 +++ b/tank/taztank	Sun Apr 03 04:11:27 2011 +0000
     3.3 @@ -140,6 +140,7 @@
     3.4  			echo -e "User $user already exist...\n" && exit 1
     3.5  		fi
     3.6  		echo "Adding user: $user"
     3.7 +		#adduser -s /bin/sh -g "SliTaz User" -G users -h /home/$user $user # for cooking
     3.8  		adduser $user
     3.9  		# HG access
    3.10  		echo -n "Hg password: " && read passwd
    3.11 @@ -159,21 +160,9 @@
    3.12  EOF
    3.13  		# Public profile
    3.14  		mkdir -p /home/$user/Public
    3.15 -		cat > /home/$user/Public/profile.php << EOF
    3.16 -<?php
    3.17 -
    3.18 -// Your custom SliTaz profile at http://people.slitaz.org/. This file must
    3.19 -// be located at ~/Public/profile.php. You must at least provide your real
    3.20 -// name and you can use the $wall variable for a personnal message.
    3.21 -
    3.22 -$name = "Real Name";
    3.23 -$location = "";
    3.24 -$scn_user = "";
    3.25 -$skills = "";
    3.26 -$wall = "";
    3.27 -
    3.28 -?>
    3.29 -EOF
    3.30 +		if [ -f /usr/share/taztank/profile.php ]; then
    3.31 +			cp -a /usr/share/taztank/profile.php /home/$user/Public/profile.php
    3.32 +		fi
    3.33  		# Shell profile
    3.34  		cat > /home/$user/.profile << EOF
    3.35  # ~/.profile: Executed by Bourne-compatible login SHells.