Each of these commands will run an ad hoc http static server in your current (or specified) directory, available at http://localhost:8000. Use this power wisely.
$ python -m SimpleHTTPServer 8000| #!/bin/bash | |
| set -ue | |
| PROJECT_ROOT=$(readlink -m "$(dirname "$(readlink -f "$0")")"/../) | |
| echo "processing ${PROJECT_ROOT} ..." | |
| find "${PROJECT_ROOT}" -type f \ | |
| -regextype posix-egrep -regex ".*\.(h|hpp|cpp|cc)$" -print0 | \ | |
| xargs -0 clang-format -style="{BasedOnStyle: Google, IndentWidth: 4}" -i |
Each of these commands will run an ad hoc http static server in your current (or specified) directory, available at http://localhost:8000. Use this power wisely.
$ python -m SimpleHTTPServer 8000| " add for the ~/linux which contains the linux kernel src, | |
| " So tabstop, shiftwidth, softtabstop = 8 and noexpandtab are needed | |
| " 10, 13, 16 come up with my several username | |
| " Can calculate it by :echo stridx(expand("~/linux/:p"), "linux") | |
| let linux_index = stridx(expand("%:p"), "linux") | |
| autocmd FileType c,cpp if linux_index == 10 || linux_index == 13 | |
| \ || linux_index == 16 | | |
| \ let b:syntastic_checkers = ['make'] | | |
| \ let g:syntastic_check_on_open = 1 | | |
| \ set tabstop=8 shiftwidth=8 softtabstop=8 noexpandtab | endif |