I just realized that you can run a command at login by appending it to your .bashrc

For instance, I added a curl pointing to a certain address that immediately upon login returns a message that tells me whether I’m connected to my VPN provider or not.

Sorry for the beginner revelation. Just thought it was cool. :3

  • rockSlayer@lemmy.blahaj.zone
    link
    fedilink
    English
    arrow-up
    3
    ·
    4 hours ago

    Help explain this to me. I was under the impression that non-interactive shells are what happens when you execute a bash script, right? When I ssh into the head node of a compute cluster at work (so non-login, I assume) and run a script, why don’t my aliases get recognized and only accepts $BASH_ENV? According to this chart, they should get recognized