Skip to content

Commit

Permalink
Modify some files
Browse files Browse the repository at this point in the history
  • Loading branch information
ssh0 committed Feb 22, 2018
1 parent bb143d4 commit 8f3d1b5
Show file tree
Hide file tree
Showing 7 changed files with 37 additions and 9 deletions.
1 change: 1 addition & 0 deletions dotlink
Original file line number Diff line number Diff line change
Expand Up @@ -208,6 +208,7 @@ zshfiles/functions/completion.zsh, .zsh/functions/completion.zsh
zshfiles/functions/confirm.zsh, .zsh/functions/confirm.zsh
zshfiles/functions/environment.zsh, .zsh/functions/environment.zsh
zshfiles/functions/extract.zsh, .zsh/functions/extract.zsh
zshfiles/functions/fkill.zsh, .zsh/functions/fkill.zsh
zshfiles/functions/git.zsh, .zsh/functions/git.zsh
zshfiles/functions/history.zsh, .zsh/functions/history.zsh
zshfiles/functions/less.zsh, .zsh/functions/less.zsh
Expand Down
4 changes: 2 additions & 2 deletions dotlink.mac
Original file line number Diff line number Diff line change
Expand Up @@ -363,8 +363,8 @@ mpd/mpd.conf, .config/mpd/mpd.conf
#==============================================================================
# ncmpcpp – featureful ncurses based MPD client inspired by ncmpc

ncmpcpp/${PC}config, .ncmpcpp/config
ncmpcpp/keys, .ncmpcpp/keys
ncmpcpp/mac/config, .ncmpcpp/config
ncmpcpp/mac/bindings, .ncmpcpp/bindings
ncmpcpp/scripts/ncmpcpp_notification.sh, .ncmpcpp/scripts/ncmpcpp_notification.sh

#===========================================================================}}}
Expand Down
14 changes: 12 additions & 2 deletions ranger/mac/rc.conf
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,7 @@ set vcs_aware false
set vcs_backend_git enabled
set vcs_backend_hg disabled
set vcs_backend_bzr disabled
set vcs_backend_svn disabled

# Use one of the supported image preview protocols
set preview_images true
Expand All @@ -80,6 +81,10 @@ set preview_images true
# (http://iterm2.com/images.html). This requires using iTerm2 compiled
# with image preview support.
#
# This feature relies on the dimensions of the terminal's font. By default, a
# width of 8 and height of 11 are used. To use other values, set the options
# iterm2_font_width and iterm2_font_height to the desired values.
#
# * urxvt:
# Preview images in full color using urxvt image backgrounds. This
# requires using urxvt compiled with pixbuf support.
Expand All @@ -89,6 +94,10 @@ set preview_images true
# whole terminal window.
set preview_images_method iterm2

# Default iTerm2 font size (see: preview_images_method: iterm2)
set iterm2_font_width 8
set iterm2_font_height 11

# Use a unicode "..." character to mark cut-off filenames?
set unicode_ellipsis false

Expand Down Expand Up @@ -199,8 +208,9 @@ set cd_bookmarks true
# Changes case sensitivity for the cd command tab completion
set cd_tab_case sensitive

# Use smart tab completion with less typing? E.g. ":cd /f/b/b<tab>" yields ":cd /foo/bar/baz".
set cd_tab_smart false
# Use fuzzy tab completion with the "cd" command. For example,
# ":cd /u/lo/b<tab>" expands to ":cd /usr/local/bin".
set cd_tab_fuzzy false

# Avoid previewing files larger than this size, in bytes. Use a value of 0 to
# disable this feature.
Expand Down
10 changes: 5 additions & 5 deletions ranger/mac/rifle.conf
Original file line number Diff line number Diff line change
Expand Up @@ -81,13 +81,13 @@ ext x?html?, has links, terminal = links "$@"
# ext x?html?, has lynx, terminal = lynx -- "$@"
# ext x?html?, has w3m, terminal = w3m "$@"

