]> andersk Git - gssapi-openssh.git/blame - openssh/fixpaths
Import of OpenSSH 4.7p1
[gssapi-openssh.git] / openssh / fixpaths
CommitLineData
6a9b3198 1#!/bin/sh
3c0ef626 2#
3# fixpaths - substitute makefile variables into text files
6a9b3198 4# Usage: fixpaths -Dsomething=somethingelse ...
3c0ef626 5
6a9b3198 6die() {
7 echo $*
8 exit -1
3c0ef626 9}
10
6a9b3198 11test -n "`echo $1|grep -- -D`" || \
12 die $0: nothing to do - no substitutions listed!
13
14test -n "`echo $1|grep -- '-D[^=]\+=[^ ]\+'`" || \
15 die $0: error in command line arguments.
3c0ef626 16
6a9b3198 17test -n "`echo $*|grep -- ' [^-]'`" || \
18 die Usage: $0 '[-Dstring=replacement] [[infile] ...]'
3c0ef626 19
6a9b3198 20sed `echo $*|sed -e 's/-D\([^=]\+\)=\([^ ]*\)/-e s=\1=\2=g/g'`
3c0ef626 21
6a9b3198 22exit 0
This page took 0.197715 seconds and 5 git commands to generate.