diff --git a/docs/troubleshooting/README.md b/docs/troubleshooting/README.md index 11a6c34..1e1d53b 100644 --- a/docs/troubleshooting/README.md +++ b/docs/troubleshooting/README.md @@ -47,6 +47,9 @@ You can inspect a failing [AliHyperloop test](../hyperloop/userdocumentation.md# See the [Support](../gettingstarted/support.md) section for the list of Mattermost channels where you can ask for help. +When asking for help with compilation or with running a local analysis, it may be useful to provide basic information about your O2Physics setup. +You can generate it by running the [`summarise_o2p_setup.sh`](summarise_o2p_setup.sh) bash script in your `alice` directory. + When posting on Mattermost: - Do not paste the entire content of files or any long blocks of log lines or code directly in the message. If needed, attach the file. diff --git a/docs/troubleshooting/summarise_o2p_setup.sh b/docs/troubleshooting/summarise_o2p_setup.sh new file mode 100644 index 0000000..7fa9c39 --- /dev/null +++ b/docs/troubleshooting/summarise_o2p_setup.sh @@ -0,0 +1,22 @@ +#!/bin/bash + +# Summarise O2Physics setup + +if [[ -n "$(which aliBuild)" ]]; then + echo "aliBuild location: $(which aliBuild)" + # echo "all aliBuild locations: $(whereis aliBuild)" + aliBuild version +else + echo "aliBuild not found." +fi + +for repo in alidist O2 O2Physics; do + [[ -d "${repo}" ]] || { echo "Directory ${repo} not found."; continue; } + echo "Last commit of ${repo}: $(cd "${repo}" && git log -n 1 --pretty="format:%ci %h")" +done + +for pkg in O2 O2Physics; do + log="$ALIBUILD_WORK_DIR/BUILD/${pkg}-latest/log" + [[ -f "${log}" ]] || { echo "Log file ${log} not found."; continue; } + echo "Last build of ${pkg}: $(stat -c "%y" "${log}")" +done