diff options
| author | Jakob Kaivo <jkk@ung.org> | 2019-02-01 18:09:21 -0500 |
|---|---|---|
| committer | Jakob Kaivo <jkk@ung.org> | 2019-02-01 18:09:21 -0500 |
| commit | a8ea1cb4b021e582b9f56963fc03de95a7123927 (patch) | |
| tree | 66e1c70978d9d1a43322b5cef67d2a959eccd1f8 | |
| parent | 107353f5b3c74e57bb1ed06194770b0c2ea0f65c (diff) | |
remember newline after extern definitions
| -rwxr-xr-x | mkh.sh | 4 |
1 files changed, 3 insertions, 1 deletions
@@ -102,6 +102,8 @@ if [ -d $HEADER.TYPE ]; then sed -ne '/#ifdef/,/#endif/p' $i elif grep -q '^typedef.*;$' $i; then grep '^typedef' $i + elif grep -q '^struct.*;$' $i; then + grep '^struct.*;$' $i else sed -ne '/^typedef/,/\}.*;$/p' $i fi @@ -174,7 +176,7 @@ if [ -d $HEADER.EXTERN ]; then fi for i in $(sort -u $v); do - printf 'extern %s' "$(grep '^[a-zA-Z_].*;$' $i)" + printf 'extern %s\n' "$(grep '^[a-zA-Z_].*;$' $i)" done if [ -n "$version" ]; then |
