GitHub supports several lightweight markup languages for documentation; the most popular ones (generally, not just at GitHub) are Markdown and reStructuredText. Markdown is sometimes considered easier to use, and is often preferred when the purpose is simply to generate HTML. On the other hand, reStructuredText is more extensible and powerful, with native support (not just embedded HTML) for tables, as well as things like automatic generation of tables of contents.
function! Command_T_Local() "Go to the root of the git repo, then CommandT | |
"Ask git for the root of the git repo (as a relative '../../' path) | |
let git_top = system('git rev-parse --show-cdup') | |
let git_fail = 'fatal: Not a git repository' | |
if strpart(git_top, 0, strlen(git_fail)) == git_fail | |
" Above line says we are not in git repo. Ugly. Better version? | |
call Command_T_Work() | |
else | |
" Move working dir to root of repo, then CommandT | |
execute ":cd ./" . git_top |
" http://j.mp/dotvimrc | |
nn gt : exec tabpagenr('$') == 1 ? 'bn' : 'tabnext'<CR> | |
nn gT : exec tabpagenr('$') == 1 ? 'bp' : 'tabprevious'<CR> |
moved to https://github.com/Thermionix/multipass-usb |
Create remote called heroku | |
> git remote add heroku git@heroku.com:YOURAPPNAME.git | |
create a local tracking branch called heroku | |
> git checkout -b heroku -t heroku/master | |
This will checkout the last revision you deployed to Heroku. | |
Now tell git to push the heroku branch to heroku/master |
/* | |
Copyright (c) 2017 Chris Patuzzo | |
https://twitter.com/chrispatuzzo | |
Permission is hereby granted, free of charge, to any person obtaining a copy | |
of this software and associated documentation files (the "Software"), to deal | |
in the Software without restriction, including without limitation the rights | |
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | |
copies of the Software, and to permit persons to whom the Software is | |
furnished to do so, subject to the following conditions: |
" Using "g*" does two things differently from the normal "*": | |
" | |
" - Doesn't move the cursor, simply sets the match | |
" - When moving the cursor with "n" and "N", positions it where it was on the original word. | |
" | |
" Note: g* is ordinarily taken, see :help g* | |
" | |
nnoremap g* :call <SID>SmartStar()<cr> | |
function! s:SmartStar() |
Some scripts/configurations that greatly improve tmux/vim workflows. The shell scripts target zsh but should be adaptable without much effort for other unix shells.
Features:
- Transparently move between tmux panes and vim windows
- Using the shell, open files in one vim instance per project or directory
- Fully integrated copy/paste between tmux, vim and x11 using simple keybinds(need to install the xclip program)
- Easily send text to any tmux pane without breaking your edit workflow(needs slimux
'vim-tmux-move.zsh', '.vimrc' and '.tmux.conf' cooperate so you can move transparently between tmux panes and vim windows using ALT + (arrow keys or jkhl). It was based on this gist
I use tmux splits (panes). Inside one of these panes there's a Vim process, and it has its own splits (windows).
In Vim I have key bindings C-h/j/k/l
set to switch windows in the given direction. (Vim default mappings for windows switching are the same, but prefixed with C-W
.) I'd like to use the same keystrokes for switching tmux panes.
An extra goal that I've solved with a dirty hack is to toggle between last active panes with C-\
.
Here's how it should work: