mirror of
https://github.com/zerotier/ZeroTierOne.git
synced 2024-12-25 07:31:05 +00:00
be7ce4110e
This reverts commit e96515433d
.
32 lines
594 B
Bash
Executable File
32 lines
594 B
Bash
Executable File
#! /bin/bash
|
|
#
|
|
# List "TODO" and "XXX" items in the given files, or throughout the source
|
|
# code.
|
|
|
|
set -e -u -o pipefail
|
|
|
|
# TODO: Make location-independent?
|
|
find_source() {
|
|
echo configure.ac
|
|
find . -name \*.cxx -o -name \*.hxx | sed -e 's|^\./||' | sort
|
|
for f in $(ls tools)
|
|
do
|
|
echo tools/$f
|
|
done
|
|
}
|
|
|
|
|
|
FILES=${*:-$(find_source)}
|
|
|
|
|
|
# Search for "$1:" in files $2.
|
|
# (This function adds the colon. That way, the search statement itself won't
|
|
# show up in the search.)
|
|
search_for() {
|
|
grep $1: $2
|
|
}
|
|
|
|
|
|
search_for XXX "$FILES" || true
|
|
search_for TODO "$FILES" || true
|