# Unix.\*.Root.MacroPath issue

**URL:** <https://root-forum.cern.ch/t/unix-root-macropath-issue/42041>\
**Category:** ROOT\
**Tags:** tmva\
**Created:** [October 28, 2020, 5:29pm UTC](https://root-forum.cern.ch/t/unix-root-macropath-issue/42041 "2020-10-28T17:29:07Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![MonkeyTommy](https://root-forum.cern.ch/letter_avatar_proxy/v4/letter/m/a87d85/32.png) [@MonkeyTommy](https://root-forum.cern.ch/u/MonkeyTommy)\
**Post date:** [October 28, 2020, 5:29pm UTC](https://root-forum.cern.ch/t/unix-root-macropath-issue/42041/1 "2020-10-28T17:29:07Z")

</div>

Hi all !

I was trying to use ROOT TMVA and it has messed up the macro path followed by ROOT. This path leads to /tmva/test instead of going to my personal directory. Thus, I am unable to load or execute any of my personal macros. I think that this line :

echo “Unix.\*.Root.MacroPath: $ROOTSYS/tmva/test” \>\> .rootrc

has lead to my issue. I tried to use it in order to change the settings in .rootrc (gROOT-\>GetVersion()) but it hasn’t changed anything. I also tried to use the ROOT tutorial in order to set the environment variables but it also hasn’t worked. Do you know if there’s a way to reset this path to its default configuration or if I can somehow choose the path to be directed to my personal directories?

Thank you for your answers !

_ROOT Version:_ 6.20/06

---

<div class="post-metadata">

**Author:** ![jalopezg](https://root-forum.cern.ch/user_avatar/root-forum.cern.ch/jalopezg/32/25844_2.png) [@jalopezg](https://root-forum.cern.ch/u/jalopezg)\
**Post date:** [October 29, 2020, 10:39am UTC](https://root-forum.cern.ch/t/unix-root-macropath-issue/42041/2 "2020-10-29T10:39:09Z")

</div>

Hello @MonkeyTommy,

You can edit your `.rootrc` file and change the value of the `Unix.*.Root.MacroPath` variable accordingly, e.g. you can include `.` to search in the current directory. Directories can be separated by the `:` character.

Alternatively, you can temporarily set the macro search path during a session by

```auto
root [0] gROOT->SetMacroPath(".:your_macros/:other/");

```

I hope this solves your issue.

Cheers,  
J.

---

<div class="post-metadata">

**Author:** ![MonkeyTommy](https://root-forum.cern.ch/letter_avatar_proxy/v4/letter/m/a87d85/32.png) [@MonkeyTommy](https://root-forum.cern.ch/u/MonkeyTommy)\
**Post date:** [October 29, 2020, 11:12am UTC](https://root-forum.cern.ch/t/unix-root-macropath-issue/42041/3 "2020-10-29T11:12:02Z")

</div>

How do you edit the .rootrc file ?

---

<div class="post-metadata">

**Author:** ![jalopezg](https://root-forum.cern.ch/user_avatar/root-forum.cern.ch/jalopezg/32/25844_2.png) [@jalopezg](https://root-forum.cern.ch/u/jalopezg)\
**Post date:** [October 29, 2020, 11:47am UTC](https://root-forum.cern.ch/t/unix-root-macropath-issue/42041/4 "2020-10-29T11:47:36Z")

</div>

You can edit it with your text editor of preference.

It should be located either in the directory where you are invoking root from, or in your home directory, i.e. `~/.rootrc`.

---

<div class="post-metadata">

**Author:** ![MonkeyTommy](https://root-forum.cern.ch/letter_avatar_proxy/v4/letter/m/a87d85/32.png) [@MonkeyTommy](https://root-forum.cern.ch/u/MonkeyTommy)\
**Post date:** [October 29, 2020, 1:24pm UTC](https://root-forum.cern.ch/t/unix-root-macropath-issue/42041/5 "2020-10-29T13:24:25Z")

</div>

Fixed it, tank you !

---

<div class="post-metadata">

**Author:** ![system](https://root-forum.cern.ch/uploads/default/original/3X/e/f/efe4f24398fd8ffeb76bccb6ecc46d9d9c003376.png) [@system](https://root-forum.cern.ch/u/system)\
**Post date:** [November 12, 2020, 1:24pm UTC](https://root-forum.cern.ch/t/unix-root-macropath-issue/42041/6 "2020-11-12T13:24:25Z")

</div>

Closed on November 12, 2020, 1:24pm UTC

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.
