2021-06-09 10:23:48 -07:00
|
|
|
#! /bin/bash
|
|
|
|
|
2022-01-06 14:50:04 -08:00
|
|
|
set -e
|
2021-06-09 10:23:48 -07:00
|
|
|
|
|
|
|
container_name=nvim-$USER
|
|
|
|
|
|
|
|
if ! docker inspect "${container_name}-home" > /dev/null ; then
|
|
|
|
docker volume create "${container_name}-home"
|
|
|
|
fi
|
|
|
|
|
|
|
|
docker run --interactive --rm --tty \
|
|
|
|
--name "$container_name" \
|
2022-01-06 14:50:04 -08:00
|
|
|
--env "NVIM_COLOR=$NVIM_COLOR" \
|
2021-12-16 20:50:37 -08:00
|
|
|
--volume "${container_name}-home:/home/vividboarder/.data" \
|
2021-06-09 10:23:48 -07:00
|
|
|
--volume "$(pwd):/home/vividboarder/data" \
|
|
|
|
--workdir /home/vividboarder/data \
|
2021-12-16 20:50:37 -08:00
|
|
|
--entrypoint /docker-entry.sh \
|
2022-01-02 22:06:47 -08:00
|
|
|
--user "vividboarder:$(id -g)" \
|
|
|
|
--group-add users \
|
2022-01-06 14:50:04 -08:00
|
|
|
vividboarder/my-neovim "$@"
|