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

https://github.com/ali5ter/clu

๐Ÿ–ฅ๏ธ A terminal interface for the commandlineuser.com CLI catalogue
https://github.com/ali5ter/clu

bubbletea catalog charmbracelet cli command-line-tools developer-tools golang pipeline terminal tui

Last synced: 2 months ago
JSON representation

๐Ÿ–ฅ๏ธ A terminal interface for the commandlineuser.com CLI catalogue

Awesome Lists containing this project

README

          

![clu demo](examples/clu_demo.gif)

# clu

Yes, it's a command-line tool for a website about command-line tools. I know.

[commandlineuser.com](https://commandlineuser.com) catalogues and scores CLI tools. It seemed only right
that you should be able to explore it without leaving the terminal โ€” and that the output should be
pipeable into the very tools it's recommending.

That's the joke. It also happens to be useful.

---

## Install

**Homebrew** (macOS and Linux):

```bash
brew tap ali5ter/clu
brew install clu
```

**Binary** (macOS and Linux, no Go required):

```bash
# macOS Apple Silicon
curl -sL https://github.com/ali5ter/clu/releases/latest/download/clu_darwin_arm64.tar.gz | tar -xz
sudo mv clu /usr/local/bin/

# macOS Intel
curl -sL https://github.com/ali5ter/clu/releases/latest/download/clu_darwin_amd64.tar.gz | tar -xz
sudo mv clu /usr/local/bin/

# Linux arm64
curl -sL https://github.com/ali5ter/clu/releases/latest/download/clu_linux_arm64.tar.gz | tar -xz
sudo mv clu /usr/local/bin/

# Linux amd64
curl -sL https://github.com/ali5ter/clu/releases/latest/download/clu_linux_amd64.tar.gz | tar -xz
sudo mv clu /usr/local/bin/
```

**Go**:

```bash
go install github.com/ali5ter/clu@latest
```

---

## Usage

Run it in a terminal and you get the TUI:

```bash
clu
```

Pipe it somewhere and it emits JSON:

```bash
clu | jq '.[] | select(.score >= 9)'
```

### Flags

| Flag | What it does |
| ----------- | -------------------------------------------------- |
| `--json` | Force JSON output even in a terminal |
| `--offline` | Use the local cache โ€” no network request |
| `--no-tty` | Pipeline mode regardless of how you're running it |

---

## TUI

Three tabs โ€” Catalog, Articles, About โ€” switched with `tab` and `shift+tab`.

### Catalog

A scored list of CLI tools on the left; detail on the right. The score colours tell you
something: green means the tool rated highly on utility, maturity, and maintenance.
Grey means it's worth knowing about but didn't break into the top tier.

### Articles

Feature articles from the site rendered in the terminal. Navigate the list on the left,
read on the right. Scroll the article with `shift+โ†‘` and `shift+โ†“`.

### Key bindings

| Key | Action |
| ------------------------ | ------------------------------------- |
| `โ†‘` / `โ†“` or `j` / `k` | Navigate list |
| `/` | Filter |
| `enter` | Open in browser |
| `ctrl+j` | Output selected item as JSON and exit |
| `shift+โ†‘` / `shift+โ†“` | Scroll detail pane |
| `tab` / `shift+tab` | Switch tabs |
| `q` | Quit |

---

## Pipeline mode

`ctrl+j` in the TUI exits and emits the selected catalogue item as JSON โ€” so you can
browse visually and hand off to `jq`, `fzf`, or anything else that reads stdin.

`--json` skips the TUI entirely and dumps the full catalogue:

```bash
clu --json | jq '.[0]'
```

Cached data lives in `~/.cache/clu/`. Use `--offline` if you're on a plane.

---

## Built with

- [Bubble Tea](https://github.com/charmbracelet/bubbletea) โ€” Elm-architecture TUI framework
- [Lip Gloss](https://github.com/charmbracelet/lipgloss) โ€” terminal styling and layout
- [Bubbles](https://github.com/charmbracelet/bubbles) โ€” list, viewport, textinput components
- [Glamour](https://github.com/charmbracelet/glamour) โ€” markdown rendering

---

## commandlineuser.com

The catalogue is updated nightly. Every item has a score, a confidence value, and an
explanation of what drove both. No curation by follower count or GitHub stars alone.

[commandlineuser.com](https://commandlineuser.com) ยท
[Methodology](https://commandlineuser.com/about/methodology) ยท
[About](https://commandlineuser.com/about)