Skip to main content

Finja

An awesome hack. Your friendly finding ninja.

Usage

Index and find your stuff.

Index the current directory.

finja --index

Find huhu in the index.

finja huhu

Update outdated files and find huhu in the index.

finja -u huhu

Also works from a subdirectory.

finja --index
cd subdir
finja huhu

Tip: If you are sure that your system survives till everything is indexed use eatmydata.

eatmydata finja -i

Raw mode is meant for machines, but you can replace the \0 with colons.

finja -r huhu | finjacol

Get reduplicated raw human readable output.

finja -r stuff | finjadup | finjacol

Get reduplicated raw output.

finja -r stuff | finjadup

Index git files only.

git ls-tree -r --name-only master > FINJA.lst
finja -i

Filter unwanted output by path.

finja -p spamfolder gold

Cleanup free (unused) tokens and rebuild the database.

finja --vacuum

If there are some badly formatted files that seriously cramp your style.

finja readlines for | cut -c -`tput cols`

Index stuff in read-only directories.

mkdir sysinclude
cd sysinclude
find /usr/include/ -xdev > FINJA.lst
eatmydata finja -i
finja AF_INET6

Caveat: We do not support languages that don’t do spaces nor interpunct. Hey we are not google!

Using in vim/neovim:

#!/bin/sh

finja -r "$@" | finjagrep
  • Set finjaack as ackprg

let g:ackprg = 'finjack'

Installation

pip install -U finja

Why?

Unlike many of the great alternatives to finja, finja is generic. It doesn’t know what it is indexing. Finja achieves good indexing quality by doing multiple passes with different tokenization methods and splitting character lists. Therefore it is slower and has a bigger index than non-generic indexers, but it just indexes your stuff and won’t miss any files it doesn’t know about.

Finja is doing something wrong, can I customize the settings?

We would like to keep settings to a minimum. At the moment there is only international interpunct, that can be switched on. Please open an issue on Github and describe your problem, we will try to find a generic solution. If we don’t find such a solution we might add a setting.

By ganwell@fangorn.ch and David Vogt, Stefan Heinemann, Pablo Vergés

Changes

1.1.1

  • Ignore empty lines in finjacol/finjagrep

1.1.0

  • Add finjagrep which emulates grep output for usage with ack.vim

1.0.11

  • Add workaround for VACUUM bug in python

  • Multiple version due bugs in packaging (rereleases)

1.0.8

  • Conditionally add the argparse dependancy on python 2.6 (@ganwell)

1.0.7

  • Case-insensitive highlighting (@ganwell)

1.0.6

  • Add argparse as requires for CentOS6 (@Pablo Verges)

  • Add search term coloring (@schtibe)

  • Add finja logo to help (@ganwell)

Metadata

Release files for finja 1.1.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for finja 1.1.1
File Size Uploaded Provenance
finja-1.1.1.tar.gz 13.6 kB Without provenance Details

Built distribution (wheel)

Table of built distributions (wheels) for finja 1.1.1
File Interpreter ABI Platform
finja-1.1.1-py3-none-any.whl Python 3 none any Details

Total release size: 37.2 kB

Release files / finja-1.1.1.tar.gz

Download URL finja-1.1.1.tar.gz
Size 13.6 kB
Tags Source
SHA-256 checksum
How to use checksums
c2a28bff364dac07dc34929af6ca46d6f09ba38e5469b19c9629ba174620b790
BLAKE2b-256 checksum
How to use checksums
4f569ad914c3713a9d836a9664efb69520da8269d47fe86f6794437615efcc9f
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/1.13.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/41.0.1 requests-toolbelt/0.9.1 tqdm/4.32.1 CPython/3.7.3

Release files / finja-1.1.1-py3-none-any.whl

Download URL finja-1.1.1-py3-none-any.whl
Size 23.7 kB
Tags Python 3
SHA-256 checksum
How to use checksums
e13fe5001f12604b5f9970da6a1bf35e5d2da0745fd8343db808661ff14db747
BLAKE2b-256 checksum
How to use checksums
c2752cc1df58fc1f195234ca75528635dcb9cc73b526f7a91008165b6083e56d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/1.13.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/41.0.1 requests-toolbelt/0.9.1 tqdm/4.32.1 CPython/3.7.3

Security for finja 1.1.1

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page