File: formatSourceFiles.sh

package info (click to toggle)
gimagereader 3.4.3-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 8,148 kB
  • sloc: cpp: 29,313; xml: 376; sh: 282; python: 70; makefile: 42
file content (7 lines) | stat: -rwxr-xr-x 281 bytes parent folder | download
1
2
3
4
5
6
7
#!/bin/sh
dir=$(dirname "$(readlink -f "$0")")
which astyle &> /dev/null || ( echo "Please install astyle." && exit 1 )

out=$(astyle --formatted --options=$dir/astyle.options $(find gtk qt common \( -name '*.cc' -or -name '*.hh' \)))
echo "$out"
[ -z "$out" ] && exit 0 || exit 1