apt-get で入る Vim は古いので、Linuxでのビルド方法 を参考にして最新版をビルドする。 この際に if_lua を有効にしておく。
sudo apt-get build-dep vim
function _prompt_char() { | |
if $(git rev-parse --is-inside-work-tree >/dev/null 2>&1); then | |
echo "%{%F{blue}%}%{%f%k%b%}" | |
else | |
echo ' ' | |
fi | |
} | |
# This theme works with both the "dark" and "light" variants of the | |
# Solarized color schema. Set the SOLARIZED_THEME variable to one of |
#!/bin/bash | |
# | |
# template script for generating ubuntu container for LXC | |
# | |
# This script consolidates and extends the existing lxc ubuntu scripts | |
# | |
# Copyright © 2011 Serge Hallyn <[email protected]> | |
# Copyright © 2010 Wilhelm Meier |
apt-get で入る Vim は古いので、Linuxでのビルド方法 を参考にして最新版をビルドする。 この際に if_lua を有効にしておく。
sudo apt-get build-dep vim
#!/bin/sh | |
set -xe | |
# Install requirements | |
sudo apt-get install build-essential unzip zip man subversion python | |
# Checkout repositories | |
svn co http://llvm.org/svn/llvm-project/llvm/trunk llvm | |
cd llvm/tools |
CXX = clang++ | |
LANGUAGE_OPTIONS = -std=c++11 | |
WARNING_OPTIONS = -Wall -Wextra -Weffc++ -Woverloaded-virtual | |
OPTIMIZATION_OPTIONS = -O3 -fno-omit-frame-pointer | |
CODE_GENERATION_OPTIONS = -fPIC | |
PREPROCESSOR_OPTIONS = -MMD -MP $(shell llvm-config --cppflags | sed -e 's/-DNDEBUG //') | |
DEBUGGING_OPTIONS = -gdwarf-3 -fsanitize=address | |
CXXFLAGS = $(LANGUAGE_OPTIONS) $(WARNING_OPTIONS) $(OPTIMIZATION_OPTIONS) $(CODE_GENERATION_OPTIONS) $(PREPROCESSOR_OPTIONS) $(DEBUGGING_OPTIONS) |
Index: lib/Format/ContinuationIndenter.cpp | |
=================================================================== | |
--- lib/Format/ContinuationIndenter.cpp (revision 216461) | |
+++ lib/Format/ContinuationIndenter.cpp (working copy) | |
@@ -825,7 +825,7 @@ | |
NewIndent = State.Stack.back().LastSpace; | |
if (Current.opensBlockTypeList(Style)) { | |
NewIndent += Style.IndentWidth; | |
- NewIndent = std::min(State.Column + 2, NewIndent); | |
+ NewIndent = std::min(State.Column + Style.IndentWidth, NewIndent); |
// slack-logger/main.go | |
package main | |
import ( | |
"encoding/json" | |
"flag" | |
"fmt" | |
"io" | |
"io/ioutil" | |
"log" |
#!/bin/sh -ex | |
cd $(dirname $0) | |
if [ -f Makefile ]; then | |
make clean | |
fi | |
./configure \ | |
--with-cc-opt="-O2 -fstack-protector --param=ssp-buffer-size=4 -Wformat -Werror=format-security -D_FORTIFY_SOURCE=2" \ | |
--with-ld-opt="-Wl,-Bsymbolic-functions -Wl,-z,relro" \ | |
--prefix=/usr/local \ |