#!/bin/sh usage() { printf 'usage: %s tag file\n' $0 exit 1 } test $# -lt 2 && usage tag="$1"; shift sed "/0.0.1=/ { n; c\\ $tag }" "$@"