1#!/bin/sh
2#
3# List all the files under version control in the source tree.
4#
5
6case $# in
70) ;;
81) cd "$1" ;;
9*) echo >&2 "Usage: $0 [top_srcdir]"; exit 2 ;;
10esac
11
12if [ -r .git/HEAD ]; then
13  ${GIT:-git} ls-files
14  exit 0
15fi
16
17echo >&2 'Cannot list sources without some version control system in use.'
18exit 1
19