I'd like to achieve this: 1) When user (anybody) logs in to tty1, then some specific command(s) will run automatically. 2) When user (anybody) logs in to other tty, then no command(s) will run automatically.
For example: When I log in to tty1, free
command will run.
I put the commands into .profile
file, but it applies to all tty.
Is there any solution how to make this possible?
Thank you
df
and couple other commands myself. Good way to go, although note that[[
is specific to bash – Sergiy Kolodyazhnyy Jul 28 '17 at 09:49