#!/bin/sh
#
# mkvi - create paths to all files before invoking editor

for file; do
  mkdir -p -- "${file%/*}" || exit
done
exec "${VISUAL-}" "$@"
