File: generate-module-list.sh

package info (click to toggle)
haskell-futhark 0.25.32-2
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 18,236 kB
  • sloc: haskell: 100,484; ansic: 12,100; python: 3,440; yacc: 785; sh: 561; javascript: 558; lisp: 399; makefile: 277
file content (14 lines) | stat: -rwxr-xr-x 539 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
#!/bin/sh
#
# This is an ad-hoc hack to generate a list of exposed modules for the
# .cabal file.  It automatically excludes the parser stuff (which go
# in the Other-Modules field in the .cabal file) and driver programs,
# under the assumption that these don't change much.  Run it from the
# root of the directory.

find "${1:-src}" -type f \
    | grep -v '#' \
    | grep -v '~' \
    | grep -E -v 'Language.Futhark.Parser.(Parser|Lexer|Tokens)|futhark|futharki' \
    | sed -e "s/.hs$//" -e "s_${1:-src}/__" -e "s_/_._g" \
    | sort