Skip to content

Instantly share code, notes, and snippets.

View renatosuero's full-sized avatar

Renato Suero renatosuero

View GitHub Profile
CREATE OR REPLACE FUNCTION public.clone_schema(
source_schema text,
dest_schema text)
RETURNS void AS
$BODY$
DECLARE
object text;
buffer text;
default_ text;
column_ text;
@renatosuero
renatosuero / mode-keys.md
Created March 27, 2016 13:51
Tabela com as teclas para o mode Vi e Emacs
Function vi emacs
Append selection A
Back to indentation ^ M-m
Bottom of history G M-<
Clear selection Escape C-g
Copy selection Enter M-w
Copy to named buffer "
Cursor down j Down
Cursor left h Left
CREATE OR REPLACE FUNCTION public.migrate_schema(change text)
RETURNS integer AS
$BODY$
DECLARE
v_schema text;
BEGIN
FOR v_schema IN
SELECT quote_ident(nspname)
FROM pg_namespace n
@renatosuero
renatosuero / vairables.md
Created March 27, 2016 13:38
Variáveis para usar nas opções -format no tmux
Variable name Alias Replaced with
alternate_on If pane is in alternate screen
alternate_saved_x Saved cusor X in alternate screen
alternate_saved_y Saved cursor Y in alternate screen
buffer_sample Sample of start of buffer
buffer_size Size of the specified buffer in bytes
client_activity Integer time client last had activity
client_created Integer time client created
client_control_mode 1 if client is in control mode
# act like GNU screen
unbind C-b
set -g prefix C-a
#Mode Vim
setw -g mode-keys vi
#Delay
set -sg escape-time 1