Automatic script which runs after open terminal [closed]

The name of the pictureThe name of the pictureThe name of the pictureClash Royale CLAN TAG#URR8PPP











up vote
-1
down vote

favorite












I made a script which is run always when open the terminal. Anyone know how to detect that script? I forgot a path to directory which I put it







share|improve this question












closed as unclear what you're asking by Kusalananda, Rui F Ribeiro, Vlastimil, Archemar, DopeGhoti Jan 30 at 19:17


Please clarify your specific problem or add additional details to highlight exactly what you need. As it's currently written, it’s hard to tell exactly what you're asking. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.














  • Your question title bears no relation to your question text :-)
    – garethTheRed
    Jan 30 at 7:30






  • 1




    Try the find command. It's named after its purpose. ;) Start with man find to see how it works.
    – Mioriin
    Jan 30 at 7:31














up vote
-1
down vote

favorite












I made a script which is run always when open the terminal. Anyone know how to detect that script? I forgot a path to directory which I put it







share|improve this question












closed as unclear what you're asking by Kusalananda, Rui F Ribeiro, Vlastimil, Archemar, DopeGhoti Jan 30 at 19:17


Please clarify your specific problem or add additional details to highlight exactly what you need. As it's currently written, it’s hard to tell exactly what you're asking. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.














  • Your question title bears no relation to your question text :-)
    – garethTheRed
    Jan 30 at 7:30






  • 1




    Try the find command. It's named after its purpose. ;) Start with man find to see how it works.
    – Mioriin
    Jan 30 at 7:31












up vote
-1
down vote

favorite









up vote
-1
down vote

favorite











I made a script which is run always when open the terminal. Anyone know how to detect that script? I forgot a path to directory which I put it







share|improve this question












I made a script which is run always when open the terminal. Anyone know how to detect that script? I forgot a path to directory which I put it









share|improve this question











share|improve this question




share|improve this question










asked Jan 30 at 7:19









lemming

85




85




closed as unclear what you're asking by Kusalananda, Rui F Ribeiro, Vlastimil, Archemar, DopeGhoti Jan 30 at 19:17


Please clarify your specific problem or add additional details to highlight exactly what you need. As it's currently written, it’s hard to tell exactly what you're asking. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.






closed as unclear what you're asking by Kusalananda, Rui F Ribeiro, Vlastimil, Archemar, DopeGhoti Jan 30 at 19:17


Please clarify your specific problem or add additional details to highlight exactly what you need. As it's currently written, it’s hard to tell exactly what you're asking. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.













  • Your question title bears no relation to your question text :-)
    – garethTheRed
    Jan 30 at 7:30






  • 1




    Try the find command. It's named after its purpose. ;) Start with man find to see how it works.
    – Mioriin
    Jan 30 at 7:31
















  • Your question title bears no relation to your question text :-)
    – garethTheRed
    Jan 30 at 7:30






  • 1




    Try the find command. It's named after its purpose. ;) Start with man find to see how it works.
    – Mioriin
    Jan 30 at 7:31















Your question title bears no relation to your question text :-)
– garethTheRed
Jan 30 at 7:30




Your question title bears no relation to your question text :-)
– garethTheRed
Jan 30 at 7:30




1




1




Try the find command. It's named after its purpose. ;) Start with man find to see how it works.
– Mioriin
Jan 30 at 7:31




Try the find command. It's named after its purpose. ;) Start with man find to see how it works.
– Mioriin
Jan 30 at 7:31










2 Answers
2






active

oldest

votes

















up vote
0
down vote



accepted










IF a particular user logged in then you want to execute script



Include script in below mentioned path



/home/user/.bashrc file


IF You want to execute the script at every reboot



Include the script in below mentioned path



/etc/rc.local





