zo - open folding
za - toggle folding
zc - close folding
zf - create manual folding from selection
| set runtimepath^=~/.vim runtimepath+=~/.vim/after | |
| let &packpath = &runtimepath | |
| source ~/.vimrc | |
| """ | |
| """ EXPERIMENTAL | |
| """ tagbar | |
| """ tern_for_vim | |
| """ vim-obsession | |
| """ ctrlp.vim | |
| """ |
| nnoremap <leader>fa :execute ":! yarn --silent flow type-at-pos --quiet %" line(".") col(".") "\| grep '^type' \| yarn --silent prettier --stdin-filepath test.js"<cr> |
| version: '2' | |
| services: | |
| grafana: | |
| image: grafana/grafana:5.0.0 # or probably any other version | |
| container_name: grafana | |
| restart: always | |
| environment: | |
| - VIRTUAL_HOST=YOUR.DOMAIN.TEST # adjust to match your domain name | |
| - VIRTUAL_PROTO=https |
| " RELOAD WITHOUT closing vim | |
| " :so ~/.vimrc | |
| " | |
| set nocompatible | |
| """"""""""""""""""" | |
| " PLUGINS | |
| """"""""""""""""""" | |
| " Specify a directory for plugins | |
| " - For Neovim: ~/.local/share/nvim/plugged |
| # Load DSL and set up stages | |
| require 'capistrano/setup' | |
| # Include default deployment tasks | |
| require 'capistrano/deploy' | |
| # Include tasks from other gems included in your Gemfile | |
| require 'capistrano/rvm' | |
| require 'capistrano/bundler' | |
| require 'capistrano/rails/assets' |
zo - open folding
za - toggle folding
zc - close folding
zf - create manual folding from selection
function createRoutes() {
function requireLogin(store) {
return (nextState, replaceState) => {
const { users: { user }} = store.getState();
if (_.isEmpty(user)) { // or any other authentication condition
replaceState({ nextPathname: nextState.location.pathname }, '/');Full live (client side) validation, "developed" to use with simple_form and foundation markup (should work in other cases too).
Create separate .coffee file e.g. client_side_select2.js.coffee with following code:
# Add select2 support
ClientSideValidations.selectors.validate_inputs += ', select[data-select2-validate]'
ClientSideValidations.selectors.inputs += ', .select2-container'| #! /usr/bin/env ruby | |
| # Modified from : http://www.tkalin.com/blog_posts/using-console-vim-as-vim-protocol-handler-in-ubuntu | |
| # NOTE: This opens with a link to the mvim protocol for compatibility with RailsPanel | |
| # goes to /usr/local/bin/cvim | |
| require 'uri' | |
| require 'cgi' | |
| full_path = ARGV[0] |