ext gslides|gsheet, X, flag f = open -a Google\ Drive\ File\ Stream "$@"
ext gslides|gsheet, X, flag f = open "$@"

#---------------------------------------------------------------------------}}}
# Misc {{{
#------------------------------------------------------------------------------
# Define the "editor" for text files as first action
mime ^text, label editor = $EDITOR -- "$@"
mime ^text, label editor = ${VISUAL:-$EDITOR} -- "$@"
mime ^text, label pager = "$PAGER" -- "$@"
ext csv|tsv, has vd = vd -- "$@"
ext csv|tsv, has tad, X, flag f = tad -- "$@"
Expand Down Expand Up @@ -130,7 +130,7 @@ mime ^video, has mplayer2, X, flag f = mplayer2 -- "$@"
mime ^video, has mplayer2, X, flag f = mplayer2 -fs -- "$@"
mime ^video, has mplayer, X, flag f = mplayer -- "$@"
mime ^video, has mplayer, X, flag f = mplayer -fs -- "$@"
mime ^video, X, flag f = open "$@"
mime ^video, has open X, flag f = open "$@"
mime ^video|audio, has vlc, X, flag f = vlc -- "$@"
mime ^video|audio, has totem, X, flag f = totem -- "$@"
mime ^video|audio, has totem, X, flag f = totem --fullscreen -- "$@"
Expand All @@ -156,7 +156,7 @@ ext pdf, has atril, X, flag f = atril -- "$@"
ext pdf, has okular, X, flag f = okular -- "$@"
ext pdf, has epdfview, X, flag f = epdfview -- "$@"
ext pdf, has qpdfview, X, flag f = qpdfview "$@"
ext pdf, X, flag f = open "$@"
ext pdf, has open, X, flag f = open "$@"

ext docx?, has catdoc, terminal = catdoc -- "$@" | "$PAGER"

Expand Down Expand Up @@ -230,7 +230,7 @@ label wallpaper, number 14, mime ^image, has feh, X = feh --bg-fill "$1"

# Define the editor for non-text files + pager as last action
!mime ^text, !ext xml|json|csv|tex|py|pl|rb|js|sh|php = ask
label editor, !mime ^text, !ext xml|json|csv|tex|py|pl|rb|js|sh|php = $EDITOR -- "$@"
label editor, !mime ^text, !ext xml|json|csv|tex|py|pl|rb|js|sh|php = ${VISUAL:-$EDITOR} -- "$@"
label pager, !mime ^text, !ext xml|json|csv|tex|py|pl|rb|js|sh|php = "$PAGER" -- "$@"

#---------------------------------------------------------------------------}}}
Expand Down
1 change: 1 addition & 0 deletions zshfiles/functions/alias.mac.zsh
Original file line number Diff line number Diff line change
Expand Up @@ -131,6 +131,7 @@ _ec plug ~/.config/nvim/plug.vim
_ec prompt ${ZSH_ROOT}/functions/prompt.zsh
_ec ranger ~/.config/ranger/rc.conf
_ec ranger.d ~/.config/ranger
_ec ssh ~/.ssh/config
_ec s ~/bin/s_provider
_ec tig ~/.tigrc
_ec tmux ~/.tmux.conf
Expand Down
15 changes: 15 additions & 0 deletions zshfiles/functions/fkill.zsh
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
# vim: set ft=zsh
#=#=#=
# Kill process
#
# fuzzy process search -> kill the selected processes
#=#=
function fkill() {
local pid
pid=$(ps -ef | sed 1d | fzf -m | awk '{print $2}')

if [ "x$pid" != "x" ]
then
echo $pid | xargs kill -${1:-9}
fi
}
1 change: 1 addition & 0 deletions zshfiles/zshrc
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,7 @@ colorize
command-not-found
confirm
extract
fkill
git
less
ls
Expand Down

0 comments on commit 8f3d1b5

Please sign in to comment.