This is a short document describing the preferred coding style for the linux kernel. Coding style is very personal, and I won't force my views on anybody, but this is what goes for anything that I have to be able to maintain, and I'd prefer it for most other things too. Please at least consider the points made here.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Simple, ad-hoc script to quickly bootstrap a fresh Vim install. | |
echo -n "This will overwrite your .vimrc and plugins. Do you wish to continue [y/N]? " | |
read answer | |
if ! echo "$answer" | grep -iq "^y"; then | |
exit | |
fi |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
execute pathogen#infect() | |
"execute pathogen#helptags() | |
" Suggested Pathogen plugins | |
" https://github.com/tpope/vim-commentary.git | |
" https://github.com/tpope/vim-obsession.git | |
" https://github.com/tpope/vim-sensible.git | |
" https://github.com/tpope/vim-markdown.git | |
" https://github.com/itchyny/lightline.vim | |
" https://github.com/terryma/vim-multiple-cursors.git | |
" https://github.com/mhinz/vim-signify |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"Version":"2012-10-17", | |
"Statement":[{ | |
"Sid":"PublicReadGetObject", | |
"Effect":"Allow", | |
"Principal": "*", | |
"Action":["s3:GetObject"], | |
"Resource":["arn:aws:s3:::example.com/*" | |
] | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <stdio.h> | |
#include <unistd.h> | |
#include <sys/socket.h> | |
#include <msgpack.h> | |
/* | |
* $ NVIM_LISTEN_ADDRESS=127.0.0.1:8888 nvim | |
* | |
*/ |
In Postgres, each row has a system column xmin
which holds the ID of the first transaction to have visibility over that row.
Conversely, the xmax
system column holds the ID of last trasaction to have visibility over that row.
DROP TABLE IF EXISTS users;
CREATE TABLE users (name varchar(80)) WITH OIDS;
INSERT INTO users VALUES ('root');
SELECT oid, xmin, xmax, name FROM users;
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> | |
<html> | |
<head> | |
<title>Gameboy (LR35902) OPCODES</title> | |
<meta http-equiv="content-type" content="text/html; charset=windows-1250"> | |
<style type="text/css"> <!-- | |
table.withborder { | |
border-width: 1px; | |
border-style: solid; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
" Plug: https://github.com/junegunn/vim-plug | |
call plug#begin('~/.vim/plugged') | |
Plug 'tpope/vim-commentary' | |
Plug 'tpope/vim-obsession' | |
Plug 'tpope/vim-sensible' | |
Plug 'tpope/vim-markdown' | |
Plug 'itchyny/lightline.vim' | |
Plug 'terryma/vim-multiple-cursors' | |
Plug 'airblade/vim-gitgutter' | |
Plug 'chriskempson/base16-vim' |
- Install vim-plug
curl -fLo ~/.vim/autoload/plug.vim --create-dirs \ https://raw.githubusercontent.com/junegunn/vim-plug/master/plug.vim
- Clone .vimrc
vim +PlugInstall +qall
- In Vim
:Obsess ~/.vim/mysession.vim
OlderNewer