Skip to content

Commit 88db449

Browse files
committed
Added updater script
1 parent 978bed9 commit 88db449

File tree

1 file changed

+42
-0
lines changed

1 file changed

+42
-0
lines changed

scripts/update_from_ref.sh

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
#! /usr/bin/env bash
2+
3+
# update_from_ref.sh
4+
# published as part of https://github.com/pConst/basic_verilog
5+
# Konstantin Pavlov, pavlovconst@gmail.com
6+
#
7+
# Updates all copies of files to the last reference version
8+
9+
10+
cd ..
11+
pp=$(pwd)
12+
13+
14+
# $1 - reference file
15+
update () {
16+
17+
find . -type f -name $(basename -- "$1") -print0 | while IFS= read -r -d '' fp; do
18+
fpr=$(readlink -f $fp)
19+
20+
if [ "$fpr" != "$1" ]; then
21+
22+
echo -n $fpr
23+
24+
if cmp -s $1 $fpr; then
25+
echo " - OK"
26+
else
27+
echo " - DIFFER"
28+
fi
29+
30+
fi
31+
32+
done
33+
}
34+
35+
36+
echo $pp
37+
echo "========================================================================="
38+
update $pp/scripts/clean_vivado.bat
39+
40+
echo "========================================================================="
41+
update $pp/scripts/clean_quartus.bat
42+

0 commit comments

Comments
 (0)