ICTREE(1)

πŸ“¦ version 1.0.1, in alpine 3.24, nixos 26.05, nixpkgs unstable

πŸ’… ICTREE(1) β€” like tree but interactive

okay bestie, so this is from the General Commands Manual section, page ICTREE(1), and it's genuinely one of those tools that makes you go "wait why didn't I know about this sooner" 🫢


✨ NAME ✨

ictree β€” it's tree, but make it interactive πŸ’…

🌸 SYNOPSIS 🌸

ictree [OPTION...]  [FILE]

πŸ¦‹ DESCRIPTION πŸ¦‹

so ictree is this terminal-based program that takes a list of the contents of directories and shows them in a pager β€” think less, but ✨glowed up✨ β€” where you can fold/unfold directories and jump between them super fast. it's giving file-explorer energy but make it terminal πŸŽ€

it's lowkey perfect for browsing locate, find, or literally any other program's output that happens to be a list of paths. slay.

πŸ“ EXAMPLES πŸ“

find something with locate and pipe that output straight into ictree:

locate something | ictree

same deal applies to any program that can produce a list of paths. for example, you can use find with ictree to view the current working directory in a nice tree-like format:

find | ictree

ictree can also take a file that contains paths as its first argument:

locate something > list.txt
ictree list.txt

also!! ictree supports vi-like search functionality. extended regular expressions are supported, no cap. and if a pattern contains the / character, the search is performed by the full paths of items instead of their short names in the list. iykyk πŸ”₯

πŸ‘‘ COMMANDS πŸ‘‘

all the commands for moving around in the pager resemble less and vi commands. classic icons.

🌈 MOVING

  • j, Down β€” move cursor down 1 line
  • k, Up β€” move cursor up 1 line
  • l, Right β€” scroll right
  • h, Left β€” scroll left
  • ^E, Mouse Wheel Down β€” scroll down one line
  • ^Y, Mouse Wheel Up β€” scroll up one line
  • ^D β€” scroll down half-window
  • ^U β€” scroll up half-window
  • ^F β€” scroll down one window
  • ^B β€” scroll up one window
  • g β€” move cursor to the top
  • G β€” move cursor to the bottom
  • z β€” put cursor at the center of window
  • p β€” go to parent item

πŸ’œ OTHERS

  • Enter, Mouse Left Button β€” fold/unfold the selected item
  • Space β€” fold selected item and move cursor down 1 line
  • c β€” go to parent item and fold it
  • / β€” search forward for pattern
  • ? β€” search backward for pattern
  • n β€” repeat previous search
  • N β€” repeat previous search in reverse direction
  • y β€” copy selected item into X or Wayland clipboard. heads up: using this command requires xsel or wl-copy installed, depending on which display server is used 🫢
  • o β€” write selected item to standard output and exit
  • q, Esc β€” quit
  • ^Z β€” suspend ictree

🧚 CUSTOM COMMANDS 🧚

it's totally possible to define custom commands in the configuration file (peep FILES below) to open a selected path in other programs. main character customization behavior, honestly.

examples:

# open selected path in vim by pressing e
map e vim $f

# open selected path in a pager
# defined in $PAGER environment variable
map i $PAGER $f

when a custom command is invoked, ictree simply runs a program with /bin/sh and sets $f variable to whatever a user has selected. easy.

note: unlike Vim, it's impossible to use more than one character in a mapping. one key, one vibe. periodt. πŸ’€

⭐ OPTIONS ⭐

  • --fold, -f β€” fold directories by default
  • --separator=<C>, -s <C> β€” set directory separator to C. / is the default value
  • --help, -h β€” print a help message and exit
  • --version, -v β€” display version information and exit

πŸŽ€ FILES πŸŽ€

  • $XDG_CONFIG_PATH/ictree/config β€” the configuration file. if $XDG_CONFIG_PATH is not defined, $HOME/.config is used instead 🫢

πŸ”₯ SEE ALSO πŸ”₯

tree(1), find(1), locate(1), less(1) β€” the whole friend group, love that for them πŸ’–

🌟 AUTHOR 🌟

written by Nikita Ivanov. iconic behavior, honestly.


okay that's the whole page bestie!! this is ICTREE(1) from the General Commands Manual, and you've officially reached the end of the vibes 🌸 no cap, go fold some directories πŸ’…βœ¨

πŸ“¦ where this page comes from