Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #!/bin/sh
- if [ $# = 0 ]
- then
- cat << END_MY-BALL > my-ball.sh
- cat << TAG_CAT > my-id.txt
- NOM
- Prénom
- adresse@mail.com
- TAG_CAT
- END_MY-BALL
- elif [ $# = 1 ]
- then
- if [ -f $1 ]
- then
- cat << END_MY-BALL > my-ball.sh
- cat $1 > "$1.recreated"
- END_MY-BALL
- else
- echo "$1 : Introuvable"
- exit 1
- fi
- else
- echo "Ce programme n'accepte qu'un seul paramètre au maximum !"
- exit 1
- fi
- chmod 755 my-ball.sh
- ./my-ball.sh
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement