David Aguilar <dav...@gmail.com> writes:

> +check_header_usage () {
> +     first=$(grep '^#include' "$1" |
> +             head -n1 |
> +             sed -e 's,#include ",,' -e 's,"$,,')

perhaps a single "sed" invocation suffices?

        sed -n -e '/^#include/{
                s/#include ["<]\(.*\)".*/\1/p
                q
        }' "$1"
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to