Public Repository

Last pushed: 2 months ago
Short Description
My Vim, dockerized
Full Description

My Vim, dockerized

Dockerfile

FROM alpine:3.6

RUN apk update && apk add 'vim>8' make curl git

ENV TERM=xterm-256color

ARG VIMRC_URL=https://raw.githubusercontent.com/meis/dotfiles/master/.vimrc
RUN curl $VIMRC_URL > /etc/vim/vimrc
ENV VIMHOME=/etc/vim

RUN vim +silent +PlugInstall +qall

RUN chmod a+rX -R /etc/vim

ENV HOME=/tmp

Usage

meis-vim() {
  path=`readlink -f ${1:-.}`
  file=`basename $path`
  dir=`dirname $path`
  ug=`id -u`:`id -g`
  docker run -ti --name meis-vim --rm \
    --user $ug \
    -v $dir:/edit \
    meis/vim \
    vim /edit/$file
}
Docker Pull Command
Owner
meis

Comments (0)