File: sort-includes.sh

package info (click to toggle)
kadu 4.1-1.1
  • links: PTS, VCS
  • area: main
  • in suites: buster
  • size: 54,532 kB
  • sloc: cpp: 128,331; sh: 988; awk: 105; makefile: 75
file content (11 lines) | stat: -rwxr-xr-x 197 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
#!/usr/bin/env bash

BASEDIR=${0%/*}
FILE=$1

echo "Sorting includes for $FILE"

AWK_SORT=$BASEDIR/sort-includes.awk

gawk -f $AWK_SORT $FILE > $FILE.sorted-includes
mv $FILE.sorted-includes $FILE