/helm-file-preview

Preview the current helm file selection.

Primary LanguageEmacs LispGNU General Public License v3.0GPL-3.0

License: GPL v3 MELPA MELPA Stable

helm-file-preview

Preview the current helm file selection.

CI

Every time uses helm to select the file is what painful to me. Especially when I use other extensions like helm-ag, helm-gtags, dumb-jump, etc. This package help you figure out what the file you are actually pointing to by showing the file in the previous window.

helm-ag helm-gtags

Few differences to helm-follow-mode.

  • Decouple from helm-source.
  • Customize once, works across all packages that use helm's interface.
  • Preview instead of opening files.

Usage

Add these lines to somewhere in your Emacs config.

(require 'helm-file-preview)
(helm-file-preview-mode 1)

Or if you are using use-package.

(use-package helm-file-preview
  :config
  (helm-file-preview-mode 1))

Customization

Turn off this if you want to preview the file no matter what. The default behaviour is the preview action will only occurs when line numbers appears in the selection. For instance, using helm-ag, helm-gtags or any packages that make compatible to helm interface.

(setq helm-file-preview-only-when-line-numbers t)

If you don't want the file to be opened after viewing the file, you can set this variable to t. If you want to leave the file opened then you should set to nil.

(setq helm-file-preview-preview-only t)

Contribute

PRs Welcome Elisp styleguide Donate on paypal

If you would like to contribute to this project, you may either clone and make pull requests to this repository. Or you can clone the project and establish your own branch of this tool. Any methods are welcome!