Reputation: 3321
I am new to Shell scripting.
Can anyone tell me what should I do in the script below, so that instead of taking the date/time as a parameter for git commit, it actually prompts me to enter the comment ?
#!/bin/bash
TODAY=$(date)
.............
.............
git commit -m "$TODAY"
............
............
Upvotes: 0
Views: 151
Reputation: 1401
#!/bin/bash
echo "Type the date, followed by [ENTER]:"
read TODAY
git commit -m "$TODAY"
Upvotes: 2