Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/metaory/xfind

Find (F/D) ❯ Filter (SK/FZF) ❯ Preview(CHROMA/BAT/CAT] ❯ Edit($EDITOR) ❯ Repeat ⮔
https://github.com/metaory/xfind

automation cli filter find fzf grep rgrep sk skim

Last synced: about 17 hours ago
JSON representation

Find (F/D) ❯ Filter (SK/FZF) ❯ Preview(CHROMA/BAT/CAT] ❯ Edit($EDITOR) ❯ Repeat ⮔

Awesome Lists containing this project

README

        



X̸FIND


find or


filter with SK or FZF,

preview with Chroma, BatCat

edit with EDITOR

··· repeat ···


```help
NAME ~
xfind - find or , filter with {SK} or {FZF}, preview with {Chroma}, {Bat}, {Cat} and edit with , repeat;

SYNOPSIS ~
xfind [] [-not|--not-path ]...

find files with max depth of 5 and two exclude glob and query glob >
xfind f5 -not '*dist*' -not '**/lib/**' '*repo*.js'
<

DESCRIPTION ~
find, filter, edit, repeat
it will pipe the find result to a {FuzzyTool}
it will look for {SK} and fallback to {FZF}
for Preview of in the {FuzzyTool}, it will look for {Chroma}, {Bat}, {Cat} in that order
for Preview of in the {FuzzyTool}, it will use Tree
on Select the will be invoked with the Selection

EXAMPLES ~
find directories with max depth of 3 and one exclude glob and query glob >
xfind d3 -not '*dist*' '*repo*'
<

find files with max depth of 5 and two exclude glob and query glob >
xfind f5 -not '*dist*' -not '**/lib/**' '*repo*.js'
<

find directories named x11 with default max depth >
xfind D x11
<

find files named xorg with default max depth >
xfind xorg
<
read from stdin >
ls | xfind
<
read from stdin >
git status --short | awk '{print $2}' | xfind
<

ENVIRONMENT VARIABLES ~
XFIND_MAXDEPTH | default max-depth
XFIND_SILENT | Silent Query & Result Prints (0 or 1)

SEE ALSO
find(1), fzf(1), locate(1)

AUTHOR
metaory , Mar 2024
```

CONFIGURATION
-------------

- `ctrl-o` toggle-preview
- `ctrl-n` next
- `ctrl-p` previous
- `ctrl-d` preview-page-down
- `ctrl-u` preview-page-up
- `enter` open in `$EDITOR`

Installation
------------

- clone repo
- give execution permissions
- place it in your path

```ex
# Clone the repo
git clone [email protected]:metaory/xfind.git

# Navigate to repo
cd xfind

# Give execution permissions
chmod +x {xfind}

# Link it somewhere in your PATH
ln -svf $PWD/xfind /usr/bin/xfind

# Use it anywhere
xfind f2 '*lib*'

# Usage
xfind --help
```

TODO
====
- [ ] Makefile