Grok wrote this command for me that I put in ~/.local/bin named fileinfo. But you can name it whatever you want. It gives useful information on a file by running three commands at once.
for file in "$@"; do
ls -gtrahs --time-style=+%Y_%a_%r_%D --group-directories-first --color=always "$file"
realpath "$file"
file --mime-type "$file"
done
ls, realpath and file.
The second command is da for "disattach" its like & after an argument but better
da firefox
da mpv
da gimp
and it prevents the terminally from being attached to the process way better then `gimp &` or `firefox &`. Its adding a dev null at the end of everything.
if [ $# -eq 0 ]; then
echo "Usage: da <command> [arguments...]" >&2
exit 1
fi
# Run detached + completely silent
"$@" > /dev/null 2>&1 &
# Optional: small feedback
#echo " $1 launched in background (silent)"
da is really useful because it almost never leaves terminal output where as & does.
All Grok did is expose Unix commands in a way that makes them work for me and I love it. So go ahead and call me a loser for asking AI to make my life easier. I hate Musk but like Grok