Date: 2021-12-23
Accepted
# vim: set syntax=dockerfile: | |
FROM node:9.9.0-alpine | |
RUN apk --update upgrade && \ | |
apk add python && \ | |
npm config set loglevel error && \ | |
npm install -g [email protected] && \ | |
apk del python && \ | |
rm -rf /var/cache/apk/* |
#!/bin/bash | |
# | |
# scripts/test.sh | |
# | |
# * Generates `coverage/index.html`: HTML artifact for download, | |
# * Generates `coverage/report.xml`: report of failed tests in Junit format, and | |
# * Validates the minimum code coverage still applies. | |
# | |
# Depends on: | |
# * github.com/jstemmer/go-junit-report |
"-- vim-go specific configuration | |
" run :GoBuild or :GoTestCompile based on the go file | |
function! s:build_go_files() | |
let l:file = expand('%') | |
if l:file =~# '^\f\+_test\.go$' | |
call go#test#Test(0, 1) | |
elseif l:file =~# '^\f\+\.go$' | |
call go#cmd#Build(0) | |
endif |
let mapleader = "," | |
filetype on | |
filetype indent on | |
filetype plugin on | |
set encoding=UTF-8 | |
syntax on | |
set nocompatible |
❯ tree internal/ | |
internal/ | |
├── datastore | |
│ ├── file1.go | |
│ ├── file2.go | |
│ ├── fileN.go | |
├── api | |
│ ├── file1.go | |
│ ├── file2.go | |
│ ├── fileN.go |
{ | |
"languageserver": { | |
"go": { | |
"command": "gopls", | |
"rootPatterns": ["go.mod"], | |
"trace.server": "verbose", | |
"filetypes": ["go"] | |
} | |
} | |
} |
vim.g.mapleader = "," | |
vim.opt.filetype="on" | |
vim.opt.filetype.indent="on" | |
vim.opt.filetype.plugin="on" | |
vim.opt.encoding="utf-8" | |
vim.opt.syntax="on" | |
vim.opt.compatible=false |