8000 GitHub - minustime/with-vim: Container with pre-configured shell and editor.
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

minustime/with-vim

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

With Vim

Container with pre-configured shell and editor. Used to keep a familiar dev experience when exploring new languages, tools, etc.

with-vim

Usage

With local files

To work on local files inside a ./workspace directory:

$ docker run -it -v `pwd`/workspace:/opt/workspace minustime/with-vim:ubuntu-bionic

OR

Even better, create a shortcut for it!

  1. Update your ~/.bashrc file with this function:

// In .bashrc
function with-vim {
        local WS="$PWD/workspace"
        if [[ ! -z "$1" ]]; then
                if [[ -d "$1" ]]; then
                        cd "$1"
                        WS="$(pwd)"
                        cd -
                else
                        WS="$PWD/$1"
                fi
        fi
        docker run -it -v "$WS:/opt/workspace" minustime/with-vim:ubuntu-bionic
}

  1. Source it
$ source ~/.bashrc
  1. Run it against any directory:
$ with-vim .

As base image

This can also be used as a temporary base image for another project:

FROM minustime/with-vim:ubuntu-bionic

USER root
RUN which nvim
USER ${USER}

CMD ["sleep", "infinity"]

Development

  1. Clone this repo:
$ git clone git@github.com:minustime/with-vim.git && cd with-vim
  1. Build, run and access the container:
$ make code

Fun features

  • Oh My Zsh + vim-mode
  • Neovim

About

Container with pre-configured shell and editor.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published
0