ambevar-dotfiles/.config/ranger/rc.conf

70 lines
2.1 KiB
Plaintext
Raw Normal View History

# ===================================================================
# This file contains the default startup commands for ranger.
# To change them, it is recommended to create the file
# ~/.config/ranger/rc.conf and add your custom commands there.
#
# If you copy this whole file there, add this line to your options.py
# so it is not loaded twice:
#
# load_default_rc = False
#
# The purpose of this file is mainly to define keybindings. For
# changing settings or running more complex python code, use the
# configuation file "options.py" or define commands in "commands.py".
#
# Each line is a command that will be run before the user interface
# is initialized. As a result, you can not use commands which rely
# on the UI such as :delete or :mark.
# ===================================================================
# ===================================================================
# == Define keys for the browser
# ===================================================================
# Basic
map ! console shell -w
# For the nostalgics: Midnight Commander bindings
map <F4> bulkrename
map <F5> console shell -w file "%f"
map <F6> console touch
map <F7> console mkdir
map <F8> console delete seriously?
map <F10> exit
# ===================================================================
# == Personal shorcuts
# ===================================================================
## Move to trash (without Trash-CLI)
# map DD shell mv -t ~/.local/share/Trash/files %s
## Move to trash (with Trash-CLI)
map DD shell trash-put -- %s
## Extraction. Ranger uses '1l', but does not work when extension is not
## right. Using atools instead.
map ex shell aunpack -e %s
## Git
map ega shell -w git add %s
map egr shell -w git checkout %s
map egs shell -w git status -uno
## Video
## Note that latin1 for MPlayer is cp1252 in reality.
map ev console shell mplayer "%f" -sub "%s"
map eV console shell mplayer "%f" -sub "%s" -subcp latin1
## Submarine
map es shell -w submarine %f
## Audio
map ea shell cmus-remote -P %s
# Quick moves
map K move up=5
map J move down=5
#map <C-h> tab_move 1
#map <C-l> tab_move -1