share|improve this answer



























    up vote
    0
    down vote













    In Linux bash will run the ~/.bashrc script.



    But in most cases, you want to add a line to your ~/.profile script.



    bash also has a logout script: ~/.bash_logout



    You should call your script from one of those. Say you put your script in ~/bin/my-script.sh, then you could add:



    ~/bin/myscript.sh


    at the end of ~/.profile.



    Note that if your script generates an error, you should see it next time you start your console. Under X-Windows, opening a new X-term console will run your script again, so you can test by closing and reopening the console.






    share|improve this answer



























      2 Answers
      2






      active

      oldest

      votes








      2 Answers
      2






      active

      oldest

      votes









      active

      oldest

      votes






      active

      oldest

      votes








      up vote
      0
      down vote



      accepted










      IF a particular user logged in then you want to execute script



      Include script in below mentioned path



      /home/user/.bashrc file


      IF You want to execute the script at every reboot



      Include the script in below mentioned path



      /etc/rc.local





      share|improve this answer
























        up vote
        0
        down vote



        accepted










        IF a particular user logged in then you want to execute script



        Include script in below mentioned path



        /home/user/.bashrc file


        IF You want to execute the script at every reboot



        Include the script in below mentioned path



        /etc/rc.local





        share|improve this answer






















          up vote
          0
          down vote



          accepted







          up vote
          0
          down vote



          accepted






          IF a particular user logged in then you want to execute script



          Include script in below mentioned path



          /home/user/.bashrc file


          IF You want to execute the script at every reboot



          Include the script in below mentioned path



          /etc/rc.local





          share|improve this answer












          IF a particular user logged in then you want to execute script



          Include script in below mentioned path



          /home/user/.bashrc file


          IF You want to execute the script at every reboot



          Include the script in below mentioned path



          /etc/rc.local






          share|improve this answer












          share|improve this answer



          share|improve this answer










          answered Jan 30 at 15:20









          Praveen Kumar BS

          1,010128




          1,010128






















              up vote
              0
              down vote













              In Linux bash will run the ~/.bashrc script.



              But in most cases, you want to add a line to your ~/.profile script.



              bash also has a logout script: ~/.bash_logout



              You should call your script from one of those. Say you put your script in ~/bin/my-script.sh, then you could add:



              ~/bin/myscript.sh


              at the end of ~/.profile.



              Note that if your script generates an error, you should see it next time you start your console. Under X-Windows, opening a new X-term console will run your script again, so you can test by closing and reopening the console.






              share|improve this answer
























                up vote
                0
                down vote













                In Linux bash will run the ~/.bashrc script.



                But in most cases, you want to add a line to your ~/.profile script.



                bash also has a logout script: ~/.bash_logout



                You should call your script from one of those. Say you put your script in ~/bin/my-script.sh, then you could add:



                ~/bin/myscript.sh


                at the end of ~/.profile.



                Note that if your script generates an error, you should see it next time you start your console. Under X-Windows, opening a new X-term console will run your script again, so you can test by closing and reopening the console.






                share|improve this answer






















                  up vote
                  0
                  down vote










                  up vote
                  0
                  down vote









                  In Linux bash will run the ~/.bashrc script.



                  But in most cases, you want to add a line to your ~/.profile script.



                  bash also has a logout script: ~/.bash_logout



                  You should call your script from one of those. Say you put your script in ~/bin/my-script.sh, then you could add:



                  ~/bin/myscript.sh


                  at the end of ~/.profile.



                  Note that if your script generates an error, you should see it next time you start your console. Under X-Windows, opening a new X-term console will run your script again, so you can test by closing and reopening the console.






                  share|improve this answer












                  In Linux bash will run the ~/.bashrc script.



                  But in most cases, you want to add a line to your ~/.profile script.



                  bash also has a logout script: ~/.bash_logout



                  You should call your script from one of those. Say you put your script in ~/bin/my-script.sh, then you could add:



                  ~/bin/myscript.sh


                  at the end of ~/.profile.



                  Note that if your script generates an error, you should see it next time you start your console. Under X-Windows, opening a new X-term console will run your script again, so you can test by closing and reopening the console.







                  share|improve this answer












                  share|improve this answer



                  share|improve this answer










                  answered Jan 30 at 7:38









                  Alexis Wilke

                  844614




                  844614












                      Popular posts from this blog

                      How to check contact read email or not when send email to Individual?

                      Bahrain

                      Postfix configuration issue with fips on centos 7; mailgun relay