dotfiles/.bin/devs
2023-02-22 08:31:38 +01:00

16 lines
350 B
Bash
Executable File

#!/bin/sh
. ~/.bin/_config
set -xe
[ ! -z "$1" ] && EXTRA="-q $1"
F=$(find /usr/src /usr/xenocara /usr/www -type f \
-not -path "*/CVS/*" \
-not -path "*/.git/*" \
-not -name "*.orig" \
-not -name "*.git*" \
-not -name "*.cvs*" \
| fzf -e -1 -0 $EXTRA)
R="$(readlink -f "$F")"
test -z "$R" || vim "$R"
echo "$(dirname "$R")"