view help/help_diff.sh @ 24800:1076f50ba2d2

Remove some unused code, fixes the following warnings: vosub_vidix.c: At top level: vosub_vidix.c:199: warning: 'vidix_draw_slice_410_fast' defined but not used vosub_vidix.c:211: warning: 'vidix_draw_slice_400' defined but not used vosub_vidix.c:365: warning: 'vidix_get_video_eq' defined but not used vosub_vidix.c:371: warning: 'vidix_set_video_eq' defined but not used vosub_vidix.c:377: warning: 'vidix_get_num_fx' defined but not used vosub_vidix.c:383: warning: 'vidix_get_oem_fx' defined but not used vosub_vidix.c:389: warning: 'vidix_set_oem_fx' defined but not used vosub_vidix.c:395: warning: 'vidix_set_deint' defined but not used
author diego
date Sun, 21 Oct 2007 12:56:22 +0000
parents 60c71a89cd76
children 3ff3bd9bf0f9
line wrap: on
line source

#!/bin/sh

# This script walks through the master (stdin) help/message file, and
# prints (stdout) only those messages which are missing from the help
# file given as parameter ($1).
#
# Example: help_diff.sh help_mp-hu.h < help_mp-en.h > missing.h

curr=""

while read -r line; do
	if echo "$line" | grep '^#define' > /dev/null 2>&1; then
		curr=`printf "%s\n" "$line" | cut -d ' ' -f 2`
		if grep "^#define $curr[	 ]" $1 > /dev/null 2>&1; then
			curr=""
		fi
	else
		if [ -z "$line" ]; then
			curr=""
		fi
	fi

	if [ -n "$curr" ]; then
		printf "%s\n" "$line"
	fi
done