Clang-format

Hello,

I have installed clang following the recommandations from the https://github.com/AliceO2Group/CodingGuidelines page.

The clang-format command is not available, see below:

manso@clraliceport15:~/alice/15-01-2020$ alienv enter Clang/latest-o2
/usr/share/modules/init/bash: ligne 36: /usr/bin/tclsh: Aucun fichier ou dossier de ce type
/usr/share/modules/init/bash: ligne 58 : export: _moduleraw : n’est pas une fonction
/usr/share/modules/init/bash: ligne 60 : export: module : n’est pas une fonction
Currently Loaded Modulefiles:

  1. BASE/1.0 2) Clang/latest-o2
    Use alienv list to list loaded modules. Use exit to exit this environment.
    [Clang/latest-o2] ~/alice/15-01-2020 $> clang-format
    bash: clang-format : commande introuvable

I discuss with another guy and he has the same issue.

Thanks for the help, F.M.

Do you use tclsh as your shell?

Hello,
non, it’s the bash shell:

manso@clraliceport15:~$ echo $SHELL
/bin/bash

Ah, wait, I misread tclsh to tcsh. Which distribution is this? Can you contact me in private on mattermost?

I’m on Ubuntu distribution 18.04. I didn’t test with CentOS7 that I have on another computer… I’m going to check on it.

Do you have tcl installed?

No, I don’t. I could try with it…

It seems that clang-format is now installed in bin-safe which is not added to the path. Probably we just need to fix our modulefile.

Ok, I found it: sw/ubuntu1804_x86-64/Clang/latest/bin-safe
and it works with: ./clang-format …

Best regards, FM

I created a ticket : https://alice.its.cern.ch/jira/browse/O2-1053