view ifndef_wrapper.sh @ 1632:c4bf28ccab97

packet: remove stale comment about "packet_type" (#63) clean up after 7f15910541 Signed-off-by: Konstantin Demin <[email protected]>
author Konstantin Demin <rockdrilla@gmail.com>
date Wed, 20 Mar 2019 17:33:15 +0300
parents 0196f4f83fee
children
line wrap: on
line source

#!/bin/sh

# Wrap all "#define X Y" with a #ifndef X...#endif"

sed 's/^\( *#define \([^ ][^ ]*\) .*\)/#ifndef \2\
\1\
#endif/'