Skip to content

Dj-Shortcut/bless

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

60 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

bless

bless is a terminal-first CLI.

Development

npm install
npm test

Test suite

Bless focuses heavily on terminal correctness:

  • raw mode restoration
  • SIGINT cleanup
  • piped input behavior
  • Windows console fallback
image

Local install

npm link
printf 'hello from bless\n' | bless

CLI options

  • -h, --help Show this help message
  • -v, --version Show bless version
  • --no-pager Disable interactive pager

Basic interactive pager controls

When viewing a file in an interactive TTY, bless now supports a minimal pager loop with classic keys:

  • q quit
  • j/k and Up/Down move one line
  • space/b and PgDn/PgUp page down/up
  • g/G jump to top/bottom

Known limitations

  • Full-screen behavior (alternate screen + resize) requires an interactive TTY.
  • File viewing still loads the full file into memory; chunked large-file buffering is not implemented yet.
  • Search (/, n, N) is not implemented yet.
  • The pager runs only when capability checks mark the terminal as interactive (non-dumb TERM with TTY output, plus raw-mode setup succeeding); otherwise bless falls back to plain passthrough output.
  • On Windows, piped stdin can also fall back to plain output when bless cannot acquire interactive console input (for example \\.\\CONIN$ open failures).
  • bless currently has no built-in --help or --version output.
  • Windows terminal behavior depends on the host terminal supporting ANSI control sequences.
  • When both a filename and piped stdin are provided, the filename is preferred.
  • Unexpected runtime failures still attempt cleanup, but if the process is forcibly killed (e.g. SIGKILL), terminal restoration is not possible.

Design goals

  • minimal pager
  • predictable terminal behavior
  • small dependency surface
  • works with pipes and files

Release-readiness checklist (packaging)

npm test
npm pack --dry-run
npm link
printf 'link check\n' | bless
npm install -g .
printf 'global check\n' | bless
git ls-files --eol

About

bless (better-less) — a small terminal pager that tries to be friendlier than less, more or less :)

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors