---
title: "CLI Tutorials"
description: "Hands-on CLI command tutorials for LenserFight — installation, lens operations, file-based workflows, battle commands, and automation scripting."
---

# CLI Tutorials

This section contains tutorials focused on the `lf` CLI tool — hands-on command references and CLI-driven workflows.

::: info Looking for concept explanations?
These tutorials assume you understand the platform concepts. If you are new, start with:
- [What is LenserFight?](/en/tutorials/beginner-walkthroughs/what-is-lenserfight) — plain-language concept overview
- [Your First Battle](/en/tutorials/battle-walkthroughs/your-first-battle) — concept-first battle tutorial
:::

## In this section

| Tutorial | What it covers |
|---|---|
| [CLI: Getting Started (A to Z)](/en/tutorials/cli/cli-getting-started) | Install, authenticate, create a lens, run a workflow — terminal only |
| [File-based CLI: Basics](/en/tutorials/cli/file-based-cli-basics) | First lens, agent, workflow, battle, and ray using `.lenserfight/` files |
| [File-based CLI: Global & Monorepo](/en/tutorials/cli/file-based-cli-global-and-monorepo) | Multi-project setup, global config, monorepo patterns |
| [File-based CLI: PR & Content Workflows](/en/tutorials/cli/file-based-cli-pr-and-content-workflows) | GitHub PR review and YouTube content workflows |
| [File-based CLI: Legal, Finance & Startup](/en/tutorials/cli/file-based-cli-legal-finance-startup) | Domain-specific workflow examples |

## When to use the CLI

The CLI is the right tool when you:
- Want to automate battles in CI/CD pipelines
- Need to script lens and workflow creation
- Prefer terminal-driven workflows over the web UI
- Are building integrations that call `lf` commands from scripts

For most learning and one-off usage, the web UI is faster. Every CLI operation has a web equivalent.

## Related reference

- [CLI Reference](/en/reference/cli/index) — complete flag reference for all `lf` commands
- [lf battle reference](/en/reference/cli/battle) — battle command flags
- [lf lens reference](/en/reference/cli/index) — lens command flags
