tidy proclaim
This commit is contained in:
parent
5552b43133
commit
c0d67e2cc8
1 changed files with 3 additions and 6 deletions
9
proclaim
9
proclaim
|
@ -6,16 +6,13 @@ timezone=UTC
|
||||||
chatlog=/var/log/bunkchat/chat.log
|
chatlog=/var/log/bunkchat/chat.log
|
||||||
prompt=""
|
prompt=""
|
||||||
|
|
||||||
makeSlug () {
|
makeprompt() {
|
||||||
# make time and date
|
|
||||||
time=$(TZ=${timezone} date +%I:%M%p)
|
time=$(TZ=${timezone} date +%I:%M%p)
|
||||||
date=$(TZ=${timezone} date +%m/%d)
|
date=$(TZ=${timezone} date +%m/%d)
|
||||||
|
|
||||||
# make name/time string
|
|
||||||
prompt="${username}-${date}-${time}"
|
prompt="${username}-${date}-${time}"
|
||||||
}
|
}
|
||||||
|
|
||||||
# enter bunkchat mode (clear the screen)
|
# enter ~bunkchat mode~ (clear the screen)
|
||||||
clear
|
clear
|
||||||
|
|
||||||
while true
|
while true
|
||||||
|
@ -29,7 +26,7 @@ do
|
||||||
echo "----------------------------------"
|
echo "----------------------------------"
|
||||||
printf "speak to the server: "
|
printf "speak to the server: "
|
||||||
read -r text
|
read -r text
|
||||||
makeSlug
|
makeprompt
|
||||||
echo "${prompt}: $text" >> $chatlog
|
echo "${prompt}: $text" >> $chatlog
|
||||||
clear
|
clear
|
||||||
done
|
done
|
||||||
|
|
Loading…
Reference in a new issue