Skip to content
ZLE widgets of fzf
Branch: master
Clone or download
ytet5uy4 Merge pull request #34 from ytet5uy4/remove-space
Remove space from the end of line
Latest commit cf19c0b Nov 22, 2017
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
.github Add issue template and pull request template Mar 12, 2017
autoload Remove space from the end of line Nov 22, 2017
LICENSE.md initial commit Jan 3, 2017
README.md
init.zsh Fix #28 Jun 14, 2017

README.md

fzf-widgets - ZLE widgets of fzf

Overview | Installation | Requirements | Usage | Configuration | License

license-badge release-badge

Overview

This repository manage ZLE widgets of fzf. Available widgets can check here.

screenshot

Pros

  • Can map widgets to whatever key you like
  • Can easily install with plugin manager
  • Can use with zsh-autosuggestions
  • Show error messages with $POSTDISPLAY
  • All widgets are autoloaded function

Installation

You can install with plugin manager. If use zplug, add the following to your .zshrc:

zplug 'ytet5uy4/fzf-widgets'

Requirements

zsh: version 5.0.2 or higher

Usage

  1. Map widgets to key with bindkey command
  2. Execute widget with mapped key

Configuration

You can map widgets to key and specify options of fzf to widgets. For example, add the following to your .zshrc:

if zplug check 'ytet5uy4/fzf-widgets'; then
  # Map widgets to key
  bindkey '^@'  fzf-select-widget
  bindkey '^@.' fzf-edit-dotfiles
  bindkey '^@c' fzf-change-directory
  bindkey '^@n' fzf-change-named-directory
  bindkey '^@f' fzf-edit-files
  bindkey '^@k' fzf-kill-processes
  bindkey '^@s' fzf-exec-ssh
  bindkey '^\'  fzf-change-recent-directory
  bindkey '^r'  fzf-insert-history
  bindkey '^xf' fzf-insert-files
  bindkey '^xd' fzf-insert-directory
  bindkey '^xn' fzf-insert-named-directory

  ## Git
  bindkey '^@g'  fzf-select-git-widget
  bindkey '^@ga' fzf-git-add-files
  bindkey '^@gc' fzf-git-change-repository

  # GitHub
  bindkey '^@h'  fzf-select-github-widget
  bindkey '^@hs' fzf-github-show-issue
  bindkey '^@hc' fzf-github-close-issue

  ## Docker
  bindkey '^@d'  fzf-select-docker-widget
  bindkey '^@dc' fzf-docker-remove-containers
  bindkey '^@di' fzf-docker-remove-images
  bindkey '^@dv' fzf-docker-remove-volumes

  # Enable Exact-match by fzf-insert-history
  FZF_WIDGET_OPTS[insert-history]='--exact'

  # Start fzf in a tmux pane
  FZF_WIDGET_TMUX=1
fi

License

Copyright (c) 2017 ytet5uy4

Released under the MIT License, see LICENSE.md.

You can’t perform that action at this time.