# How to call certain file whenever one is in the ROOT environment in terminal?

**URL:** <https://root-forum.cern.ch/t/how-to-call-certain-file-whenever-one-is-in-the-root-environment-in-terminal/62025>\
**Category:** ROOT\
**Tags:** root\
**Created:** [October 26, 2024, 1:06am UTC](https://root-forum.cern.ch/t/how-to-call-certain-file-whenever-one-is-in-the-root-environment-in-terminal/62025 "2024-10-26T01:06:53Z")\
**Posts on this page:** 1\
**Showing post:** 4

<div class="post-metadata">

**Author:** ![Wile\_E\_Coyote](https://root-forum.cern.ch/user_avatar/root-forum.cern.ch/wile_e_coyote/32/12417_2.png) [@Wile\_E\_Coyote](https://root-forum.cern.ch/u/Wile_E_Coyote)\
**Post date:** [October 26, 2024, 11:09am UTC](https://root-forum.cern.ch/t/how-to-call-certain-file-whenever-one-is-in-the-root-environment-in-terminal/62025/4 "2024-10-26T11:09:37Z")

</div>

> [@rootlogon.C documentation](https://root-forum.cern.ch/t/rootlogon-c-documentation/49150/11):
>
> Well, to be precise, the order is as follows: “$(root-config --etcdir)/system.rootlogon.C” “${HOME}/.rootlogon.C” “${PWD}/.rootlogon.C” but only if “${PWD}” != “${HOME}” the file defined by “Rint.Logon” which exists in “TROOT::GetMacroPath()”, so, by default (see the “$(root-config --etcdir)/system.rootrc” file), it will be either “${PWD}/rootlogon.C” or “${ROOTSYS}/macros/rootlogon.C”

---

_[View the full topic](https://root-forum.cern.ch/t/how-to-call-certain-file-whenever-one-is-in-the-root-environment-in-terminal/62025)._
