Skip to content

Commit

Permalink
u-boot: add git describe to README
Browse files Browse the repository at this point in the history
  • Loading branch information
davidkaroly committed Mar 3, 2023
1 parent f5ef3b9 commit 9ac8b1b
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 1 addition & 1 deletion u-boot/tools/README.template
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ This section tracks the u-boot revision within this repo.
* **License:** GPLv2
* **Source Code:** %%GIT_REPO%%
* **Date:** %%GIT_DATE%%
* **GIT Hash:** %%GIT_HASH%%
* **GIT Commit:** %%GIT_HASH%% %%GIT_DESC%%
* **Toolchain:** http://cgit.haiku-os.org/buildtools/
* **Toolchain version:** %%CROSS_TOOL_VERSION%%
* **Build Commands:**
Expand Down
2 changes: 2 additions & 0 deletions u-boot/tools/build
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,7 @@ fi
echo "Calculating dates..."
GIT_DATE=$(git -C $TMP log -1 --format=%cd)
GIT_HASH=$(git -C $TMP log -1 --format=%H)
GIT_DESC=$(git -C $TMP describe)

echo "Locating work..."
WORK_QUEUE=$(find $TARGET_ARCH/ -mindepth 1 -type d)
Expand Down Expand Up @@ -143,6 +144,7 @@ for dir in $WORK_QUEUE; do
sed -i "s^%%GIT_REPO%%^$GIT_REPO^g" $dir/README.md
sed -i "s^%%GIT_DATE%%^$GIT_DATE^g" $dir/README.md
sed -i "s^%%GIT_HASH%%^$GIT_HASH^g" $dir/README.md
sed -i "s^%%GIT_DESC%%^$GIT_DESC^g" $dir/README.md
sed -i "s^%%BOARD%%^$NAME^g" $dir/README.md
sed -i "s^%%FILES%%^$FILES^g" $dir/README.md
sed -i "s^%%CONFIG%%^$CONFIG^g" $dir/README.md
Expand Down

0 comments on commit 9ac8b1b

Please sign in to comment.