mirror of
https://github.com/iiab/iiab.git
synced 2025-03-09 15:40:17 +00:00
Record recent git tag, for 2 primary repos
This commit is contained in:
parent
18aef95d92
commit
f898553346
4 changed files with 19 additions and 20 deletions
|
@ -4,15 +4,16 @@
|
|||
# PLEASE SEE /opt/iiab/iiab/scripts/iiab-diagnostics.README.md OR ONLINE HERE:
|
||||
# https://github.com/iiab/iiab/blob/master/scripts/iiab-diagnostics.README.md
|
||||
|
||||
IIAB_RELEASE=`cat /etc/iiab/iiab.env | grep IIAB_RELEASE | cut -d'=' -f2`
|
||||
OS_VER=`cat /etc/iiab/iiab.env | grep OS_VER | cut -d'=' -f2`
|
||||
IIAB_RELEASE=$(cat /etc/iiab/iiab.env | grep IIAB_RELEASE | cut -d'=' -f2)
|
||||
OS_VER=$(cat /etc/iiab/iiab.env | grep OS_VER | cut -d'=' -f2)
|
||||
YMDT=$(date +%F_%T_%Z)
|
||||
|
||||
#HASH=`cd /opt/iiab/iiab; git log --pretty=format:'%h' -n 1`
|
||||
git config --global --add safe.directory /opt/iiab/iiab # Nec below, if non-root
|
||||
HASH1=`cd /opt/iiab/iiab; git log --pretty=format:'%H' -n 1`
|
||||
HASH1=$(cd /opt/iiab/iiab; git log --pretty=format:'%H' -n 1) # --pretty=format:'%h' (8 chars)
|
||||
TAG1=$(cd /opt/iiab/iiab; git describe --tags --abbrev=0)
|
||||
git config --global --add safe.directory /opt/iiab/iiab-admin-console # Nec below, if non-root
|
||||
HASH2=`cd /opt/iiab/iiab-admin-console; git log --pretty=format:'%H' -n 1`
|
||||
HASH2=$(cd /opt/iiab/iiab-admin-console; git log --pretty=format:'%H' -n 1)
|
||||
TAG2=$(cd /opt/iiab/iiab-admin-console; git describe --tags --abbrev=0)
|
||||
|
||||
echo -e "\nGathers IIAB diagnostics into 1 file, to accelerate troubleshooting. USAGE:"
|
||||
echo
|
||||
|
@ -123,10 +124,12 @@ echo -e "\nCompiling diagnostics..."
|
|||
echo -e "\n 0. Filename Header + Git Hashes + Raspberry Pi Model + OS"
|
||||
echo "This is: $outfile" >> $outfile
|
||||
echo >> $outfile
|
||||
echo -e "\n\n\n\n0. GIT HASHES + RASPBERRY PI MODEL + OS" >> $outfile
|
||||
echo -e "\n\n\n\n0. GIT HASHES/TAGS + RASPBERRY PI MODEL + OS" >> $outfile
|
||||
echo >> $outfile
|
||||
echo "iiab commit: $HASH1" >> $outfile
|
||||
echo " recent git tag: $TAG1" >> $outfile
|
||||
echo "iiab-admin-console commit: $HASH2" >> $outfile
|
||||
echo " recent git tag: $TAG2" >> $outfile
|
||||
echo >> $outfile
|
||||
cat_file /etc/iiab/pr-list-pulled
|
||||
cat_file /proc/device-tree/model # Should be identical to /sys/firmware/devicetree/base/model
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue