Created
February 13, 2018 19:49
-
-
Save olafkrueger/e43adc982b3a03e94169d05aa7df5ee4 to your computer and use it in GitHub Desktop.
Just a little bash test
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Just a very little bash test | |
echo "What is your name? [ENTER]:" | |
read name | |
echo "How old are you? [ENTER]:" | |
read age | |
if [ $age -gt 45 ]; then | |
echo "$name, you are too old for this stuff." | |
else | |
echo "$name, there's little chance that you'll get it!." | |
fi | |
echo "Name:" $name > test.txt | |
echo "Age:" $age >> test.txt | |
echo "It works!" >> test.txt |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment