Skip to content

Instantly share code, notes, and snippets.

@lorn
Last active October 4, 2015 12:47
Show Gist options
  • Save lorn/2638879 to your computer and use it in GitHub Desktop.
Save lorn/2638879 to your computer and use it in GitHub Desktop.
emacs tips

janelas e buffers

ctrl x+b troca de buffer

ctrl x + ctrl b mostra buffer

ctrl x+o troca de janela

ctrl x+0 ( elimina a janela )

ctrl x+1 ( deixa só a janela atual )

ctrl x+2 ( divide a janela na horizontal )

ctrl x+3 ( divide a jenale na vertial

Edições simples

ctrl + shift + _ ( undo )

ctrl + x + u ( redo )

seleciona todo o codigo ctrl + h + x

alt+d ( deleta palavra )

recorta frase ctrl+k cola ctrl+y

Haskell stuff

( inferior process / inferior lisp/haskell )

shell haskell ctrl c + ctrl l

Dev stuff

tab identa

C-SPC marca linha

Para identar um bloco basta marca-lo com o 'marca linha' e depois:

C-M-\

M-; comenta linha

Escrever em blocos

Blarg! It's simple: use C-x r t -- # http://stackoverflow.com/questions/761706/in-emacs-edit-multiple-lines-at-once

cua-mode

One of the solutions is using CUA mode. Activate cua mode with M-x cua-mode, select rectangle regin: first press C-Enter then move cursor with standard movement commands to make selection, now pressing enter at any time will cycle cursor through corners of the rectangle enabling you to prepend or append text to the selection.

Org-mode

Para atualizar emacs.org em cima do #begin C-c C-c

Live/Phone Meetings

For capturing annotations during meetings outside of IRC, I use org-timer. Start it with C-c C-x 0, move your cursor into the heading where you want to annotate and use C-c C-x – to start a list, pressing M-RET (alt + return) will insert additional items into the list and record the times on each new item. And you get a list like this one:

tags e tarefas

C-c # - Atualiza cache do checkbox

C-c C-t - Muda status da tarefa (TODO/DONE)

C-c C-q - Adiciona Tag

C-c \ - Busca tag

C-c C-c marca task list

Outras coisas

6:21 e digia os espacos, ou vc usa cua-bindings (esse é o jeito mais facil)

6:21 M-x cua-mode

6:22 dai, C-enter

Dos to unix

M-x set-buffer-file-coding-system RET undecided-unix save the file (C-x C-s)

Unix to dos

M-x set-buffer-file-coding-system RET undecided-dos save the file (C-x C-s)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment