Skip to content
/ iqa.el Public

(Emacs) Init file (and directory) Quick Access.

Notifications You must be signed in to change notification settings

a13/iqa.el

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

25 Commits
 
 
 
 
 
 

Repository files navigation

Init file(and directory) Quick Access.

https://melpa.org/packages/iqa-badge.svg

Trivia

Sadly, Emacs (unlike Spacemacs, which has spacemacs/find-dotfile) doesn’t have a function to open its own init file, so thousands of users have to write their owns. I’m not different :)

Installation

Using use-package:

(use-package iqa
  ;; use this if your config is generated from org file
  ;; :custom
  ;; (iqa-user-init-file (concat user-emacs-directory "README.org") "Edit README.org by default.")
  ;; bind iqa functions to shortcuts
  :bind (:map ctl-x-map
              ("M-f" . iqa-find-user-init-file)
              ("M-c" . iqa-find-user-custom-file)
              ("M-r" . iqa-reload-user-init-file)
              ("M-d" . iqa-find-user-init-directory))
  ;; :config
  ;; (iqa-add-bookmarks) — to add bookmarks to emacs init files
  ;; (iqa-setup-default) - to bind default bindings
  )

or just put iqa.el to load-path and

(require 'iqa)
(iqa-setup-default)

Info

iqa-find-user-init-file is a shorthand to open user init file. By default user-init-file is used. If your configuration is generated from org-mode source you may want to point it to your org file.

(setq iqa-user-init-file (concat user-emacs-directory "init.org"))

File is opened by find-file but you can redefine it by e.g.

(setq iqa-find-file-function #'find-file-other-window)

iqa-reload-user-init-file reloads user-init-file (not iqa-user-init-file)

For a full restart take a look at restart-emacs package.

iqa-find-user-init-directory opens init file directory

iqa-setup-default defines keybindings:

C-x M-fiqa-find-user-init-file

C-x M-ciqa-find-user-custom-file

C-x M-riqa-reload-user-init-file

C-x M-diqa-find-user-init-directory

If you don’t like these, or prefer to use Emacs bookmarks instead, iqa-add-bookmarks adds bookmarks to these files.

Releases

No releases published

Packages

No packages published