From a1099dad7cdf46b74232f2a3cf4bab9cae4d7846 Mon Sep 17 00:00:00 2001 From: Mateus Devino Date: Thu, 25 Jul 2024 17:19:39 -0300 Subject: [PATCH 1/3] Add rust version and commit hash to bug report Signed-off-by: Mateus Devino --- .github/ISSUE_TEMPLATE/bug_report.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/ISSUE_TEMPLATE/bug_report.md b/.github/ISSUE_TEMPLATE/bug_report.md index 7eeb5562..5b525a06 100644 --- a/.github/ISSUE_TEMPLATE/bug_report.md +++ b/.github/ISSUE_TEMPLATE/bug_report.md @@ -14,8 +14,8 @@ A clear and concise description of what the bug is. Please provide details about the environment you are using, including the following: -- Interpreter version: -- Library version: +- Rust version (`rustc --version`): +- Commit hash from main branch (`git log -1 --pretty=format:"%h"`): ## Sample Code From 7db79e2004708f0b210bd73c1126704a6f518bf1 Mon Sep 17 00:00:00 2001 From: Mateus Devino Date: Thu, 25 Jul 2024 17:32:38 -0300 Subject: [PATCH 2/3] Add script to collect environment details for bug reports Signed-off-by: Mateus Devino --- .github/ISSUE_TEMPLATE/bug_report.md | 13 ++++++++++--- scripts/collect_env.sh | 4 ++++ 2 files changed, 14 insertions(+), 3 deletions(-) create mode 100755 scripts/collect_env.sh diff --git a/.github/ISSUE_TEMPLATE/bug_report.md b/.github/ISSUE_TEMPLATE/bug_report.md index 5b525a06..0bd870e5 100644 --- a/.github/ISSUE_TEMPLATE/bug_report.md +++ b/.github/ISSUE_TEMPLATE/bug_report.md @@ -12,10 +12,17 @@ A clear and concise description of what the bug is. ## Platform -Please provide details about the environment you are using, including the following: +Please provide details about the environment you are using (run `scripts/collect_env.sh`). + +Hint: In case you cannot run script due to permissions, try `chmod u+x scripts/collect_env.sh`, then run again. + + -- Rust version (`rustc --version`): -- Commit hash from main branch (`git log -1 --pretty=format:"%h"`): ## Sample Code diff --git a/scripts/collect_env.sh b/scripts/collect_env.sh new file mode 100755 index 00000000..a521784c --- /dev/null +++ b/scripts/collect_env.sh @@ -0,0 +1,4 @@ +#/usr/bin/env sh + +rustc --version +echo "Commit hash: $(git log -1 --pretty=format:'%h')" \ No newline at end of file From fa358291dc01a85134702bccc88b4fa7196e9420 Mon Sep 17 00:00:00 2001 From: Mateus Devino Date: Fri, 24 Jan 2025 09:15:41 -0300 Subject: [PATCH 3/3] Add tag to collect_env.sh Signed-off-by: Mateus Devino --- .github/ISSUE_TEMPLATE/bug_report.md | 4 ++-- scripts/collect_env.sh | 7 ++++++- 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/.github/ISSUE_TEMPLATE/bug_report.md b/.github/ISSUE_TEMPLATE/bug_report.md index 0bd870e5..15bf52b9 100644 --- a/.github/ISSUE_TEMPLATE/bug_report.md +++ b/.github/ISSUE_TEMPLATE/bug_report.md @@ -19,8 +19,8 @@ Hint: In case you cannot run script due to permissions, try `chmod u+x scripts/c diff --git a/scripts/collect_env.sh b/scripts/collect_env.sh index a521784c..16df0bb9 100755 --- a/scripts/collect_env.sh +++ b/scripts/collect_env.sh @@ -1,4 +1,9 @@ #/usr/bin/env sh rustc --version -echo "Commit hash: $(git log -1 --pretty=format:'%h')" \ No newline at end of file + +ORCHESTRATOR_VERSION=$(git tag --points-at HEAD) +if [ -z "$ORCHESTRATOR_VERSION" ]; then + ORCHESTRATOR_VERSION="No tag associated" +fi +echo "Orchestrator version: $ORCHESTRATOR_VERSION ($(git log -1 --pretty=format:'%h'))" \ No newline at end of file