uknowngithubuser
10/31/2018 - 4:57 PM

Add Text at the top of a file #Function #Shell

Add Text at the top of a file #Function #Shell

function prepend()
{
  if [ -e $2 ]; then
      sed -i -e '1i$1\' $2
  fi
}