ivy mode support improved

This commit is contained in:
Sameer Rahmani 2016-11-21 15:29:37 +03:30
parent 633dbbb9c7
commit a6b2ec09a1
3 changed files with 21 additions and 9 deletions

View File

@ -6,7 +6,7 @@
(theme themes/color-theme-monokai)
;; Disable abilities which we do not want to load
(disable 'rbenv 'helm 'swiper)
(disable 'rbenv 'helm)
;; Activate these extensions
(activate-extensions 'editor

View File

@ -10,6 +10,10 @@
(depends-on 'ov)
(depends-on 'cheatsheet)
(with-ability ivy
(depends-on 'ivy)
(depends-on 'counsel))
(with-ability ido
(depends-on 'ido)
(depends-on 'ido-ubiquitous)

View File

@ -144,19 +144,27 @@
(helm-mode 1))
;; Swiper ---------------------------------------------------
(ability swiper ()
"Replace default isearch with swiper"
(ability ivy ()
"Completion using ivy."
(require 'ivy)
(ivy-mode 1)
(setq ivy-use-virtual-buffers t)
(global-set-key "\C-s" 'swiper)
(global-set-key "\C-r" 'swiper)
(global-set-key (kbd "C-c C-r") 'ivy-resume)
(global-set-key [f6] 'ivy-resume)
(with-ability ido
(global-set-key (kbd "C-x b") 'ido-switch-buffer)))
(global-set-key (kbd "M-x") 'counsel-M-x)
(global-set-key (kbd "<f1> f") 'counsel-describe-function)
(global-set-key (kbd "<f1> v") 'counsel-describe-variable)
(global-set-key (kbd "<f1> l") 'counsel-load-library)
(global-set-key (kbd "<f2> i") 'counsel-info-lookup-symbol)
(global-set-key (kbd "<f2> u") 'counsel-unicode-char))
;; Swiper ---------------------------------------------------
(ability swiper (ivy)
"Replace default isearch with swiper"
(global-set-key "\C-s" 'swiper)
(global-set-key "\C-r" 'swiper))
;; (with-ability ido
;; (global-set-key (kbd "C-x b") 'ido-switch-buffer)))
;; Session Management ---------------------------------------
(desktop-save-mode 1)