Skip to content

Instantly share code, notes, and snippets.

View utsav00's full-sized avatar
🎯
Focusing

Utsav utsav00

🎯
Focusing
View GitHub Profile
@rohitkg98
rohitkg98 / daily_log.sh
Created January 3, 2020 17:27
A Script to maintain logs for everyday.
#!/bin/bash
# Check if DAILYLOG_DIR exists.
if [[ ! -z $DAILYLOG_DIR ]]; then
echo "Creating a new log at" "$DAILYLOG_DIR"
else
echo "Please enter directory to store logs:"
# tput is used to set colour and bold font - experimental turns all text to bold red
# trap 'echo -e $(tput bold)$(tput setaf 196)"NOTE: Path should be relative from ~/ i.e. home"' DEBUG
echo -e "NOTE: Path should be relative from ~/ i.e. home"