Last active
December 28, 2018 19:49
-
-
Save bravosierrasierra/9c16fd212da2e8b12b9596cfa0fe3320 to your computer and use it in GitHub Desktop.
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
** hydra | |
*** transparency | |
#+begin_src emacs-lisp | |
(defun my--set-transparency (inc) | |
"Increase or decrease the selected frame transparency" | |
(let* ((alpha (frame-parameter (selected-frame) 'alpha)) | |
(next-alpha (cond ((not alpha) 100) | |
((> (- alpha inc) 100) 100) | |
((< (- alpha inc) 0) 0) | |
(t (- alpha inc))))) | |
(set-frame-parameter (selected-frame) 'alpha next-alpha))) | |
(defhydra hydra-transparency (:columns 2) | |
" | |
ALPHA : [ %(frame-parameter nil 'alpha) ] | |
" | |
("j" (lambda () (interactive) (my--set-transparency +1)) "+ more") | |
("k" (lambda () (interactive) (my--set-transparency -1)) "- less") | |
("J" (lambda () (interactive) (my--set-transparency +10)) "++ more") | |
("K" (lambda () (interactive) (my--set-transparency -10)) "-- less") | |
("=" (lambda (value) (interactive "nTransparency Value 0 - 100 opaque:") | |
(set-frame-parameter (selected-frame) 'alpha value)) "Set to ?" :color blue)) | |
#+end_src | |
*** windows | |
[2017-11-23 Thu 15:25] | |
[[https://www.reddit.com/r/emacs/comments/7evidd/windmove_shortcuts/][windmove shortcuts : emacs]] | |
#+begin_src emacs-lisp | |
;; hydra-window -------------------------------------------- | |
;; | |
;; hydra for managing windows | |
(defhydra hydra-window (:color pink :hint nil :timeout 20) | |
" | |
Move Resize Swap Split | |
╭─────────────────────────────────────────────────────────────────────────────────────────┐ | |
^_<up>_^ ^_C-<up>_^ ^_M-<up>_^ [_v_]ertical | |
^^▲^^ ^^▲^^ ^^▲^^ [_h_]orizontal | |
_<left>_ ◀ ▶ _<right>_ _C-<left>_ ◀ ▶ _C-<right>_ _M-<left>_ ◀ ▶ _M-<right>_ | |
^^▼^^ ^^▼^^ ^^▼^^ ╭──────────┐ | |
^_<down>_^ ^_C-<down>_^ ^_M-<down>_^ quit : [_SPC_] | |
" | |
("<left>" windmove-left) | |
("<down>" windmove-down) | |
("<up>" windmove-up) | |
("<right>" windmove-right) | |
("h" split-window-below) | |
("v" split-window-right) | |
("C-<up>" hydra-move-splitter-up) | |
("C-<down>" hydra-move-splitter-down) | |
("C-<left>" hydra-move-splitter-left) | |
("C-<right>" hydra-move-splitter-right) | |
("M-<up>" buf-move-up) | |
("M-<down>" buf-move-down) | |
("M-<left>" buf-move-left) | |
("M-<right>" buf-move-right) | |
("=" text-scale-increase) | |
("-" text-scale-decrease) | |
("t" tile :color blue) | |
("T" transpose-frame "transpose") | |
("i" flip-frame "flip") | |
("o" flop-frame "flop") | |
("r" rotate-frame "rotate") | |
("n" make-frame-command "create frame" :color blue) | |
("k" delete-frame "delete frame" :color blue) | |
("s" delete-other-frames "delete other frames" :color blue) | |
("q" nil "cancel") | |
("SPC" nil)) | |
#+end_src | |
*** rectangle | |
#+begin_src emacs-lisp | |
(defhydra hydra-rectangle (:body-pre (rectangle-mark-mode 1) | |
:color pink | |
:hint nil | |
:post (deactivate-mark)) | |
" | |
^_k_^ _w_ copy _o_pen _N_umber-lines |\\ -,,,--,,_ | |
_h_ _l_ _y_ank _t_ype _e_xchange-point /,`.-'`' .. \-;;,_ | |
^_j_^ _d_ kill _c_lear _r_eset-region-mark |,4- ) )_ .;.( `'-' | |
^^^^ _u_ndo _g_ quit ^ ^ '---''(./..)-'(_\_) | |
" | |
("k" rectangle-previous-line) | |
("j" rectangle-next-line) | |
("h" rectangle-backward-char) | |
("l" rectangle-forward-char) | |
("d" kill-rectangle) ;; C-x r k | |
("y" yank-rectangle) ;; C-x r y | |
("w" copy-rectangle-as-kill) ;; C-x r M-w | |
("o" open-rectangle) ;; C-x r o | |
("t" string-rectangle) ;; C-x r t | |
("c" clear-rectangle) ;; C-x r c | |
("e" rectangle-exchange-point-and-mark) ;; C-x C-x | |
("N" rectangle-number-lines) ;; C-x r N | |
("r" (if (region-active-p) | |
(deactivate-mark) | |
(rectangle-mark-mode 1))) | |
("u" undo nil) | |
("g" nil) | |
("q" nil "cancel" :color blue) | |
) | |
(global-set-key (kbd "<s-f5>") 'hydra-rectangle/body) | |
#+end_src | |
*** smerge | |
[2018-05-31 Thu 22:16] | |
#+begin_src emacs-lisp | |
(setq smerge-command-prefix "s-s") | |
(defhydra smerge-hydra (:color pink :hint nil :timeout 20) | |
" | |
Movement^^^^ Merge Action^^ Other | |
---------------------^^^^ -------------------^^ ----------- | |
[_n_/_p_] next/prev hunk [_b_] keep base [_u_] undo | |
[_j_/_k_] move up/down [_m_] keep mine [_R_] refine | |
^^^^ [_a_] keep all [_q_] quit | |
^^^^ [_o_] keep other | |
^^^^ [_c_] keep current | |
^^^^ [_C_] combine with next | |
" | |
("n" smerge-next) | |
("p" smerge-prev) | |
("k" smerge-prev) | |
("j" evil-next-line) | |
("k" evil-previous-line) | |
("a" smerge-keep-all) | |
("b" smerge-keep-base) | |
("m" smerge-keep-mine) | |
("o" smerge-keep-other) | |
("c" smerge-keep-current) | |
("C" smerge-combine-with-next) | |
("R" smerge-refine) | |
("u" undo-tree-undo) | |
("q" nil :exit t) | |
) | |
#+end_src | |
*** unicode | |
#+begin_src emacs-lisp | |
(defun my/insert-unicode (unicode-name) | |
"Same as C-x 8 enter UNICODE-NAME." | |
(insert-char (cdr (assoc-string unicode-name (ucs-names))))) | |
(global-set-key | |
(kbd "C-x 9") | |
(defhydra hydra-unicode (:hint nil) | |
" | |
Unicode _e_ € _s_ ZERO WIDTH SPACE | |
_f_ ♀ _o_ ° _m_ µ | |
_r_ ♂ _a_ → _c_ © | |
" | |
("e" (my/insert-unicode "EURO SIGN")) | |
("r" (my/insert-unicode "MALE SIGN")) | |
("f" (my/insert-unicode "FEMALE SIGN")) | |
("s" (my/insert-unicode "ZERO WIDTH SPACE")) | |
("o" (my/insert-unicode "DEGREE SIGN")) | |
("a" (my/insert-unicode "RIGHTWARDS ARROW")) | |
("m" (my/insert-unicode "MICRO SIGN")) | |
("c" (my/insert-unicode "COPYRIGHT SIGN")) | |
("q" nil "cancel" :color blue) | |
)) | |
#+end_src | |
*** org-clock | |
:LOGBOOK: | |
CLOCK: [2017-03-30 Thu 11:17]--[2017-03-30 Thu 11:18] => 0:01 | |
:END: | |
https://www.gnu.org/software/emacs/manual/html_node/org/Clocking-commands.html | |
#+begin_src emacs-lisp | |
;; (defhydra hydra-org-clock (:color blue :hint nil) | |
(defhydra hydra-org-clock (:hint nil) | |
" | |
^Clock:^ ^In/out^ ^Edit^ ^Summary^ | ^Timers:^ ^Run^ ^Insert | |
-^-^-----^-^----------^-^------^-^----------|--^-^------^-^-------------^------ | |
(_?_) _i_n _e_dit _g_oto entry | (_z_) _r_elative ti_m_e | |
^ ^ _c_ontinue _Q_uit _d_isplay | ^ ^ cou_n_tdown it_E_m | |
^ ^ _o_ut ^ ^ _R_eport | ^ ^ _p_ause toggle | |
^ ^ h_I_story ^ ^ ^ ^ | ^ ^ _s_top | |
------------------------------------------------------------------------------ | |
^Pomodoro:^ | |
_k_icker state: %(if org-pomodoro-plus-kicker-enabled \"Enabled\" \"Disabled\") _t_icking state: %(if (get-process org-pomodoro-plus-ticktack-process-name) \"Enabled\" \"Disabled\") | |
" | |
("t" (if (get-process org-pomodoro-plus-ticktack-process-name) (org-pomodoro-plus-stop-ticking) (org-pomodoro-plus-restore-ticking))) | |
("k" (if org-pomodoro-plus-kicker-enabled (pomodoro-kicker-timer-mode-stop) (pomodoro-kicker-timer-mode-start))) | |
("i" org-clock-in) | |
;; ("I" (lambda () (interactive) (let ((current-prefix-arg '(4))) ((org-clock-in))))) | |
("I" (org-clock-in '(4) t)) | |
("c" org-clock-in-last) | |
("o" org-clock-out) | |
("e" org-clock-modify-effort-estimate) | |
("Q" org-clock-cancel) | |
("g" org-clock-goto) | |
("d" org-clock-display) | |
("R" org-clock-report) | |
("?" (org-info "Clocking commands")) | |
;; ("k" pomodoro-kicker-timer-mode-start) | |
;; ("K" pomodoro-kicker-timer-mode-stop) | |
("D" org-pomodoro-plus-stop-ticking) | |
("E" org-pomodoro-plus-restore-ticking) | |
("r" org-timer-start) | |
("n" org-timer-set-timer) | |
("p" org-timer-pause-or-continue) | |
("s" org-timer-stop) | |
("m" org-timer) | |
("E" org-timer-item) | |
("z" (org-info "Timers"))) | |
(bind-key "C-c w" 'hydra-org-clock/body) | |
#+end_src | |
*** org-hydra | |
:LOGBOOK: | |
:END: | |
https://www.gnu.org/software/emacs/manual/html_node/org/Clocking-commands.html | |
#+begin_src emacs-lisp | |
(defhydra hydra-org-hydra (:color blue :hint nil) | |
" | |
^Clock:^ ^In/out^ ^Edit^ ^Summary^ | ^Timers:^ ^Run^ ^Insert | |
-^-^-----^-^----------^-^------^-^----------|--^-^------^-^-------------^------ | |
(_?_) _i_n _e_dit _g_oto entry | (_z_) _r_elative ti_m_e | |
^ ^ _c_ontinue _q_uit _d_isplay | ^ ^ cou_n_tdown i_t_em | |
^ ^ _o_ut ^ ^ _R_eport | ^ ^ _p_ause toggle | |
^ ^ h_I_story ^ ^ ^ ^ | ^ ^ _s_top | |
" | |
("i" org-clock-in) | |
;; ("I" (lambda () (interactive) (let ((current-prefix-arg '(4))) ((org-clock-in))))) | |
("I" (org-clock-in '(4) t)) | |
("c" org-clock-in-last) | |
("o" org-clock-out) | |
("e" org-clock-modify-effort-estimate) | |
("q" org-clock-cancel) | |
("g" org-clock-goto) | |
("d" org-clock-display) | |
("R" org-clock-report) | |
("?" (org-info "Clocking commands")) | |
("r" org-timer-start) | |
("n" org-timer-set-timer) | |
("p" org-timer-pause-or-continue) | |
("s" org-timer-stop) | |
("m" org-timer) | |
("t" org-timer-item) | |
("z" (org-info "Timers"))) | |
(bind-key "C-c w" 'hydra-org-clock/body) | |
#+end_src | |
*** errors | |
[2017-12-23 Sat 09:15] | |
#+begin_src emacs-lisp | |
(defhydra hydra-errors () | |
("c" counsel-flycheck :color blue) | |
("<up>" flycheck-previous-error "previous error") | |
("<down>" flycheck-next-error "next error") | |
("<left>" previous-error "previous error") | |
("<right>" next-error "next error") | |
("q" nil "cancel")) | |
;; (global-set-key (kbd "C-q") 'hydra-errors/body) | |
#+end_src | |
*** history | |
[2017-12-23 Sat 09:17] | |
#+begin_src emacs-lisp | |
(defhydra hydra-history () | |
("y" counsel-yank-pop) | |
("m" counsel-mark-ring) | |
("c" counsel-command-history) | |
("e" counsel-expression-history) | |
("p" counsel-package) | |
("b" backup-walker-start) | |
("q" nil "cancel")) | |
;; (global-set-key (kbd "<f9>") 'hydra-history/body) | |
#+end_src | |
*** hydra-org-global | |
#+begin_src emacs-lisp | |
;;TODO: update docstring | |
(defhydra hydra-org-global (:color green :idle 1.0) | |
" | |
^Control^ ^Editing^ ^Context^ ^Movement^ | |
--------------------------------------------------------------------------------------------------------- | |
_g_oto clock captur_e_ _a_genda _<right>_ next visible heading | |
_._ clock in _w_ store link dash_b_oard _<left>_ prev visible heading | |
_,_ clock out _y_ank link re_v_eal _<down>_ forward same level | |
_\^_ recently clocked _S_et property _f_ ace-link _<up>_ backward same level | |
_c_ancel clock _D_elete property _n_arrow to subtree heading _u_p | |
_d_isplay clocktime footnote _A_ction _-_ sparse tree recent _H_eadings | |
_R_eport clocks _r_efile agenda _h_eadings Org _G_oto | |
_p_omodoro create _T_able _=_ todo tree | |
_s_chedule _2_ random agenda | |
_|_ deadline | |
_i_ add time to TS | |
_t_oggle TS type | |
_\?_ clocking commands | |
" | |
("g" org-clock-goto) | |
("." org-clock-in) | |
("," org-clock-out) | |
("^" org-mru-clock-select-recent-task) | |
("c" org-clock-cancel) | |
("d" org-clock-display) | |
("R" org-clock-report) | |
("p" org-pomodoro) | |
("s" org-schedule :color blue) | |
("|" org-deadline :color blue) | |
("i" custom/org-update-timestamp-with-time) | |
("t" org-toggle-timestamp-type) | |
("e" org-capture :color blue) | |
("w" org-store-link) | |
("y" org-insert-link-global) | |
("S" org-set-property) | |
("D" org-delete-property) | |
("A" org-footnote-action) | |
("r" org-refile "refile") | |
("T" org-table-create) | |
("a" org-agenda :color blue) | |
("b" org-dashboard-display :color blue) | |
("v" org-reveal "reveal") | |
("f" ace-link-org :color blue) | |
("n" org-narrow-to-subtree) | |
("-" org-sparse-tree) | |
("h" counsel-org-agenda-headlines) | |
("H" org-recent-headings-ivy) | |
("=" org-show-todo-tree) | |
("\\" counsel-org-tag) | |
("2" custom/jump-to-custom-agenda-random "show random custom agenda") | |
("<right>" outline-next-visible-heading "next heading") | |
("<left>" outline-previous-visible-heading "prev heading") | |
("<down>" org-forward-heading-same-level "next heading at same level") | |
("<up>" org-backward-heading-same-level "prev heading at same level") | |
("u" outline-up-heading "up heading") | |
("G" org-goto "goto" :exit t) | |
(";" custom/org-tags-all :exit t) | |
("?" (org-info "Clocking commands") "") | |
("q" nil "cancel")) | |
(global-set-key (kbd "<f7>") 'hydra-org-global/body) | |
#+end_src | |
*** macros | |
#+begin_src emacs-lisp | |
(defhydra hydra-macro (:hint nil :color pink :pre | |
(when defining-kbd-macro | |
(kmacro-end-macro 1))) | |
" | |
^Create-Cycle^ ^Basic^ ^Insert^ ^Save^ ^Edit^ | |
╭─────────────────────────────────────────────────────────────────────────╯ | |
^_k_^ [_e_] execute [_n_] insert [_b_] name [_'_] previous | |
^^↑^^ [_d_] delete [_t_] set [_K_] key [_,_] last | |
_h_ ← → _l_ [_o_] edit [_a_] add [_x_] register | |
^^↓^^ [_r_] region [_f_] format [_B_] defun | |
^_j_^ [_m_] step | |
^^ ^^ [_s_] swap | |
" | |
("h" kmacro-start-macro :color blue) | |
("l" kmacro-end-or-call-macro-repeat) | |
("k" kmacro-cycle-ring-previous) | |
("j" kmacro-cycle-ring-next) | |
("r" apply-macro-to-region-lines) | |
("d" kmacro-delete-ring-head) | |
("e" kmacro-end-or-call-macro-repeat) | |
("o" kmacro-edit-macro-repeat) | |
("m" kmacro-step-edit-macro) | |
("s" kmacro-swap-ring) | |
("n" kmacro-insert-counter) | |
("t" kmacro-set-counter) | |
("a" kmacro-add-counter) | |
("f" kmacro-set-format) | |
("b" kmacro-name-last-macro) | |
("K" kmacro-bind-to-key) | |
("B" insert-kbd-macro) | |
("x" kmacro-to-register) | |
("'" kmacro-edit-macro) | |
("," edit-kbd-macro) | |
("q" nil :color blue)) | |
#+end_src | |
*** help apropos | |
#+begin_src emacs-lisp | |
(defhydra hydra-apropos (:color blue) | |
" | |
Apropos | |
--------------- | |
_a_s it is =) | |
_d_ocumentation | |
_v_ariable | |
_c_ommand | |
_l_ibrary | |
_u_ser option | |
_i_nfo | |
_t_ags | |
valu_e_ | |
" | |
("a" apropos) | |
("d" apropos-documentation) | |
("v" apropos-variable) | |
("c" apropos-command) | |
("l" apropos-library) | |
("u" apropos-user-option) | |
("i" info-apropos "info") | |
("t" tags-apropos "tags") | |
("e" apropos-value)) | |
(global-set-key (kbd "C-h a") 'hydra-apropos/body) | |
#+end_src | |
*** edit | |
#+begin_src emacs-lisp | |
(defhydra hydra-edit (:color blue :idle 1.0) | |
" | |
Editing Kill/yank Buffers | |
------------------------------------------------------------------------------------- | |
just _o_ne space between _y_ank to register _`_ redraw display | |
_2_ duplicate + comment _p_ut from register create _S_cratch | |
_/_ make comment box _f_ilename -> clipboard _d_iff buffer <-> file | |
_SPC_ untabify _k_ yank rectangle re_n_ame buffer+file | |
_TAB_ tabify append next _K_ill query/replace rege_x_p | |
delete trailing _w_hitespaces _a_ppend cited region | |
_s_ort lines | |
keep _u_nique lines | |
_4_ snakehump TAP | |
Custom: | |
_i_nsert current date+time | |
_t_ranslate TAP with Google | |
_T_ranslate query with Google | |
" | |
("o" just-one-space) | |
("2" crux-duplicate-and-comment-current-line-or-region) | |
("/" comment-box) | |
("SPC" untabify) | |
("TAB" tabify) | |
("w" delete-trailing-whitespace) | |
("s" sort-lines) | |
("u" delete-duplicate-lines) | |
("4" snakehump-next-at-point) | |
("r" rebox-dwim :color blue) | |
("c" rebox-cycle "cycle box styles") | |
("y" copy-to-register) | |
("p" insert-register) | |
("f" custom/copy-file-name-to-clipboard) | |
("k" custom/kill-save-rectangle) | |
("K" append-next-kill) | |
("a" custom/append-cited-region) | |
("`" redraw-display) | |
("S" scratch) | |
("d" diff-buffer-with-file) | |
("n" crux-rename-file-and-buffer) | |
("x" query-replace-regexp) | |
("i" custom/insert-current-date-time) | |
("t" google-translate-at-point) | |
("T" google-translate-query-translate) | |
("q" nil "cancel")) | |
;; (global-set-key (kbd "C-z") 'hydra-edit/body) | |
#+end_src | |
*** toggle | |
#+begin_src emacs-lisp | |
(defhydra hydra-toggle (:color blue) | |
" | |
TOGGLE: de_b_ug on error (%(format \"%S\" debug-on-error)) | |
_w_hitespace mode | |
" | |
("b" toggle-debug-on-error "debug on error") | |
("w" whitespace-mode "whitespace mode") | |
("W" global-whitespace-mode "*global* whitespace mode") | |
("B" subword-mode) | |
("v" view-mode) | |
("h" highlight-sexp-mode "toggle highlight-sexp mode") | |
("q" toggle-debug-on-quit "toggle debug-on-quit mode") | |
("p" toggle-projectile-global-mode "toggle projectile-global-mode")) | |
;; (global-set-key (kbd "<f11>") 'hydra-toggle/body) | |
#+end_src | |
*** navigate | |
[2017-12-23 Sat 09:19] | |
#+begin_src emacs-lisp | |
(defhydra hydra-navigate () | |
" | |
Locate Narrow/widen Links | |
----------------------------------------------------------------------- | |
_i_ search TAP _r_egion _f_ hint & open | |
_o_ search query _d_efun _y_ hint & copy | |
<prior> URL backward defun + _C_omments select w_3_m buffer | |
<next> URL forward _w_iden open _u_rls in region | |
_>_ reposition buffer recursive _N_arrow DWIM | |
counsel-_I_menu recursive wi_D_en DWIM | |
_<return>_ Execute TAP | |
" | |
("i" (lambda () (interactive) (swiper (thing-at-point 'symbol))) :color blue) | |
("o" (lambda () (interactive) (swiper "")) :color blue) | |
("<prior>" custom/find-url-backward "previous url") | |
("<next>" custom/find-url-forward "next url") | |
(">" reposition-window :color blue) | |
("r" narrow-to-region :color blue) | |
("d" narrow-to-defun :color blue) | |
("C" narrow-to-defun+comments-above :color blue) | |
("w" widen :color blue) | |
("N" recursive-narrow-or-widen-dwim) | |
("D" recursive-widen-dwim) | |
("f" link-hint-open-link :color blue) | |
("y" link-hint-copy-link :color blue) | |
("3" w3m-select-buffer :color blue) | |
("u" custom/open-urls-in-region :color blue) | |
("I" counsel-imenu :color blue) | |
("<return>" custom/process-thing-at-point "execute ;)" :color blue)) | |
;; (global-set-key (kbd "<f3>") 'hydra-navigate/body) | |
#+end_src | |
*** vcs | |
#+BEGIN_SRC emacs-lisp | |
(defhydra hydra-vcs (:color red) | |
" | |
PROJECT: %(projectile-project-root) | |
Magit Additional | |
----------------------------------------- | |
_g_: status _k_ smerge / goto prev conflict | |
_l_: log _j_ smerge / goto next conflict | |
_f_: file log _l_ Show repositories _l_ist | |
_r_: reflog | |
_w_: diff worktree | |
_t_: time machine | |
_B_: blame | |
_c_: checkout | |
_b_: branch mgr | |
" | |
("g" magit-status :color blue) | |
("f" magit-log-buffer-file :color blue) | |
("c" magit-checkout :color blue) | |
("w" magit-diff-working-tree :color blue) | |
("r" magit-reflog :color blue) | |
("B" magit-blame :color blue) | |
("b" magit-branch-popup :color blue) | |
("l" magit-log :color blue) | |
("t" git-timemachine :color blue) | |
("k" smerge-prev "previous conflict") | |
("j" smerge-next "next conflict") | |
("l" open-global-repos-list :color blue)) | |
(define-key org-mode-map (kbd "C-'") nil) | |
(global-set-key (kbd "C-'") 'hydra-vcs/body) | |
#+END_SRC | |
*** projectile hydra | |
#+begin_src emacs-lisp | |
(defhydra hydra-projectile-other-window (:color teal) | |
"projectile-other-window" | |
("f" projectile-find-file-other-window "file") | |
("g" projectile-find-file-dwim-other-window "file dwim") | |
("d" projectile-find-dir-other-window "dir") | |
("b" projectile-switch-to-buffer-other-window "buffer") | |
("q" nil "cancel" :color blue)) | |
(defhydra hydra-projectile (:color green | |
:hint nil) | |
" | |
PROJECTILE: %(projectile-project-root) | |
Find File Search/Tags Buffers Cache | |
------------------------------------------------------------------------------------------ | |
_f_: file _a_: ag _i_: Ibuffer _c_: cache clear | |
_F_: file (other win) _t_: update gtags _b_: switch to buffer _x_: remove known project | |
_r_: recent file _o_: multi-occur _K_: Kill all buffers _X_: cleanup non-existing | |
_d_: dir (counsel) _g_: grep (counsel) _s_: switch project ^^^^_z_: cache current | |
_D_: dir _G_: grep | |
" | |
("a" counsel-projectile-ag) | |
("b" projectile-switch-to-buffer) | |
("c" projectile-invalidate-cache) | |
("d" counsel-projectile-find-dir) | |
("D" projectile-find-dir) | |
("f" counsel-projectile-find-file) | |
("F" projectile-find-file-other-window) | |
("t" ggtags-update-tags) | |
("i" projectile-ibuffer) | |
("K" projectile-kill-buffers) | |
("m" projectile-multi-occur) | |
("g" counsel-projectile-grep) | |
("G" projectile-grep) | |
("o" projectile-multi-occur) | |
("s" projectile-switch-project) | |
("r" projectile-recentf) | |
("x" projectile-remove-known-project) | |
("X" projectile-cleanup-known-projects) | |
("z" projectile-cache-current-file) | |
("`" hydra-projectile-other-window/body "other window") | |
("q" nil "cancel" :color blue)) | |
(global-set-key (kbd "<C-f5>") 'hydra-projectile/body) | |
;; https://github.com/abo-abo/hydra/wiki/Projectile-%26-Fixmee | |
(defhydra hydra-project (:color blue :hint nil :idle 0.4) | |
" | |
PROJECTILE: %(projectile-project-root) | |
╭────────────┐ | |
Files Search Buffer Do │ Projectile │ | |
╭─────────────────────────────────────────────────────────────────────┴────────────╯ | |
[_f_] file [_a_] ag [_b_] switch [_m_] magit/vcs | |
[_l_] file dwim [_g_] grep (counsel) [_v_] show all [_p_] commander | |
[_r_] recent file [_G_] grep [_V_] ibuffer [_P_] switch project | |
[_d_] dir [_s_] occur [_K_] kill all [_i_] info | |
[_o_] other [_S_] replace | |
[_u_] test file [_t_] find tag | |
[_h_] root (dired) [_T_] make tags | |
╭────────┐ | |
Other Window Run Cache Do │ Fixmee │ | |
╭──────────────────────────────────────────────────╯ ╭────────────────┴────────╯ | |
[_F_] file [_U_] test [_kc_] clear [_x_] TODO & FIXME | |
[_L_] dwim [_M_] compile [_kk_] add current [_X_] toggle | |
[_D_] dir [_c_] shell [_ks_] cleanup | |
[_O_] other [_C_] command [_kd_] remove | |
[_B_] buffer | |
-------------------------------------------------------------------------------- | |
" | |
("<tab>" hydra-master/body "back") | |
("<ESC>" nil "quit") | |
("a" projectile-ag) | |
("g" counsel-projectile-grep) | |
("G" projectile-grep) | |
("b" projectile-switch-to-buffer) | |
("B" projectile-switch-to-buffer-other-window) | |
("c" projectile-run-async-shell-command-in-root) | |
("C" projectile-run-command-in-root) | |
("d" counsel-projectile-find-dir) | |
("D" projectile-find-dir-other-window) | |
("f" counsel-projectile-find-file) | |
("F" projectile-find-file-other-window) | |
("m" projectile-vc) | |
("h" projectile-dired) | |
("i" projectile-project-info) | |
("kc" projectile-invalidate-cache) | |
("kd" projectile-remove-known-project) | |
("kk" projectile-cache-current-file) | |
("K" projectile-kill-buffers) | |
("ks" projectile-cleanup-known-projects) | |
("l" projectile-find-file-dwim) | |
("L" projectile-find-file-dwim-other-window) | |
("M" projectile-compile-project) | |
("o" projectile-find-other-file) | |
("O" projectile-find-other-file-other-window) | |
("p" projectile-commander) | |
("P" projectile-switch-project) | |
("r" projectile-recentf) | |
("s" projectile-multi-occur) | |
("S" projectile-replace) | |
("t" projectile-find-tag) | |
("T" projectile-regenerate-tags) | |
("u" projectile-find-test-file) | |
("U" projectile-test-project) | |
("v" projectile-display-buffer) | |
("V" projectile-ibuffer) | |
("X" fixmee-mode) | |
("x" fixmee-view-listing)) | |
(global-set-key (kbd "<f5>") 'hydra-project/body) | |
#+end_src | |
(defhydra hydra-projects (:color green :idle 1.0) | |
" | |
PROJECT: %(projectile-project-root) | |
Project More Search | |
-------------------------------------------------------------------------------- | |
_i_nvalidate cache _c_ommander _r_egexp | |
_I_buffer _d_ired a_g_ | |
_k_ill buffers recent_f_ _m_ulti-swoop | |
_s_witch project | |
_h_elm-projectile | |
" | |
("I" ibuffer) | |
("i" projectile-invalidate-cache) | |
("k" projectile-kill-buffers) | |
("c" projectile-commander) | |
("d" projectile-dired) | |
("f" projectile-recentf) | |
("s" projectile-switch-project) | |
("h" projectile-find-file) | |
("r" socyl-search-regexp) | |
("g" counsel-rg) | |
("G" (lambda () (interactive) | |
(counsel-rg (thing-at-point 'symbol) (projectile-project-root)))) | |
("l" counsel-git-log) | |
("m" swiper-multi)) | |
;; (global-set-key (kbd "<f10>") 'hydra-projects/body) | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment