television/docs/Users/cli/index.html
2025-07-13 14:44:52 +00:00

506 lines
85 KiB
HTML
Raw Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<!doctype html>
<html lang="en" dir="ltr" class="docs-wrapper plugin-docs plugin-id-default docs-version-current docs-doc-page docs-doc-id-Users/cli" data-has-hydrated="false">
<head>
<meta charset="UTF-8">
<meta name="generator" content="Docusaurus v3.8.1">
<title data-rh="true">CLI Reference | Television</title><meta data-rh="true" name="viewport" content="width=device-width,initial-scale=1"><meta data-rh="true" name="twitter:card" content="summary_large_image"><meta data-rh="true" property="og:image" content="https://alexpasmantier.github.io/television/img/tv-social.png"><meta data-rh="true" name="twitter:image" content="https://alexpasmantier.github.io/television/img/tv-social.png"><meta data-rh="true" property="og:url" content="https://alexpasmantier.github.io/television/docs/Users/cli"><meta data-rh="true" property="og:locale" content="en"><meta data-rh="true" name="docusaurus_locale" content="en"><meta data-rh="true" name="docsearch:language" content="en"><meta data-rh="true" name="docusaurus_version" content="current"><meta data-rh="true" name="docusaurus_tag" content="docs-default-current"><meta data-rh="true" name="docsearch:version" content="current"><meta data-rh="true" name="docsearch:docusaurus_tag" content="docs-default-current"><meta data-rh="true" property="og:title" content="CLI Reference | Television"><meta data-rh="true" name="description" content="Television (tv) is a cross-platform, fast and extensible general purpose fuzzy finder TUI. This document provides a comprehensive reference for all CLI options, modes, restrictions, and usage patterns."><meta data-rh="true" property="og:description" content="Television (tv) is a cross-platform, fast and extensible general purpose fuzzy finder TUI. This document provides a comprehensive reference for all CLI options, modes, restrictions, and usage patterns."><link data-rh="true" rel="icon" href="/television/img/tv-icon-150.png"><link data-rh="true" rel="canonical" href="https://alexpasmantier.github.io/television/docs/Users/cli"><link data-rh="true" rel="alternate" href="https://alexpasmantier.github.io/television/docs/Users/cli" hreflang="en"><link data-rh="true" rel="alternate" href="https://alexpasmantier.github.io/television/docs/Users/cli" hreflang="x-default"><script data-rh="true" type="application/ld+json">{"@context":"https://schema.org","@type":"BreadcrumbList","itemListElement":[{"@type":"ListItem","position":1,"name":"CLI Reference","item":"https://alexpasmantier.github.io/television/docs/Users/cli"}]}</script><link rel="stylesheet" href="/television/assets/css/styles.21c2131b.css">
<script src="/television/assets/js/runtime~main.03589cbc.js" defer="defer"></script>
<script src="/television/assets/js/main.391aee7d.js" defer="defer"></script>
</head>
<body class="navigation-with-keyboard">
<svg xmlns="http://www.w3.org/2000/svg" style="display: none;"><defs>
<symbol id="theme-svg-external-link" viewBox="0 0 24 24"><path fill="currentColor" d="M21 13v10h-21v-19h12v2h-10v15h17v-8h2zm3-12h-10.988l4.035 4-6.977 7.07 2.828 2.828 6.977-7.07 4.125 4.172v-11z"/></symbol>
</defs></svg>
<script>!function(){var t="dark";var e=function(){try{return new URLSearchParams(window.location.search).get("docusaurus-theme")}catch(t){}}()||function(){try{return window.localStorage.getItem("theme")}catch(t){}}();document.documentElement.setAttribute("data-theme",e||t),document.documentElement.setAttribute("data-theme-choice",e||t)}(),function(){try{const c=new URLSearchParams(window.location.search).entries();for(var[t,e]of c)if(t.startsWith("docusaurus-data-")){var a=t.replace("docusaurus-data-","data-");document.documentElement.setAttribute(a,e)}}catch(t){}}()</script><div id="__docusaurus"><link rel="preload" as="image" href="/television/img/tv-icon-80.png"><div role="region" aria-label="Skip to main content"><a class="skipToContent_nod4" href="#__docusaurus_skipToContent_fallback">Skip to main content</a></div><nav aria-label="Main" class="theme-layout-navbar navbar navbar--fixed-top"><div class="navbar__inner"><div class="theme-layout-navbar-left navbar__items"><button aria-label="Toggle navigation bar" aria-expanded="false" class="navbar__toggle clean-btn" type="button"><svg width="30" height="30" viewBox="0 0 30 30" aria-hidden="true"><path stroke="currentColor" stroke-linecap="round" stroke-miterlimit="10" stroke-width="2" d="M4 7h22M4 15h22M4 23h22"></path></svg></button><a class="navbar__brand" href="/television/"><div class="navbar__logo"><img src="/television/img/tv-icon-80.png" alt="Television Logo" class="themedComponent_rgZj themedComponent--light_hdxy"><img src="/television/img/tv-icon-80.png" alt="Television Logo" class="themedComponent_rgZj themedComponent--dark_Iwy7"></div><b class="navbar__title text--truncate">Television</b></a><a aria-current="page" class="navbar__item navbar__link navbar__link--active" href="/television/docs/Users/installation">docs</a><a href="https://github.com/alexpasmantier/television/releases" target="_blank" rel="noopener noreferrer" class="navbar__item navbar__link">releases<svg width="13.5" height="13.5" aria-hidden="true" class="iconExternalLink_dOts"><use href="#theme-svg-external-link"></use></svg></a><a href="https://crates.io/crates/television" target="_blank" rel="noopener noreferrer" class="navbar__item navbar__link">crates.io<svg width="13.5" height="13.5" aria-hidden="true" class="iconExternalLink_dOts"><use href="#theme-svg-external-link"></use></svg></a></div><div class="theme-layout-navbar-right navbar__items navbar__items--right"><a href="https://github.com/alexpasmantier/television" target="_blank" rel="noopener noreferrer" class="navbar__item navbar__link">GitHub<svg width="13.5" height="13.5" aria-hidden="true" class="iconExternalLink_dOts"><use href="#theme-svg-external-link"></use></svg></a><div class="navbarSearchContainer_VxOy"></div></div></div><div role="presentation" class="navbar-sidebar__backdrop"></div></nav><div id="__docusaurus_skipToContent_fallback" class="theme-layout-main main-wrapper mainWrapper_HR2q"><div class="docsWrapper_uElw"><button aria-label="Scroll back to top" class="clean-btn theme-back-to-top-button backToTopButton_IzB1" type="button"></button><div class="docRoot_MWdD"><aside class="theme-doc-sidebar-container docSidebarContainer_AJtF"><div class="sidebarViewport_usFm"><div class="sidebar_HC93"><nav aria-label="Docs sidebar" class="menu thin-scrollbar menu_BnDX"><ul class="theme-doc-sidebar-menu menu__list"><li class="theme-doc-sidebar-item-category theme-doc-sidebar-item-category-level-1 menu__list-item"><div class="menu__list-item-collapsible"><a class="menu__link menu__link--sublist menu__link--sublist-caret menu__link--active" role="button" aria-expanded="true" href="/television/docs/Users/installation">Users</a></div><ul class="menu__list"><li class="theme-doc-sidebar-item-link theme-doc-sidebar-item-link-level-2 menu__list-item"><a class="menu__link" tabindex="0" href="/television/docs/Users/installation">Installation</a></li><li class="theme-doc-sidebar-item-link theme-doc-sidebar-item-link-level-2 menu__list-item"><a class="menu__link" tabindex="0" href="/television/docs/Users/quickstart">Quickstart</a></li><li class="theme-doc-sidebar-item-link theme-doc-sidebar-item-link-level-2 menu__list-item"><a class="menu__link" tabindex="0" href="/television/docs/Users/configuration">Configuration</a></li><li class="theme-doc-sidebar-item-link theme-doc-sidebar-item-link-level-2 menu__list-item"><a class="menu__link" tabindex="0" href="/television/docs/Users/keybindings">Keybindings</a></li><li class="theme-doc-sidebar-item-link theme-doc-sidebar-item-link-level-2 menu__list-item"><a class="menu__link" tabindex="0" href="/television/docs/Users/shell-integration">Shell Integration</a></li><li class="theme-doc-sidebar-item-link theme-doc-sidebar-item-link-level-2 menu__list-item"><a class="menu__link" tabindex="0" href="/television/docs/Users/search-patterns">Search Patterns</a></li><li class="theme-doc-sidebar-item-link theme-doc-sidebar-item-link-level-2 menu__list-item"><a class="menu__link" tabindex="0" href="/television/docs/Users/channels">Channels</a></li><li class="theme-doc-sidebar-item-link theme-doc-sidebar-item-link-level-2 menu__list-item"><a class="menu__link" tabindex="0" href="/television/docs/Users/themes">Themes</a></li><li class="theme-doc-sidebar-item-link theme-doc-sidebar-item-link-level-2 menu__list-item"><a class="menu__link menu__link--active" aria-current="page" tabindex="0" href="/television/docs/Users/cli">CLI Reference</a></li><li class="theme-doc-sidebar-item-link theme-doc-sidebar-item-link-level-2 menu__list-item"><a class="menu__link" tabindex="0" href="/television/docs/Users/community-channels-unix">🍿 Community Channels (unix)</a></li><li class="theme-doc-sidebar-item-link theme-doc-sidebar-item-link-level-2 menu__list-item"><a class="menu__link" tabindex="0" href="/television/docs/Users/community-channels-windows">🍿 Community Channels (windows)</a></li><li class="theme-doc-sidebar-item-link theme-doc-sidebar-item-link-level-2 menu__list-item"><a class="menu__link" tabindex="0" href="/television/docs/Users/terminal_emulators">Terminal Emulators</a></li><li class="theme-doc-sidebar-item-link theme-doc-sidebar-item-link-level-2 menu__list-item"><a class="menu__link" tabindex="0" href="/television/docs/Users/showcase">Showcase</a></li></ul></li><li class="theme-doc-sidebar-item-category theme-doc-sidebar-item-category-level-1 menu__list-item menu__list-item--collapsed"><div class="menu__list-item-collapsible"><a class="menu__link menu__link--sublist menu__link--sublist-caret" role="button" aria-expanded="false" href="/television/docs/Developers/contributing">Developers</a></div></li></ul></nav><button type="button" title="Collapse sidebar" aria-label="Collapse sidebar" class="button button--secondary button--outline collapseSidebarButton_I1Io"><svg width="20" height="20" aria-hidden="true" class="collapseSidebarButtonIcon_KwG0"><g fill="#7a7a7a"><path d="M9.992 10.023c0 .2-.062.399-.172.547l-4.996 7.492a.982.982 0 01-.828.454H1c-.55 0-1-.453-1-1 0-.2.059-.403.168-.551l4.629-6.942L.168 3.078A.939.939 0 010 2.528c0-.548.45-.997 1-.997h2.996c.352 0 .649.18.828.45L9.82 9.472c.11.148.172.347.172.55zm0 0"></path><path d="M19.98 10.023c0 .2-.058.399-.168.547l-4.996 7.492a.987.987 0 01-.828.454h-3c-.547 0-.996-.453-.996-1 0-.2.059-.403.168-.551l4.625-6.942-4.625-6.945a.939.939 0 01-.168-.55 1 1 0 01.996-.997h3c.348 0 .649.18.828.45l4.996 7.492c.11.148.168.347.168.55zm0 0"></path></g></svg></button></div></div></aside><main class="docMainContainer_yFTf"><div class="container padding-top--md padding-bottom--lg"><div class="row"><div class="col docItemCol_QLDD"><div class="docItemContainer_Hqnr"><article><nav class="theme-doc-breadcrumbs breadcrumbsContainer_eD4m" aria-label="Breadcrumbs"><ul class="breadcrumbs"><li class="breadcrumbs__item"><a aria-label="Home page" class="breadcrumbs__link" href="/television/"><svg viewBox="0 0 24 24" class="breadcrumbHomeIcon_YhwE"><path d="M10 19v-5h4v5c0 .55.45 1 1 1h3c.55 0 1-.45 1-1v-7h1.7c.46 0 .68-.57.33-.87L12.67 3.6c-.38-.34-.96-.34-1.34 0l-8.36 7.53c-.34.3-.13.87.33.87H5v7c0 .55.45 1 1 1h3c.55 0 1-.45 1-1z" fill="currentColor"></path></svg></a></li><li class="breadcrumbs__item"><span class="breadcrumbs__link">Users</span></li><li class="breadcrumbs__item breadcrumbs__item--active"><span class="breadcrumbs__link">CLI Reference</span></li></ul></nav><div class="tocCollapsible_Qf8d theme-doc-toc-mobile tocMobile_mt20"><button type="button" class="clean-btn tocCollapsibleButton_Hr9f">On this page</button></div><div class="theme-doc-markdown markdown"><header><h1>CLI Reference</h1></header>
<p>Television (<code>tv</code>) is a cross-platform, fast and extensible general purpose fuzzy finder TUI. This document provides a comprehensive reference for all CLI options, modes, restrictions, and usage patterns.</p>
<h2 class="anchor anchorWithStickyNavbar_Fogf" id="table-of-contents">Table of Contents<a href="#table-of-contents" class="hash-link" aria-label="Direct link to Table of Contents" title="Direct link to Table of Contents"></a></h2>
<ul>
<li><a href="#overview">Overview</a></li>
<li><a href="#operating-modes">Operating Modes</a></li>
<li><a href="#basic-usage">Basic Usage</a></li>
<li><a href="#arguments">Arguments</a></li>
<li><a href="#options">Options</a></li>
<li><a href="#subcommands">Subcommands</a></li>
<li><a href="#usage-rules-and-restrictions">Usage Rules and Restrictions</a></li>
<li><a href="#configuration">Configuration</a></li>
<li><a href="#template-system">Template System</a></li>
<li><a href="#examples">Examples</a></li>
</ul>
<h2 class="anchor anchorWithStickyNavbar_Fogf" id="overview">Overview<a href="#overview" class="hash-link" aria-label="Direct link to Overview" title="Direct link to Overview"></a></h2>
<p>Television supports two primary operating modes that determine how CLI flags are interpreted and validated:</p>
<ol>
<li><strong>Channel Mode</strong>: When a channel is specified, the application uses the channel&#x27;s configuration as a base and CLI flags act as overrides</li>
<li><strong>Ad-hoc Mode</strong>: When no channel is specified, the application creates a custom channel from CLI flags with stricter validation</li>
</ol>
<h2 class="anchor anchorWithStickyNavbar_Fogf" id="operating-modes">Operating Modes<a href="#operating-modes" class="hash-link" aria-label="Direct link to Operating Modes" title="Direct link to Operating Modes"></a></h2>
<h3 class="anchor anchorWithStickyNavbar_Fogf" id="channel-mode">Channel Mode<a href="#channel-mode" class="hash-link" aria-label="Direct link to Channel Mode" title="Direct link to Channel Mode"></a></h3>
<p><strong>Activated when</strong>: A channel name is provided as the first argument or via <code>--autocomplete-prompt</code></p>
<p><strong>Behavior</strong>:</p>
<ul>
<li>Channel provides base configuration (source commands, preview commands, UI settings)</li>
<li>CLI flags act as <strong>overrides</strong> to channel defaults</li>
<li>More permissive validation - allows most combination of flags</li>
<li>Minimal dependency checking since channel provides sensible defaults</li>
</ul>
<p><strong>Example</strong>:</p>
<div class="language-bash codeBlockContainer_MbdR theme-code-block" style="--prism-color:#F8F8F2;--prism-background-color:#282A36"><div class="codeBlockContent_WPSJ"><pre tabindex="0" class="prism-code language-bash codeBlock_ke8T thin-scrollbar" style="color:#F8F8F2;background-color:#282A36"><code class="codeBlockLines_oe7S"><span class="token-line" style="color:#F8F8F2"><span class="token plain">tv files --preview-command </span><span class="token string" style="color:rgb(255, 121, 198)">&quot;bat -n --color=always &#x27;{}&#x27;&quot;</span><br></span></code></pre></div></div>
<h3 class="anchor anchorWithStickyNavbar_Fogf" id="ad-hoc-mode">Ad-hoc Mode<a href="#ad-hoc-mode" class="hash-link" aria-label="Direct link to Ad-hoc Mode" title="Direct link to Ad-hoc Mode"></a></h3>
<p><strong>Activated when</strong>: No channel is specified and no <code>--autocomplete-prompt</code> is used</p>
<p><strong>Behavior</strong>:</p>
<ul>
<li>Creates a custom channel on-the-fly from CLI flags</li>
<li>Requires <code>--source-command</code> to generate any entries</li>
<li><strong>Stricter validation</strong> ensures necessary components are present</li>
<li>All functionality depends on explicitly provided flags</li>
</ul>
<p><strong>Example</strong>:</p>
<div class="language-bash codeBlockContainer_MbdR theme-code-block" style="--prism-color:#F8F8F2;--prism-background-color:#282A36"><div class="codeBlockContent_WPSJ"><pre tabindex="0" class="prism-code language-bash codeBlock_ke8T thin-scrollbar" style="color:#F8F8F2;background-color:#282A36"><code class="codeBlockLines_oe7S"><span class="token-line" style="color:#F8F8F2"><span class="token plain">tv --source-command </span><span class="token string" style="color:rgb(255, 121, 198)">&quot;find . -name &#x27;*.rs&#x27;&quot;</span><span class="token plain"> --preview-command </span><span class="token string" style="color:rgb(255, 121, 198)">&quot;bat -n --color=always &#x27;{}&#x27;&quot;</span><br></span></code></pre></div></div>
<h2 class="anchor anchorWithStickyNavbar_Fogf" id="basic-usage">Basic Usage<a href="#basic-usage" class="hash-link" aria-label="Direct link to Basic Usage" title="Direct link to Basic Usage"></a></h2>
<div class="language-text codeBlockContainer_MbdR theme-code-block" style="--prism-color:#F8F8F2;--prism-background-color:#282A36"><div class="codeBlockContent_WPSJ"><pre tabindex="0" class="prism-code language-text codeBlock_ke8T thin-scrollbar" style="color:#F8F8F2;background-color:#282A36"><code class="codeBlockLines_oe7S"><span class="token-line" style="color:#F8F8F2"><span class="token plain">tv [OPTIONS] [CHANNEL] [PATH]</span><br></span></code></pre></div></div>
<h3 class="anchor anchorWithStickyNavbar_Fogf" id="arguments">Arguments<a href="#arguments" class="hash-link" aria-label="Direct link to Arguments" title="Direct link to Arguments"></a></h3>
<p>Television has intelligent positional argument handling with special path detection logic.</p>
<h4 class="anchor anchorWithStickyNavbar_Fogf" id="position-1-channel">Position 1: <code>[CHANNEL]</code><a href="#position-1-channel" class="hash-link" aria-label="Direct link to position-1-channel" title="Direct link to position-1-channel"></a></h4>
<p><strong>Purpose</strong>: Channel name to activate Channel Mode</p>
<ul>
<li>
<p><strong>Standard behavior</strong>: When a valid channel name is provided, activates Channel Mode</p>
</li>
<li>
<p><strong>Special path detection</strong>: If the argument exists as a path on the filesystem, it&#x27;s automatically treated as a working directory instead</p>
</li>
<li>
<p><strong>Effect when path detected</strong>: Switches to Ad-hoc Mode and uses the path as the working directory</p>
</li>
<li>
<p><strong>Required</strong>: No (falls back to <code>default_channel</code> from the global config)</p>
</li>
<li>
<p><strong>Examples</strong>:</p>
<div class="language-bash codeBlockContainer_MbdR theme-code-block" style="--prism-color:#F8F8F2;--prism-background-color:#282A36"><div class="codeBlockContent_WPSJ"><pre tabindex="0" class="prism-code language-bash codeBlock_ke8T thin-scrollbar" style="color:#F8F8F2;background-color:#282A36"><code class="codeBlockLines_oe7S"><span class="token-line" style="color:#F8F8F2"><span class="token plain">tv files </span><span class="token comment" style="color:rgb(98, 114, 164)"># Uses &#x27;files&#x27; channel</span><span class="token plain"></span><br></span><span class="token-line" style="color:#F8F8F2"><span class="token plain">tv /home/user/docs </span><span class="token comment" style="color:rgb(98, 114, 164)"># Auto-detects path, uses as working directory</span><span class="token plain"></span><br></span><span class="token-line" style="color:#F8F8F2"><span class="token plain">tv ./projects </span><span class="token comment" style="color:rgb(98, 114, 164)"># Auto-detects relative path</span><br></span></code></pre></div></div>
</li>
</ul>
<h4 class="anchor anchorWithStickyNavbar_Fogf" id="position-2-path">Position 2: <code>[PATH]</code><a href="#position-2-path" class="hash-link" aria-label="Direct link to position-2-path" title="Direct link to position-2-path"></a></h4>
<p><strong>Purpose</strong>: Working directory to start in</p>
<ul>
<li><strong>Behavior</strong>: Sets the working directory for the application</li>
<li><strong>Required</strong>: No</li>
<li><strong>Precedence</strong>: Only used if Position 1 was not detected as a path</li>
<li><strong>Default</strong>: Current directory</li>
<li><strong>Example</strong>: <code>tv files /home/user/projects</code></li>
</ul>
<h4 class="anchor anchorWithStickyNavbar_Fogf" id="-smart-path-detection-logic">⚡ Smart Path Detection Logic<a href="#-smart-path-detection-logic" class="hash-link" aria-label="Direct link to ⚡ Smart Path Detection Logic" title="Direct link to ⚡ Smart Path Detection Logic"></a></h4>
<p>Television automatically detects when the first argument is a filesystem path:</p>
<ol>
<li><strong>Path Check</strong>: If Position 1 exists as a file or directory on the filesystem</li>
<li><strong>Mode Switch</strong>: Automatically switches to Ad-hoc Mode (no channel)</li>
<li><strong>Directory Assignment</strong>: Uses the detected path as the working directory</li>
<li><strong>Requirement</strong>: When this happens, <code>--source-command</code> becomes required (Ad-hoc Mode rules apply)</li>
</ol>
<p><strong>Examples of Smart Detection</strong>:</p>
<div class="language-bash codeBlockContainer_MbdR theme-code-block" style="--prism-color:#F8F8F2;--prism-background-color:#282A36"><div class="codeBlockContent_WPSJ"><pre tabindex="0" class="prism-code language-bash codeBlock_ke8T thin-scrollbar" style="color:#F8F8F2;background-color:#282A36"><code class="codeBlockLines_oe7S"><span class="token-line" style="color:#F8F8F2"><span class="token comment" style="color:rgb(98, 114, 164)"># No arguments - uses default_channel from config</span><span class="token plain"></span><br></span><span class="token-line" style="color:#F8F8F2"><span class="token plain">tv</span><br></span><span class="token-line" style="color:#F8F8F2"><span class="token plain" style="display:inline-block"></span><br></span><span class="token-line" style="color:#F8F8F2"><span class="token plain"></span><span class="token comment" style="color:rgb(98, 114, 164)"># Channel name provided - Channel Mode</span><span class="token plain"></span><br></span><span class="token-line" style="color:#F8F8F2"><span class="token plain">tv files</span><br></span><span class="token-line" style="color:#F8F8F2"><span class="token plain" style="display:inline-block"></span><br></span><span class="token-line" style="color:#F8F8F2"><span class="token plain"></span><span class="token comment" style="color:rgb(98, 114, 164)"># Existing path provided - triggers path detection → uses default_channel</span><span class="token plain"></span><br></span><span class="token-line" style="color:#F8F8F2"><span class="token plain">tv /home/user/docs </span><span class="token comment" style="color:rgb(98, 114, 164)"># Uses default_channel in /home/user/docs directory</span><span class="token plain"></span><br></span><span class="token-line" style="color:#F8F8F2"><span class="token plain" style="display:inline-block"></span><br></span><span class="token-line" style="color:#F8F8F2"><span class="token plain"></span><span class="token comment" style="color:rgb(98, 114, 164)"># Non-existent path - treated as channel name → error if channel doesn&#x27;t exist</span><span class="token plain"></span><br></span><span class="token-line" style="color:#F8F8F2"><span class="token plain">tv /nonexistent/path </span><span class="token comment" style="color:rgb(98, 114, 164)"># Error: Channel not found</span><span class="token plain"></span><br></span><span class="token-line" style="color:#F8F8F2"><span class="token plain" style="display:inline-block"></span><br></span><span class="token-line" style="color:#F8F8F2"><span class="token plain"></span><span class="token comment" style="color:rgb(98, 114, 164)"># Channel + explicit working directory - Channel Mode</span><span class="token plain"></span><br></span><span class="token-line" style="color:#F8F8F2"><span class="token plain">tv files /home/user/docs</span><br></span><span class="token-line" style="color:#F8F8F2"><span class="token plain" style="display:inline-block"></span><br></span><span class="token-line" style="color:#F8F8F2"><span class="token plain"></span><span class="token comment" style="color:rgb(98, 114, 164)"># The key nuance: same name, different behavior based on filesystem</span><span class="token plain"></span><br></span><span class="token-line" style="color:#F8F8F2"><span class="token plain">tv myproject </span><span class="token comment" style="color:rgb(98, 114, 164)"># Channel Mode (if &#x27;myproject&#x27; is a channel name)</span><span class="token plain"></span><br></span><span class="token-line" style="color:#F8F8F2"><span class="token plain">tv ./myproject </span><span class="token comment" style="color:rgb(98, 114, 164)"># Channel Mode with default_channel (if &#x27;./myproject&#x27; directory exists)</span><span class="token plain"></span><br></span><span class="token-line" style="color:#F8F8F2"><span class="token plain" style="display:inline-block"></span><br></span><span class="token-line" style="color:#F8F8F2"><span class="token plain"></span><span class="token comment" style="color:rgb(98, 114, 164)"># Ambiguous case - path detection takes precedence</span><span class="token plain"></span><br></span><span class="token-line" style="color:#F8F8F2"><span class="token plain">tv docs </span><span class="token comment" style="color:rgb(98, 114, 164)"># If &#x27;docs&#x27; directory exists → default_channel + path detection</span><span class="token plain"></span><br></span><span class="token-line" style="color:#F8F8F2"><span class="token plain"> </span><span class="token comment" style="color:rgb(98, 114, 164)"># If &#x27;docs&#x27; directory doesn&#x27;t exist → &#x27;docs&#x27; channel</span><br></span></code></pre></div></div>
<blockquote>
<p><strong>💡 Tip</strong>: This smart detection makes Television intuitive - you can just specify a directory and it automatically knows you want to work in that location.</p>
</blockquote>
<h2 class="anchor anchorWithStickyNavbar_Fogf" id="options">Options<a href="#options" class="hash-link" aria-label="Direct link to Options" title="Direct link to Options"></a></h2>
<p>Television&#x27;s options are organized by functionality. Each option behaves differently depending on whether you&#x27;re using Channel Mode (with a channel specified) or Ad-hoc Mode (no channel).</p>
<h3 class="anchor anchorWithStickyNavbar_Fogf" id="-source-and-data-options">🎯 Source and Data Options<a href="#-source-and-data-options" class="hash-link" aria-label="Direct link to 🎯 Source and Data Options" title="Direct link to 🎯 Source and Data Options"></a></h3>
<h4 class="anchor anchorWithStickyNavbar_Fogf" id="--source-command-string"><code>--source-command &lt;STRING&gt;</code><a href="#--source-command-string" class="hash-link" aria-label="Direct link to --source-command-string" title="Direct link to --source-command-string"></a></h4>
<p><strong>Purpose</strong>: Defines the command that generates entries for the picker</p>
<ul>
<li><strong>Channel Mode</strong>: Overrides the channel&#x27;s default source command</li>
<li><strong>Ad-hoc Mode</strong>: ⚠️ <strong>Required</strong> - without this, no entries will be generated</li>
<li><strong>Example</strong>: <code>--source-command &quot;find . -name &#x27;*.py&#x27;&quot;</code></li>
</ul>
<h4 class="anchor anchorWithStickyNavbar_Fogf" id="--source-display-string"><code>--source-display &lt;STRING&gt;</code><a href="#--source-display-string" class="hash-link" aria-label="Direct link to --source-display-string" title="Direct link to --source-display-string"></a></h4>
<p><strong>Purpose</strong>: Template for formatting how entries appear in the results list</p>
<ul>
<li><strong>Both Modes</strong>: Same behavior</li>
<li><strong>Requires</strong>: <code>--source-command</code> (in ad-hoc mode)</li>
<li><strong>Example</strong>: <code>--source-display &quot;{split:/:-1} ({split:/:0..-1|join:-})&quot;</code></li>
</ul>
<h4 class="anchor anchorWithStickyNavbar_Fogf" id="--source-output-string"><code>--source-output &lt;STRING&gt;</code><a href="#--source-output-string" class="hash-link" aria-label="Direct link to --source-output-string" title="Direct link to --source-output-string"></a></h4>
<p><strong>Purpose</strong>: Template for formatting the final output when an entry is selected</p>
<ul>
<li><strong>Both Modes</strong>: Same behavior</li>
<li><strong>Requires</strong>: <code>--source-command</code> (in ad-hoc mode)</li>
<li><strong>Example</strong>: <code>--source-output &quot;code {}&quot;</code></li>
</ul>
<h3 class="anchor anchorWithStickyNavbar_Fogf" id="-preview-options">👁️ Preview Options<a href="#-preview-options" class="hash-link" aria-label="Direct link to 👁️ Preview Options" title="Direct link to 👁️ Preview Options"></a></h3>
<h4 class="anchor anchorWithStickyNavbar_Fogf" id="--no-preview"><code>--no-preview</code><a href="#--no-preview" class="hash-link" aria-label="Direct link to --no-preview" title="Direct link to --no-preview"></a></h4>
<p><strong>Purpose</strong>: Disable preview feature, toggling is not possible</p>
<ul>
<li><strong>Both Modes</strong>: Same behavior</li>
<li><strong>Conflicts</strong>: Cannot be used with any <code>--preview-*</code> or <code>--*-preview</code> flags</li>
<li><strong>Use Case</strong>: Minimal interface</li>
</ul>
<h4 class="anchor anchorWithStickyNavbar_Fogf" id="--hide-preview"><code>--hide-preview</code><a href="#--hide-preview" class="hash-link" aria-label="Direct link to --hide-preview" title="Direct link to --hide-preview"></a></h4>
<p><strong>Purpose</strong>: Starts the interface with the preview panel hidden</p>
<ul>
<li><strong>Both Modes</strong>: Same behavior</li>
<li><strong>Conflicts</strong>: Cannot be used with <code>--no-preview</code> or <code>--show-preview</code></li>
<li><strong>Use Case</strong>: Start with clean interface, toggle preview later</li>
</ul>
<h4 class="anchor anchorWithStickyNavbar_Fogf" id="--show-preview"><code>--show-preview</code><a href="#--show-preview" class="hash-link" aria-label="Direct link to --show-preview" title="Direct link to --show-preview"></a></h4>
<p><strong>Purpose</strong>: Starts the interface with the preview panel visible</p>
<ul>
<li><strong>Both Modes</strong>: Same behavior</li>
<li><strong>Conflicts</strong>: Cannot be used with <code>--no-preview</code> or <code>--hide-preview</code></li>
<li><strong>Use Case</strong>: Ensure preview is always available</li>
</ul>
<h4 class="anchor anchorWithStickyNavbar_Fogf" id="-p---preview-command-string"><code>-p, --preview-command &lt;STRING&gt;</code><a href="#-p---preview-command-string" class="hash-link" aria-label="Direct link to -p---preview-command-string" title="Direct link to -p---preview-command-string"></a></h4>
<p><strong>Purpose</strong>: Command to generate preview content for the selected entry</p>
<ul>
<li><strong>Both Modes</strong>: Same behavior</li>
<li><strong>Requires</strong>: <code>--source-command</code> (in ad-hoc mode)</li>
<li><strong>Conflicts</strong>: Cannot be used with <code>--no-preview</code></li>
<li><strong>Example</strong>: <code>--preview-command &quot;bat -n --color=always &#x27;{}&#x27;&quot;</code></li>
</ul>
<h4 class="anchor anchorWithStickyNavbar_Fogf" id="--preview-header-string"><code>--preview-header &lt;STRING&gt;</code><a href="#--preview-header-string" class="hash-link" aria-label="Direct link to --preview-header-string" title="Direct link to --preview-header-string"></a></h4>
<p><strong>Purpose</strong>: Template for text displayed above the preview panel</p>
<ul>
<li><strong>Both Modes</strong>: Same behavior</li>
<li><strong>Requires</strong>: <code>--preview-command</code> (in ad-hoc mode)</li>
<li><strong>Conflicts</strong>: Cannot be used with <code>--no-preview</code></li>
<li><strong>Example</strong>: <code>--preview-header &quot;File: {split:/:-1|upper}&quot;</code></li>
</ul>
<h4 class="anchor anchorWithStickyNavbar_Fogf" id="--preview-footer-string"><code>--preview-footer &lt;STRING&gt;</code><a href="#--preview-footer-string" class="hash-link" aria-label="Direct link to --preview-footer-string" title="Direct link to --preview-footer-string"></a></h4>
<p><strong>Purpose</strong>: Template for text displayed below the preview panel</p>
<ul>
<li><strong>Both Modes</strong>: Same behavior</li>
<li><strong>Requires</strong>: <code>--preview-command</code> (in ad-hoc mode)</li>
<li><strong>Conflicts</strong>: Cannot be used with <code>--no-preview</code></li>
</ul>
<h4 class="anchor anchorWithStickyNavbar_Fogf" id="--preview-offset-string"><code>--preview-offset &lt;STRING&gt;</code><a href="#--preview-offset-string" class="hash-link" aria-label="Direct link to --preview-offset-string" title="Direct link to --preview-offset-string"></a></h4>
<p><strong>Purpose</strong>: Template that determines the scroll position in the preview</p>
<ul>
<li><strong>Both Modes</strong>: Same behavior</li>
<li><strong>Requires</strong>: <code>--preview-command</code> (in ad-hoc mode)</li>
<li><strong>Conflicts</strong>: Cannot be used with <code>--no-preview</code></li>
<li><strong>Example</strong>: <code>--preview-offset &quot;10&quot;</code> (start at line 10)</li>
</ul>
<h4 class="anchor anchorWithStickyNavbar_Fogf" id="--preview-size-integer"><code>--preview-size &lt;INTEGER&gt;</code><a href="#--preview-size-integer" class="hash-link" aria-label="Direct link to --preview-size-integer" title="Direct link to --preview-size-integer"></a></h4>
<p><strong>Purpose</strong>: Width of the preview panel as a percentage</p>
<ul>
<li><strong>Both Modes</strong>: Same behavior</li>
<li><strong>Default</strong>: 50% of screen width</li>
<li><strong>Range</strong>: 1-99</li>
<li><strong>Conflicts</strong>: Cannot be used with <code>--no-preview</code></li>
</ul>
<h3 class="anchor anchorWithStickyNavbar_Fogf" id="-status-bar-options"> Status Bar Options<a href="#-status-bar-options" class="hash-link" aria-label="Direct link to Status Bar Options" title="Direct link to Status Bar Options"></a></h3>
<h4 class="anchor anchorWithStickyNavbar_Fogf" id="--no-status-bar"><code>--no-status-bar</code><a href="#--no-status-bar" class="hash-link" aria-label="Direct link to --no-status-bar" title="Direct link to --no-status-bar"></a></h4>
<p><strong>Purpose</strong>: Disable status bar feature, toggling is not possible</p>
<ul>
<li><strong>Both Modes</strong>: Same behavior</li>
<li><strong>Conflicts</strong>: Cannot be used with <code>--hide-status-bar</code> or <code>--show-status-bar</code></li>
<li><strong>Use Case</strong>: Minimal interface</li>
</ul>
<h4 class="anchor anchorWithStickyNavbar_Fogf" id="--hide-status-bar"><code>--hide-status-bar</code><a href="#--hide-status-bar" class="hash-link" aria-label="Direct link to --hide-status-bar" title="Direct link to --hide-status-bar"></a></h4>
<p><strong>Purpose</strong>: Starts the interface with the status bar hidden</p>
<ul>
<li><strong>Both Modes</strong>: Same behavior</li>
<li><strong>Conflicts</strong>: Cannot be used with <code>--no-status-bar</code> or <code>--show-status-bar</code></li>
<li><strong>Use Case</strong>: Clean interface with option to show status later</li>
</ul>
<h4 class="anchor anchorWithStickyNavbar_Fogf" id="--show-status-bar"><code>--show-status-bar</code><a href="#--show-status-bar" class="hash-link" aria-label="Direct link to --show-status-bar" title="Direct link to --show-status-bar"></a></h4>
<p><strong>Purpose</strong>: Starts the interface with the status bar visible</p>
<ul>
<li><strong>Both Modes</strong>: Same behavior</li>
<li><strong>Conflicts</strong>: Cannot be used with <code>--no-status-bar</code> or <code>--hide-status-bar</code></li>
<li><strong>Use Case</strong>: Ensure status information is always available</li>
</ul>
<h3 class="anchor anchorWithStickyNavbar_Fogf" id="-remote-control-options">📡 Remote Control Options<a href="#-remote-control-options" class="hash-link" aria-label="Direct link to 📡 Remote Control Options" title="Direct link to 📡 Remote Control Options"></a></h3>
<h4 class="anchor anchorWithStickyNavbar_Fogf" id="--no-remote"><code>--no-remote</code><a href="#--no-remote" class="hash-link" aria-label="Direct link to --no-remote" title="Direct link to --no-remote"></a></h4>
<p><strong>Purpose</strong>: Disable remote control feature, toggling is not possible</p>
<ul>
<li><strong>Both Modes</strong>: Same behavior</li>
<li><strong>Conflicts</strong>: Cannot be used with <code>--hide-remote</code> or <code>--show-remote</code></li>
<li><strong>Use Case</strong>: Single-channel mode, embedded usage</li>
</ul>
<h4 class="anchor anchorWithStickyNavbar_Fogf" id="--hide-remote"><code>--hide-remote</code><a href="#--hide-remote" class="hash-link" aria-label="Direct link to --hide-remote" title="Direct link to --hide-remote"></a></h4>
<p><strong>Purpose</strong>: Starts the interface with the remote control hidden</p>
<ul>
<li><strong>Both Modes</strong>: Same behavior</li>
<li><strong>Conflicts</strong>: Cannot be used with <code>--no-remote</code> or <code>--show-remote</code></li>
<li><strong>Use Case</strong>: Start in single-channel mode, access remote later</li>
</ul>
<h4 class="anchor anchorWithStickyNavbar_Fogf" id="--show-remote"><code>--show-remote</code><a href="#--show-remote" class="hash-link" aria-label="Direct link to --show-remote" title="Direct link to --show-remote"></a></h4>
<p><strong>Purpose</strong>: Starts the interface with the remote control visible</p>
<ul>
<li><strong>Both Modes</strong>: Same behavior</li>
<li><strong>Conflicts</strong>: Cannot be used with <code>--no-remote</code> or <code>--hide-remote</code></li>
<li><strong>Use Case</strong>: Ensure channel switching is always available</li>
</ul>
<h3 class="anchor anchorWithStickyNavbar_Fogf" id="-help-panel-options">❓ Help Panel Options<a href="#-help-panel-options" class="hash-link" aria-label="Direct link to ❓ Help Panel Options" title="Direct link to ❓ Help Panel Options"></a></h3>
<h4 class="anchor anchorWithStickyNavbar_Fogf" id="--no-help-panel"><code>--no-help-panel</code><a href="#--no-help-panel" class="hash-link" aria-label="Direct link to --no-help-panel" title="Direct link to --no-help-panel"></a></h4>
<p><strong>Purpose</strong>: Disable help panel feature, toggling is not possible</p>
<ul>
<li><strong>Both Modes</strong>: Same behavior</li>
<li><strong>Conflicts</strong>: Cannot be used with <code>--hide-help-panel</code> or <code>--show-help-panel</code></li>
<li><strong>Use Case</strong>: Minimal interface</li>
</ul>
<h4 class="anchor anchorWithStickyNavbar_Fogf" id="--hide-help-panel"><code>--hide-help-panel</code><a href="#--hide-help-panel" class="hash-link" aria-label="Direct link to --hide-help-panel" title="Direct link to --hide-help-panel"></a></h4>
<p><strong>Purpose</strong>: Starts the interface with the help panel hidden</p>
<ul>
<li><strong>Both Modes</strong>: Same behavior</li>
<li><strong>Conflicts</strong>: Cannot be used with <code>--no-help-panel</code> or <code>--show-help-panel</code></li>
<li><strong>Use Case</strong>: Clean interface with option to show help later</li>
</ul>
<h4 class="anchor anchorWithStickyNavbar_Fogf" id="--show-help-panel"><code>--show-help-panel</code><a href="#--show-help-panel" class="hash-link" aria-label="Direct link to --show-help-panel" title="Direct link to --show-help-panel"></a></h4>
<p><strong>Purpose</strong>: Starts the interface with the help panel visible</p>
<ul>
<li><strong>Both Modes</strong>: Same behavior</li>
<li><strong>Conflicts</strong>: Cannot be used with <code>--no-help-panel</code> or <code>--hide-help-panel</code></li>
<li><strong>Use Case</strong>: Ensure help information is always available</li>
</ul>
<h3 class="anchor anchorWithStickyNavbar_Fogf" id="-interface-and-layout-options">🎨 Interface and Layout Options<a href="#-interface-and-layout-options" class="hash-link" aria-label="Direct link to 🎨 Interface and Layout Options" title="Direct link to 🎨 Interface and Layout Options"></a></h3>
<h4 class="anchor anchorWithStickyNavbar_Fogf" id="--layout-layout"><code>--layout &lt;LAYOUT&gt;</code><a href="#--layout-layout" class="hash-link" aria-label="Direct link to --layout-layout" title="Direct link to --layout-layout"></a></h4>
<p><strong>Purpose</strong>: Controls the overall interface orientation</p>
<ul>
<li><strong>Both Modes</strong>: Same behavior</li>
<li><strong>Values</strong>: <code>landscape</code> (side-by-side), <code>portrait</code> (stacked)</li>
<li><strong>Default</strong>: <code>landscape</code></li>
</ul>
<h4 class="anchor anchorWithStickyNavbar_Fogf" id="--input-header-string"><code>--input-header &lt;STRING&gt;</code><a href="#--input-header-string" class="hash-link" aria-label="Direct link to --input-header-string" title="Direct link to --input-header-string"></a></h4>
<p><strong>Purpose</strong>: Template for text displayed above the input field</p>
<ul>
<li><strong>Both Modes</strong>: Same behavior</li>
<li><strong>Default</strong>: Channel name (channel mode) or empty (ad-hoc mode)</li>
<li><strong>Example</strong>: <code>--input-header &quot;Search files:&quot;</code></li>
</ul>
<h4 class="anchor anchorWithStickyNavbar_Fogf" id="--ui-scale-integer"><code>--ui-scale &lt;INTEGER&gt;</code><a href="#--ui-scale-integer" class="hash-link" aria-label="Direct link to --ui-scale-integer" title="Direct link to --ui-scale-integer"></a></h4>
<p><strong>Purpose</strong>: Scales the entire interface size</p>
<ul>
<li><strong>Both Modes</strong>: Same behavior</li>
<li><strong>Default</strong>: 100%</li>
<li><strong>Range</strong>: 10-100%</li>
<li><strong>Use Case</strong>: Adapt to different screen sizes or preferences</li>
</ul>
<h4 class="anchor anchorWithStickyNavbar_Fogf" id="--height-integer"><code>--height &lt;INTEGER&gt;</code><a href="#--height-integer" class="hash-link" aria-label="Direct link to --height-integer" title="Direct link to --height-integer"></a></h4>
<p><strong>Purpose</strong>: Sets a fixed height for non-fullscreen mode</p>
<ul>
<li><strong>Both Modes</strong>: Same behavior</li>
<li><strong>Range</strong>: 6 or higher (minimum UI height required)</li>
<li><strong>Conflicts</strong>: Cannot be used with <code>--inline</code></li>
<li><strong>Use Case</strong>: Precise control over interface height</li>
</ul>
<h4 class="anchor anchorWithStickyNavbar_Fogf" id="--width-integer"><code>--width &lt;INTEGER&gt;</code><a href="#--width-integer" class="hash-link" aria-label="Direct link to --width-integer" title="Direct link to --width-integer"></a></h4>
<p><strong>Purpose</strong>: Sets a fixed width for non-fullscreen mode</p>
<ul>
<li><strong>Both Modes</strong>: Same behavior</li>
<li><strong>Range</strong>: 10 or higher (minimum UI width required)</li>
<li><strong>Requires</strong>: Must be used with <code>--inline</code> or <code>--height</code></li>
<li><strong>Use Case</strong>: Precise control over interface width</li>
</ul>
<h4 class="anchor anchorWithStickyNavbar_Fogf" id="--inline"><code>--inline</code><a href="#--inline" class="hash-link" aria-label="Direct link to --inline" title="Direct link to --inline"></a></h4>
<p><strong>Purpose</strong>: Uses all available empty space at the bottom of the terminal</p>
<ul>
<li><strong>Both Modes</strong>: Same behavior</li>
<li><strong>Behavior</strong>: Automatically uses all available space below the cursor,
minimum height is ensured (set by default at 15 lines)</li>
<li><strong>Conflicts</strong>: Cannot be used with <code>--height</code></li>
<li><strong>Use Case</strong>: Use of all available space without entering fullscreen mode</li>
</ul>
<h3 class="anchor anchorWithStickyNavbar_Fogf" id="-input-and-interaction-options">⌨️ Input and Interaction Options<a href="#-input-and-interaction-options" class="hash-link" aria-label="Direct link to ⌨️ Input and Interaction Options" title="Direct link to ⌨️ Input and Interaction Options"></a></h3>
<h4 class="anchor anchorWithStickyNavbar_Fogf" id="-i---input-string"><code>-i, --input &lt;STRING&gt;</code><a href="#-i---input-string" class="hash-link" aria-label="Direct link to -i---input-string" title="Direct link to -i---input-string"></a></h4>
<p><strong>Purpose</strong>: Pre-fills the input prompt with specified text</p>
<ul>
<li><strong>Both Modes</strong>: Same behavior</li>
<li><strong>Use Case</strong>: Continue a previous search or provide default query</li>
<li><strong>Example</strong>: <code>-i &quot;main.py&quot;</code></li>
</ul>
<h4 class="anchor anchorWithStickyNavbar_Fogf" id="-k---keybindings-string"><code>-k, --keybindings &lt;STRING&gt;</code><a href="#-k---keybindings-string" class="hash-link" aria-label="Direct link to -k---keybindings-string" title="Direct link to -k---keybindings-string"></a></h4>
<p><strong>Purpose</strong>: Overrides default keyboard shortcuts</p>
<ul>
<li><strong>Both Modes</strong>: Same behavior</li>
<li><strong>Format</strong>: <code>action1=[&quot;key1&quot;,&quot;key2&quot;];action2=[&quot;key3&quot;]</code></li>
<li><strong>Example</strong>: <code>-k &#x27;quit=[&quot;q&quot;,&quot;esc&quot;];select=[&quot;enter&quot;,&quot;space&quot;]&#x27;</code></li>
</ul>
<h4 class="anchor anchorWithStickyNavbar_Fogf" id="--exact"><code>--exact</code><a href="#--exact" class="hash-link" aria-label="Direct link to --exact" title="Direct link to --exact"></a></h4>
<p><strong>Purpose</strong>: Changes matching behavior from fuzzy to exact substring matching</p>
<ul>
<li><strong>Both Modes</strong>: Same behavior</li>
<li><strong>Default</strong>: Fuzzy matching</li>
<li><strong>Use Case</strong>: When you need precise substring matches</li>
</ul>
<h3 class="anchor anchorWithStickyNavbar_Fogf" id="-selection-behavior-options">⚡ Selection Behavior Options<a href="#-selection-behavior-options" class="hash-link" aria-label="Direct link to ⚡ Selection Behavior Options" title="Direct link to ⚡ Selection Behavior Options"></a></h3>
<blockquote>
<p><strong>Note</strong>: These options are mutually exclusive - only one can be used at a time.</p>
</blockquote>
<h4 class="anchor anchorWithStickyNavbar_Fogf" id="--select-1"><code>--select-1</code><a href="#--select-1" class="hash-link" aria-label="Direct link to --select-1" title="Direct link to --select-1"></a></h4>
<p><strong>Purpose</strong>: Automatically selects and returns the entry if only one is found</p>
<ul>
<li><strong>Both Modes</strong>: Same behavior</li>
<li><strong>Use Case</strong>: Scripting scenarios where single results should be auto-selected</li>
</ul>
<h4 class="anchor anchorWithStickyNavbar_Fogf" id="--take-1"><code>--take-1</code><a href="#--take-1" class="hash-link" aria-label="Direct link to --take-1" title="Direct link to --take-1"></a></h4>
<p><strong>Purpose</strong>: Takes the first entry after loading completes</p>
<ul>
<li><strong>Both Modes</strong>: Same behavior</li>
<li><strong>Use Case</strong>: Scripts that always want the first/best result</li>
</ul>
<h4 class="anchor anchorWithStickyNavbar_Fogf" id="--take-1-fast"><code>--take-1-fast</code><a href="#--take-1-fast" class="hash-link" aria-label="Direct link to --take-1-fast" title="Direct link to --take-1-fast"></a></h4>
<p><strong>Purpose</strong>: Takes the first entry immediately as it appears</p>
<ul>
<li><strong>Both Modes</strong>: Same behavior</li>
<li><strong>Use Case</strong>: Maximum speed scripts that don&#x27;t care about all options</li>
</ul>
<h3 class="anchor anchorWithStickyNavbar_Fogf" id="-performance-and-monitoring-options">⚙️ Performance and Monitoring Options<a href="#-performance-and-monitoring-options" class="hash-link" aria-label="Direct link to ⚙️ Performance and Monitoring Options" title="Direct link to ⚙️ Performance and Monitoring Options"></a></h3>
<h4 class="anchor anchorWithStickyNavbar_Fogf" id="-t---tick-rate-float"><code>-t, --tick-rate &lt;FLOAT&gt;</code><a href="#-t---tick-rate-float" class="hash-link" aria-label="Direct link to -t---tick-rate-float" title="Direct link to -t---tick-rate-float"></a></h4>
<p><strong>Purpose</strong>: Controls how frequently the interface updates (times per second)</p>
<ul>
<li><strong>Both Modes</strong>: Same behavior</li>
<li><strong>Default</strong>: Auto-calculated based on system performance</li>
<li><strong>Validation</strong>: Must be positive number</li>
<li><strong>Example</strong>: <code>--tick-rate 30</code> (30 updates per second)</li>
</ul>
<h4 class="anchor anchorWithStickyNavbar_Fogf" id="--watch-float"><code>--watch &lt;FLOAT&gt;</code><a href="#--watch-float" class="hash-link" aria-label="Direct link to --watch-float" title="Direct link to --watch-float"></a></h4>
<p><strong>Purpose</strong>: Automatically re-runs the source command at regular intervals</p>
<ul>
<li><strong>Both Modes</strong>: Same behavior</li>
<li><strong>Default</strong>: 0 (disabled)</li>
<li><strong>Units</strong>: Seconds between updates</li>
<li><strong>Conflicts</strong>: Cannot be used with selection options (<code>--select-1</code>, <code>--take-1</code>, <code>--take-1-fast</code>)</li>
<li><strong>Example</strong>: <code>--watch 2.0</code> (update every 2 seconds)</li>
</ul>
<h3 class="anchor anchorWithStickyNavbar_Fogf" id="-directory-and-configuration-options">📁 Directory and Configuration Options<a href="#-directory-and-configuration-options" class="hash-link" aria-label="Direct link to 📁 Directory and Configuration Options" title="Direct link to 📁 Directory and Configuration Options"></a></h3>
<h4 class="anchor anchorWithStickyNavbar_Fogf" id="path-positional-argument-2"><code>[PATH]</code> (Positional Argument 2)<a href="#path-positional-argument-2" class="hash-link" aria-label="Direct link to path-positional-argument-2" title="Direct link to path-positional-argument-2"></a></h4>
<p><strong>Purpose</strong>: Sets the working directory for the command</p>
<ul>
<li><strong>Both Modes</strong>: Same behavior</li>
<li><strong>Default</strong>: Current directory</li>
<li><strong>Example</strong>: <code>tv files /home/user/projects</code></li>
</ul>
<h4 class="anchor anchorWithStickyNavbar_Fogf" id="--config-file-path"><code>--config-file &lt;PATH&gt;</code><a href="#--config-file-path" class="hash-link" aria-label="Direct link to --config-file-path" title="Direct link to --config-file-path"></a></h4>
<p><strong>Purpose</strong>: Uses a custom configuration file instead of the default</p>
<ul>
<li><strong>Both Modes</strong>: Same behavior</li>
<li><strong>Default</strong>: <code>~/.config/tv/config.toml</code> (Linux/macOS) or <code>%APPDATA%\tv\config.toml</code> (Windows)</li>
<li><strong>Use Case</strong>: Multiple configurations for different workflows</li>
</ul>
<h4 class="anchor anchorWithStickyNavbar_Fogf" id="--cable-dir-path"><code>--cable-dir &lt;PATH&gt;</code><a href="#--cable-dir-path" class="hash-link" aria-label="Direct link to --cable-dir-path" title="Direct link to --cable-dir-path"></a></h4>
<p><strong>Purpose</strong>: Uses a custom directory for channel definitions</p>
<ul>
<li><strong>Both Modes</strong>: Same behavior</li>
<li><strong>Default</strong>: <code>~/.config/tv/cable/</code> (Linux/macOS) or <code>%APPDATA%\tv\cable\</code> (Windows)</li>
<li><strong>Use Case</strong>: Custom channel collections or shared team channels</li>
</ul>
<h3 class="anchor anchorWithStickyNavbar_Fogf" id="-history-options">📚 History Options<a href="#-history-options" class="hash-link" aria-label="Direct link to 📚 History Options" title="Direct link to 📚 History Options"></a></h3>
<h4 class="anchor anchorWithStickyNavbar_Fogf" id="--global-history"><code>--global-history</code><a href="#--global-history" class="hash-link" aria-label="Direct link to --global-history" title="Direct link to --global-history"></a></h4>
<p><strong>Purpose</strong>: Enables global history for the current session</p>
<ul>
<li><strong>Both Modes</strong>: Same behavior</li>
<li><strong>Default</strong>: Channel-specific history (scoped to current channel)</li>
<li><strong>Use Case</strong>: Cross-channel workflow when you want to see all recent searches</li>
<li><strong>Example</strong>: <code>tv files --global-history</code></li>
</ul>
<h3 class="anchor anchorWithStickyNavbar_Fogf" id="-special-mode-options">🔧 Special Mode Options<a href="#-special-mode-options" class="hash-link" aria-label="Direct link to 🔧 Special Mode Options" title="Direct link to 🔧 Special Mode Options"></a></h3>
<h4 class="anchor anchorWithStickyNavbar_Fogf" id="--autocomplete-prompt-string"><code>--autocomplete-prompt &lt;STRING&gt;</code><a href="#--autocomplete-prompt-string" class="hash-link" aria-label="Direct link to --autocomplete-prompt-string" title="Direct link to --autocomplete-prompt-string"></a></h4>
<p><strong>Purpose</strong>: ⚡ <strong>Activates Channel Mode</strong> - Auto-detects channel from shell command</p>
<ul>
<li><strong>Effect</strong>: Switches to Channel Mode automatically</li>
<li><strong>Behavior</strong>: Analyzes the provided command to determine appropriate channel</li>
<li><strong>Conflicts</strong>: Cannot be used with <code>[CHANNEL]</code> positional argument</li>
<li><strong>Use Case</strong>: Shell integration and smart channel detection</li>
<li><strong>Example</strong>: <code>--autocomplete-prompt &quot;git log --oneline&quot;</code></li>
</ul>
<h2 class="anchor anchorWithStickyNavbar_Fogf" id="subcommands">Subcommands<a href="#subcommands" class="hash-link" aria-label="Direct link to Subcommands" title="Direct link to Subcommands"></a></h2>
<h3 class="anchor anchorWithStickyNavbar_Fogf" id="list-channels"><code>list-channels</code><a href="#list-channels" class="hash-link" aria-label="Direct link to list-channels" title="Direct link to list-channels"></a></h3>
<p>Lists all available channels in the cable directory.</p>
<div class="language-bash codeBlockContainer_MbdR theme-code-block" style="--prism-color:#F8F8F2;--prism-background-color:#282A36"><div class="codeBlockContent_WPSJ"><pre tabindex="0" class="prism-code language-bash codeBlock_ke8T thin-scrollbar" style="color:#F8F8F2;background-color:#282A36"><code class="codeBlockLines_oe7S"><span class="token-line" style="color:#F8F8F2"><span class="token plain">tv list-channels</span><br></span></code></pre></div></div>
<h3 class="anchor anchorWithStickyNavbar_Fogf" id="init-shell"><code>init &lt;SHELL&gt;</code><a href="#init-shell" class="hash-link" aria-label="Direct link to init-shell" title="Direct link to init-shell"></a></h3>
<p>Generates shell completion script for the specified shell.</p>
<p><strong>Supported shells</strong>: <code>bash</code>, <code>zsh</code>, <code>fish</code>, <code>powershell</code>, <code>cmd</code></p>
<div class="language-bash codeBlockContainer_MbdR theme-code-block" style="--prism-color:#F8F8F2;--prism-background-color:#282A36"><div class="codeBlockContent_WPSJ"><pre tabindex="0" class="prism-code language-bash codeBlock_ke8T thin-scrollbar" style="color:#F8F8F2;background-color:#282A36"><code class="codeBlockLines_oe7S"><span class="token-line" style="color:#F8F8F2"><span class="token plain">tv init </span><span class="token function" style="color:rgb(80, 250, 123)">zsh</span><span class="token plain"> </span><span class="token operator">&gt;</span><span class="token plain"> ~/.zshrc.d/tv-completion.zsh</span><br></span></code></pre></div></div>
<h3 class="anchor anchorWithStickyNavbar_Fogf" id="update-channels"><code>update-channels</code><a href="#update-channels" class="hash-link" aria-label="Direct link to update-channels" title="Direct link to update-channels"></a></h3>
<p>Downloads the latest channel prototypes from GitHub.</p>
<div class="language-bash codeBlockContainer_MbdR theme-code-block" style="--prism-color:#F8F8F2;--prism-background-color:#282A36"><div class="codeBlockContent_WPSJ"><pre tabindex="0" class="prism-code language-bash codeBlock_ke8T thin-scrollbar" style="color:#F8F8F2;background-color:#282A36"><code class="codeBlockLines_oe7S"><span class="token-line" style="color:#F8F8F2"><span class="token plain">tv update-channels</span><br></span></code></pre></div></div>
<h2 class="anchor anchorWithStickyNavbar_Fogf" id="usage-rules-and-restrictions">Usage Rules and Restrictions<a href="#usage-rules-and-restrictions" class="hash-link" aria-label="Direct link to Usage Rules and Restrictions" title="Direct link to Usage Rules and Restrictions"></a></h2>
<blockquote>
<p><strong>Note</strong>: Detailed requirements and conflicts for each flag are covered in the <a href="#options">Options</a> section above. This section provides a high-level overview of the key rules.</p>
</blockquote>
<h3 class="anchor anchorWithStickyNavbar_Fogf" id="-ad-hoc-mode-requirements">🎯 Ad-hoc Mode Requirements<a href="#-ad-hoc-mode-requirements" class="hash-link" aria-label="Direct link to 🎯 Ad-hoc Mode Requirements" title="Direct link to 🎯 Ad-hoc Mode Requirements"></a></h3>
<p>When using Television without a channel, certain flags become mandatory:</p>
<ul>
<li><strong><code>--source-command</code> is required</strong> - without this, no entries will be generated</li>
<li><strong>Preview dependencies</strong> - all <code>--preview-*</code> flags require <code>--preview-command</code> to be functional</li>
<li><strong>Source formatting dependencies</strong> - <code>--source-display</code> and <code>--source-output</code> require <code>--source-command</code></li>
</ul>
<h3 class="anchor anchorWithStickyNavbar_Fogf" id="-mutually-exclusive-options">🚫 Mutually Exclusive Options<a href="#-mutually-exclusive-options" class="hash-link" aria-label="Direct link to 🚫 Mutually Exclusive Options" title="Direct link to 🚫 Mutually Exclusive Options"></a></h3>
<p>These option groups cannot be used together:</p>
<ul>
<li><strong>Selection behavior</strong>: Only one of <code>--select-1</code>, <code>--take-1</code>, or <code>--take-1-fast</code></li>
<li><strong>Preview control</strong>: <code>--no-preview</code> conflicts with all <code>--preview-*</code> flags and <code>--hide-preview</code>/<code>--show-preview</code></li>
<li><strong>Preview visibility</strong>: Only one of <code>--no-preview</code>, <code>--hide-preview</code>, or <code>--show-preview</code></li>
<li><strong>Status bar control</strong>: Only one of <code>--no-status-bar</code>, <code>--hide-status-bar</code>, or <code>--show-status-bar</code></li>
<li><strong>Remote control</strong>: Only one of <code>--no-remote</code>, <code>--hide-remote</code>, or <code>--show-remote</code></li>
<li><strong>Help panel control</strong>: Only one of <code>--no-help-panel</code>, <code>--hide-help-panel</code>, or <code>--show-help-panel</code></li>
<li><strong>Channel selection</strong>: Cannot use both <code>[CHANNEL]</code> argument and <code>--autocomplete-prompt</code></li>
<li><strong>Watch vs selection</strong>: <code>--watch</code> cannot be used with auto-selection flags</li>
</ul>
<h3 class="anchor anchorWithStickyNavbar_Fogf" id="-channel-mode-benefits">✅ Channel Mode Benefits<a href="#-channel-mode-benefits" class="hash-link" aria-label="Direct link to ✅ Channel Mode Benefits" title="Direct link to ✅ Channel Mode Benefits"></a></h3>
<p>Channels provide sensible defaults, making the tool more flexible:</p>
<ul>
<li>Preview and source flags work independently (channel provides missing pieces)</li>
<li>All UI options have reasonable defaults</li>
<li>Less strict validation since channels fill in the gaps</li>
</ul>
<h2 class="anchor anchorWithStickyNavbar_Fogf" id="configuration">Configuration<a href="#configuration" class="hash-link" aria-label="Direct link to Configuration" title="Direct link to Configuration"></a></h2>
<h3 class="anchor anchorWithStickyNavbar_Fogf" id="-configuration-priority">⚡ Configuration Priority<a href="#-configuration-priority" class="hash-link" aria-label="Direct link to ⚡ Configuration Priority" title="Direct link to ⚡ Configuration Priority"></a></h3>
<p>Television uses a layered configuration system where each layer can override the previous:</p>
<ol>
<li><strong>CLI flags</strong> - Highest priority, overrides everything</li>
<li><strong>Channel configuration</strong> - Channel-specific settings</li>
<li><strong>User config file</strong> - Personal preferences</li>
<li><strong>Built-in defaults</strong> - Fallback values</li>
</ol>
<h3 class="anchor anchorWithStickyNavbar_Fogf" id="-configuration-locations">📁 Configuration Locations<a href="#-configuration-locations" class="hash-link" aria-label="Direct link to 📁 Configuration Locations" title="Direct link to 📁 Configuration Locations"></a></h3>
<h4 class="anchor anchorWithStickyNavbar_Fogf" id="user-configuration-file">User Configuration File<a href="#user-configuration-file" class="hash-link" aria-label="Direct link to User Configuration File" title="Direct link to User Configuration File"></a></h4>
<ul>
<li><strong>Linux/macOS</strong>: <code>~/.config/tv/config.toml</code></li>
<li><strong>Windows</strong>: <code>%APPDATA%\tv\config.toml</code></li>
</ul>
<h4 class="anchor anchorWithStickyNavbar_Fogf" id="channel-definitions-cable-directory">Channel Definitions (Cable Directory)<a href="#channel-definitions-cable-directory" class="hash-link" aria-label="Direct link to Channel Definitions (Cable Directory)" title="Direct link to Channel Definitions (Cable Directory)"></a></h4>
<ul>
<li><strong>Linux/macOS</strong>: <code>~/.config/tv/cable/</code></li>
<li><strong>Windows</strong>: <code>%APPDATA%\tv\cable\</code></li>
</ul>
<blockquote>
<p><strong>Tip</strong>: Use <code>--config-file</code> and <code>--cable-dir</code> flags to override these default locations</p>
</blockquote>
<h3 class="anchor anchorWithStickyNavbar_Fogf" id="-feature-configuration">🎛️ Feature Configuration<a href="#-feature-configuration" class="hash-link" aria-label="Direct link to 🎛️ Feature Configuration" title="Direct link to 🎛️ Feature Configuration"></a></h3>
<p>Television features support dual-state control: <strong>enabled/disabled</strong> and <strong>visible/not visible</strong>.</p>
<blockquote>
<p><strong>📖 For more details on the ui feature documentation</strong>, see <a href="/television/docs/Developers/ui-features"><code>ui-features.md</code></a>.</p>
</blockquote>
<h4 class="anchor anchorWithStickyNavbar_Fogf" id="quick-feature-overview">Quick Feature Overview<a href="#quick-feature-overview" class="hash-link" aria-label="Direct link to Quick Feature Overview" title="Direct link to Quick Feature Overview"></a></h4>
<p>Television supports four main UI features:</p>
<table><thead><tr><th>Feature</th><th>Purpose</th><th>Default State</th><th>CLI Controls</th></tr></thead><tbody><tr><td><strong>Preview Panel</strong></td><td>Shows contextual information for selected entries</td><td>Enabled &amp; Visible</td><td><code>--no-preview</code>, <code>--hide-preview</code>, <code>--show-preview</code></td></tr><tr><td><strong>Status Bar</strong></td><td>Displays application status and available actions</td><td>Enabled &amp; Visible</td><td><code>--no-status-bar</code>, <code>--hide-status-bar</code>, <code>--show-status-bar</code></td></tr><tr><td><strong>Help Panel</strong></td><td>Shows contextual help and keyboard shortcuts</td><td>Enabled but Hidden</td><td><code>--no-help-panel</code>, <code>--hide-help-panel</code>, <code>--show-help-panel</code></td></tr><tr><td><strong>Remote Control</strong></td><td>Provides channel switching interface</td><td>Enabled but Hidden</td><td><code>--no-remote</code>, <code>--hide-remote</code>, <code>--show-remote</code></td></tr></tbody></table>
<h4 class="anchor anchorWithStickyNavbar_Fogf" id="cli-feature-override-examples">CLI Feature Override Examples<a href="#cli-feature-override-examples" class="hash-link" aria-label="Direct link to CLI Feature Override Examples" title="Direct link to CLI Feature Override Examples"></a></h4>
<div class="language-bash codeBlockContainer_MbdR theme-code-block" style="--prism-color:#F8F8F2;--prism-background-color:#282A36"><div class="codeBlockContent_WPSJ"><pre tabindex="0" class="prism-code language-bash codeBlock_ke8T thin-scrollbar" style="color:#F8F8F2;background-color:#282A36"><code class="codeBlockLines_oe7S"><span class="token-line" style="color:#F8F8F2"><span class="token comment" style="color:rgb(98, 114, 164)"># Control visibility while keeping functionality</span><span class="token plain"></span><br></span><span class="token-line" style="color:#F8F8F2"><span class="token plain">tv files --hide-preview --show-status-bar</span><br></span><span class="token-line" style="color:#F8F8F2"><span class="token plain" style="display:inline-block"></span><br></span><span class="token-line" style="color:#F8F8F2"><span class="token plain"></span><span class="token comment" style="color:rgb(98, 114, 164)"># Force features on</span><span class="token plain"></span><br></span><span class="token-line" style="color:#F8F8F2"><span class="token plain">tv files --show-preview --show-remote</span><br></span><span class="token-line" style="color:#F8F8F2"><span class="token plain" style="display:inline-block"></span><br></span><span class="token-line" style="color:#F8F8F2"><span class="token plain"></span><span class="token comment" style="color:rgb(98, 114, 164)"># Disable completely</span><span class="token plain"></span><br></span><span class="token-line" style="color:#F8F8F2"><span class="token plain">tv files --no-preview --no-remote</span><br></span><span class="token-line" style="color:#F8F8F2"><span class="token plain" style="display:inline-block"></span><br></span><span class="token-line" style="color:#F8F8F2"><span class="token plain"></span><span class="token comment" style="color:rgb(98, 114, 164)"># Mixed control</span><span class="token plain"></span><br></span><span class="token-line" style="color:#F8F8F2"><span class="token plain">tv files --hide-status-bar --show-remote</span><br></span></code></pre></div></div>
<h2 class="anchor anchorWithStickyNavbar_Fogf" id="template-system">Template System<a href="#template-system" class="hash-link" aria-label="Direct link to Template System" title="Direct link to Template System"></a></h2>
<p>Television uses a powerful template system for dynamic content generation. Templates are enclosed in curly braces <code>{}</code> and support complex operations.</p>
<h3 class="anchor anchorWithStickyNavbar_Fogf" id="template-enabled-flags">Template-Enabled Flags<a href="#template-enabled-flags" class="hash-link" aria-label="Direct link to Template-Enabled Flags" title="Direct link to Template-Enabled Flags"></a></h3>
<table><thead><tr><th>Flag Category</th><th>Flags Using Templates</th></tr></thead><tbody><tr><td><strong>Source</strong></td><td><code>--source-command</code>, <code>--source-display</code>, <code>--source-output</code></td></tr><tr><td><strong>Preview</strong></td><td><code>--preview-command</code>, <code>--preview-offset</code></td></tr><tr><td><strong>Headers</strong></td><td><code>--input-header</code>, <code>--preview-header</code>, <code>--preview-footer</code></td></tr></tbody></table>
<h3 class="anchor anchorWithStickyNavbar_Fogf" id="basic-template-syntax">Basic Template Syntax<a href="#basic-template-syntax" class="hash-link" aria-label="Direct link to Basic Template Syntax" title="Direct link to Basic Template Syntax"></a></h3>
<p>Templates support a wide range of operations that can be chained together:</p>
<div class="language-text codeBlockContainer_MbdR theme-code-block" style="--prism-color:#F8F8F2;--prism-background-color:#282A36"><div class="codeBlockContent_WPSJ"><pre tabindex="0" class="prism-code language-text codeBlock_ke8T thin-scrollbar" style="color:#F8F8F2;background-color:#282A36"><code class="codeBlockLines_oe7S"><span class="token-line" style="color:#F8F8F2"><span class="token plain">{operation1|operation2|operation3}</span><br></span></code></pre></div></div>
<h3 class="anchor anchorWithStickyNavbar_Fogf" id="core-template-operations">Core Template Operations<a href="#core-template-operations" class="hash-link" aria-label="Direct link to Core Template Operations" title="Direct link to Core Template Operations"></a></h3>
<table><thead><tr><th>Operation</th><th>Description</th><th>Example</th></tr></thead><tbody><tr><td><code>{}</code></td><td>Full entry (passthrough)</td><td><code>{}</code> → original entry</td></tr><tr><td><code>{split:SEPARATOR:RANGE}</code></td><td>Split text and extract parts</td><td><code>{split:/:1}</code> → last path component</td></tr><tr><td><code>{upper}</code></td><td>Convert to uppercase</td><td><code>{upper}</code>&quot;HELLO&quot;</td></tr><tr><td><code>{lower}</code></td><td>Convert to lowercase</td><td><code>{lower}</code>&quot;hello&quot;</td></tr><tr><td><code>{trim}</code></td><td>Remove whitespace</td><td><code>{trim}</code>&quot;text&quot;</td></tr><tr><td><code>{append:TEXT}</code></td><td>Add text to end</td><td><code>{append:.txt}</code>&quot;file.txt&quot;</td></tr><tr><td><code>{prepend:TEXT}</code></td><td>Add text to beginning</td><td><code>{prepend:/home/}</code>&quot;/home/file&quot;</td></tr></tbody></table>
<h3 class="anchor anchorWithStickyNavbar_Fogf" id="advanced-template-operations">Advanced Template Operations<a href="#advanced-template-operations" class="hash-link" aria-label="Direct link to Advanced Template Operations" title="Direct link to Advanced Template Operations"></a></h3>
<table><thead><tr><th>Operation</th><th>Description</th><th>Example</th></tr></thead><tbody><tr><td><code>{replace:s/PATTERN/REPLACEMENT/FLAGS}</code></td><td>Regex find and replace</td><td><code>{replace:s/\\.py$/.backup/}</code></td></tr><tr><td><code>{regex_extract:PATTERN}</code></td><td>Extract matching text</td><td><code>{regex_extract:\\d+}</code> → extract numbers</td></tr><tr><td><code>{filter:PATTERN}</code></td><td>Keep items matching pattern</td><td><code>{split:,:..|filter:^test}</code></td></tr><tr><td><code>{sort}</code></td><td>Sort list items</td><td><code>{split:,:..|sort}</code></td></tr><tr><td><code>{unique}</code></td><td>Remove duplicates</td><td><code>{split:,:..|unique}</code></td></tr><tr><td><code>{join:SEPARATOR}</code></td><td>Join list with separator</td><td><code>{split:,:..|join:-}</code></td></tr></tbody></table>
<h3 class="anchor anchorWithStickyNavbar_Fogf" id="template-examples">Template Examples<a href="#template-examples" class="hash-link" aria-label="Direct link to Template Examples" title="Direct link to Template Examples"></a></h3>
<div class="language-text codeBlockContainer_MbdR theme-code-block" style="--prism-color:#F8F8F2;--prism-background-color:#282A36"><div class="codeBlockContent_WPSJ"><pre tabindex="0" class="prism-code language-text codeBlock_ke8T thin-scrollbar" style="color:#F8F8F2;background-color:#282A36"><code class="codeBlockLines_oe7S"><span class="token-line" style="color:#F8F8F2"><span class="token plain"># File path manipulation</span><br></span><span class="token-line" style="color:#F8F8F2"><span class="token plain">{split:/:-1} # Get filename from path</span><br></span><span class="token-line" style="color:#F8F8F2"><span class="token plain">{split:/:0..-1|join:/} # Get directory from path</span><br></span><span class="token-line" style="color:#F8F8F2"><span class="token plain" style="display:inline-block"></span><br></span><span class="token-line" style="color:#F8F8F2"><span class="token plain"># Text processing</span><br></span><span class="token-line" style="color:#F8F8F2"><span class="token plain">{split: :..|map:{upper}|join:_} # &quot;hello world&quot;&quot;HELLO_WORLD&quot;</span><br></span><span class="token-line" style="color:#F8F8F2"><span class="token plain">{trim|replace:s/\s+/_/g} # Replace spaces with underscores</span><br></span><span class="token-line" style="color:#F8F8F2"><span class="token plain" style="display:inline-block"></span><br></span><span class="token-line" style="color:#F8F8F2"><span class="token plain"># Data extraction</span><br></span><span class="token-line" style="color:#F8F8F2"><span class="token plain">{regex_extract:@(.+)} # Extract email domain</span><br></span><span class="token-line" style="color:#F8F8F2"><span class="token plain">{split:,:..|filter:^[A-Z]} # Filter items starting with uppercase</span><br></span></code></pre></div></div>
<h3 class="anchor anchorWithStickyNavbar_Fogf" id="range-specifications">Range Specifications<a href="#range-specifications" class="hash-link" aria-label="Direct link to Range Specifications" title="Direct link to Range Specifications"></a></h3>
<table><thead><tr><th>Syntax</th><th>Description</th></tr></thead><tbody><tr><td><code>N</code></td><td>Single index (0-based)</td></tr><tr><td><code>N..M</code></td><td>Range exclusive (items N to M-1)</td></tr><tr><td><code>N..=M</code></td><td>Range inclusive (items N to M)</td></tr><tr><td><code>N..</code></td><td>From N to end</td></tr><tr><td><code>..M</code></td><td>From start to M-1</td></tr><tr><td><code>..</code></td><td>All items</td></tr><tr><td><code>-1</code></td><td>Last item</td></tr><tr><td><code>-N</code></td><td>N-th from end</td></tr></tbody></table>
<p>For complete template documentation, see the <a href="https://github.com/lalvarezt/string_pipeline/blob/main/docs/template-system.md" target="_blank" rel="noopener noreferrer">Template System Documentation</a>.</p>
<h2 class="anchor anchorWithStickyNavbar_Fogf" id="examples">Examples<a href="#examples" class="hash-link" aria-label="Direct link to Examples" title="Direct link to Examples"></a></h2>
<blockquote>
<p><strong>Note</strong>: More detailed examples with explanations are included in each option&#x27;s documentation above.</p>
</blockquote>
<h3 class="anchor anchorWithStickyNavbar_Fogf" id="-quick-start-examples">🎯 Quick Start Examples<a href="#-quick-start-examples" class="hash-link" aria-label="Direct link to 🎯 Quick Start Examples" title="Direct link to 🎯 Quick Start Examples"></a></h3>
<h4 class="anchor anchorWithStickyNavbar_Fogf" id="channel-mode-recommended">Channel Mode (Recommended)<a href="#channel-mode-recommended" class="hash-link" aria-label="Direct link to Channel Mode (Recommended)" title="Direct link to Channel Mode (Recommended)"></a></h4>
<div class="language-bash codeBlockContainer_MbdR theme-code-block" style="--prism-color:#F8F8F2;--prism-background-color:#282A36"><div class="codeBlockContent_WPSJ"><pre tabindex="0" class="prism-code language-bash codeBlock_ke8T thin-scrollbar" style="color:#F8F8F2;background-color:#282A36"><code class="codeBlockLines_oe7S"><span class="token-line" style="color:#F8F8F2"><span class="token comment" style="color:rgb(98, 114, 164)"># Basic usage - use built-in channels</span><span class="token plain"></span><br></span><span class="token-line" style="color:#F8F8F2"><span class="token plain">tv files </span><span class="token comment" style="color:rgb(98, 114, 164)"># Browse files in current directory</span><span class="token plain"></span><br></span><span class="token-line" style="color:#F8F8F2"><span class="token plain">tv git-log </span><span class="token comment" style="color:rgb(98, 114, 164)"># Browse git commit history</span><span class="token plain"></span><br></span><span class="token-line" style="color:#F8F8F2"><span class="token plain">tv docker-images </span><span class="token comment" style="color:rgb(98, 114, 164)"># Browse Docker images</span><span class="token plain"></span><br></span><span class="token-line" style="color:#F8F8F2"><span class="token plain" style="display:inline-block"></span><br></span><span class="token-line" style="color:#F8F8F2"><span class="token plain"></span><span class="token comment" style="color:rgb(98, 114, 164)"># Channel + customization</span><span class="token plain"></span><br></span><span class="token-line" style="color:#F8F8F2"><span class="token plain">tv files --preview-command </span><span class="token string" style="color:rgb(255, 121, 198)">&quot;bat -n --color=always &#x27;{}&#x27;&quot;</span><span class="token plain"></span><br></span><span class="token-line" style="color:#F8F8F2"><span class="token plain">tv git-log </span><span class="token parameter variable" style="color:rgb(189, 147, 249);font-style:italic">--layout</span><span class="token plain"> portrait</span><br></span><span class="token-line" style="color:#F8F8F2"><span class="token plain" style="display:inline-block"></span><br></span><span class="token-line" style="color:#F8F8F2"><span class="token plain"></span><span class="token comment" style="color:rgb(98, 114, 164)"># Feature visibility control</span><span class="token plain"></span><br></span><span class="token-line" style="color:#F8F8F2"><span class="token plain">tv files --hide-preview --show-status-bar </span><span class="token comment" style="color:rgb(98, 114, 164)"># Clean interface, status visible</span><span class="token plain"></span><br></span><span class="token-line" style="color:#F8F8F2"><span class="token plain">tv files --show-remote </span><span class="token comment" style="color:rgb(98, 114, 164)"># Force remote control visible</span><br></span></code></pre></div></div>
<h4 class="anchor anchorWithStickyNavbar_Fogf" id="ad-hoc-mode-custom-commands">Ad-hoc Mode (Custom Commands)<a href="#ad-hoc-mode-custom-commands" class="hash-link" aria-label="Direct link to Ad-hoc Mode (Custom Commands)" title="Direct link to Ad-hoc Mode (Custom Commands)"></a></h4>
<div class="language-bash codeBlockContainer_MbdR theme-code-block" style="--prism-color:#F8F8F2;--prism-background-color:#282A36"><div class="codeBlockContent_WPSJ"><pre tabindex="0" class="prism-code language-bash codeBlock_ke8T thin-scrollbar" style="color:#F8F8F2;background-color:#282A36"><code class="codeBlockLines_oe7S"><span class="token-line" style="color:#F8F8F2"><span class="token comment" style="color:rgb(98, 114, 164)"># Simple custom finder</span><span class="token plain"></span><br></span><span class="token-line" style="color:#F8F8F2"><span class="token plain">tv --source-command </span><span class="token string" style="color:rgb(255, 121, 198)">&quot;find . -name &#x27;*.md&#x27;&quot;</span><span class="token plain"></span><br></span><span class="token-line" style="color:#F8F8F2"><span class="token plain" style="display:inline-block"></span><br></span><span class="token-line" style="color:#F8F8F2"><span class="token plain"></span><span class="token comment" style="color:rgb(98, 114, 164)"># Live system monitoring with hidden UI elements</span><span class="token plain"></span><br></span><span class="token-line" style="color:#F8F8F2"><span class="token plain">tv --source-command </span><span class="token string" style="color:rgb(255, 121, 198)">&quot;ps aux | tail -n +2&quot;</span><span class="token plain"> </span><span class="token punctuation" style="color:rgb(248, 248, 242)">\</span><span class="token plain"></span><br></span><span class="token-line" style="color:#F8F8F2"><span class="token plain"> </span><span class="token parameter variable" style="color:rgb(189, 147, 249);font-style:italic">--watch</span><span class="token plain"> </span><span class="token number">1.0</span><span class="token plain"> </span><span class="token punctuation" style="color:rgb(248, 248, 242)">\</span><span class="token plain"></span><br></span><span class="token-line" style="color:#F8F8F2"><span class="token plain"> --hide-preview </span><span class="token punctuation" style="color:rgb(248, 248, 242)">\</span><span class="token plain"></span><br></span><span class="token-line" style="color:#F8F8F2"><span class="token plain"> --hide-status-bar</span><br></span><span class="token-line" style="color:#F8F8F2"><span class="token plain" style="display:inline-block"></span><br></span><span class="token-line" style="color:#F8F8F2"><span class="token plain"></span><span class="token comment" style="color:rgb(98, 114, 164)"># Clean interface with selective visibility</span><span class="token plain"></span><br></span><span class="token-line" style="color:#F8F8F2"><span class="token plain">tv --source-command </span><span class="token string" style="color:rgb(255, 121, 198)">&quot;docker ps -a&quot;</span><span class="token plain"> </span><span class="token punctuation" style="color:rgb(248, 248, 242)">\</span><span class="token plain"></span><br></span><span class="token-line" style="color:#F8F8F2"><span class="token plain"> --hide-preview </span><span class="token punctuation" style="color:rgb(248, 248, 242)">\</span><span class="token plain"></span><br></span><span class="token-line" style="color:#F8F8F2"><span class="token plain"> --show-status-bar</span><br></span></code></pre></div></div></div></article><nav class="docusaurus-mt-lg pagination-nav" aria-label="Docs pages"><a class="pagination-nav__link pagination-nav__link--prev" href="/television/docs/Users/themes"><div class="pagination-nav__sublabel">Previous</div><div class="pagination-nav__label">Themes</div></a><a class="pagination-nav__link pagination-nav__link--next" href="/television/docs/Users/community-channels-unix"><div class="pagination-nav__sublabel">Next</div><div class="pagination-nav__label">🍿 Community Channels (unix)</div></a></nav></div></div><div class="col col--3"><div class="tableOfContents_sLnf thin-scrollbar theme-doc-toc-desktop"><ul class="table-of-contents table-of-contents__left-border"><li><a href="#table-of-contents" class="table-of-contents__link toc-highlight">Table of Contents</a></li><li><a href="#overview" class="table-of-contents__link toc-highlight">Overview</a></li><li><a href="#operating-modes" class="table-of-contents__link toc-highlight">Operating Modes</a><ul><li><a href="#channel-mode" class="table-of-contents__link toc-highlight">Channel Mode</a></li><li><a href="#ad-hoc-mode" class="table-of-contents__link toc-highlight">Ad-hoc Mode</a></li></ul></li><li><a href="#basic-usage" class="table-of-contents__link toc-highlight">Basic Usage</a><ul><li><a href="#arguments" class="table-of-contents__link toc-highlight">Arguments</a></li></ul></li><li><a href="#options" class="table-of-contents__link toc-highlight">Options</a><ul><li><a href="#-source-and-data-options" class="table-of-contents__link toc-highlight">🎯 Source and Data Options</a></li><li><a href="#-preview-options" class="table-of-contents__link toc-highlight">👁️ Preview Options</a></li><li><a href="#-status-bar-options" class="table-of-contents__link toc-highlight"> Status Bar Options</a></li><li><a href="#-remote-control-options" class="table-of-contents__link toc-highlight">📡 Remote Control Options</a></li><li><a href="#-help-panel-options" class="table-of-contents__link toc-highlight">❓ Help Panel Options</a></li><li><a href="#-interface-and-layout-options" class="table-of-contents__link toc-highlight">🎨 Interface and Layout Options</a></li><li><a href="#-input-and-interaction-options" class="table-of-contents__link toc-highlight">⌨️ Input and Interaction Options</a></li><li><a href="#-selection-behavior-options" class="table-of-contents__link toc-highlight">⚡ Selection Behavior Options</a></li><li><a href="#-performance-and-monitoring-options" class="table-of-contents__link toc-highlight">⚙️ Performance and Monitoring Options</a></li><li><a href="#-directory-and-configuration-options" class="table-of-contents__link toc-highlight">📁 Directory and Configuration Options</a></li><li><a href="#-history-options" class="table-of-contents__link toc-highlight">📚 History Options</a></li><li><a href="#-special-mode-options" class="table-of-contents__link toc-highlight">🔧 Special Mode Options</a></li></ul></li><li><a href="#subcommands" class="table-of-contents__link toc-highlight">Subcommands</a><ul><li><a href="#list-channels" class="table-of-contents__link toc-highlight"><code>list-channels</code></a></li><li><a href="#init-shell" class="table-of-contents__link toc-highlight"><code>init &lt;SHELL&gt;</code></a></li><li><a href="#update-channels" class="table-of-contents__link toc-highlight"><code>update-channels</code></a></li></ul></li><li><a href="#usage-rules-and-restrictions" class="table-of-contents__link toc-highlight">Usage Rules and Restrictions</a><ul><li><a href="#-ad-hoc-mode-requirements" class="table-of-contents__link toc-highlight">🎯 Ad-hoc Mode Requirements</a></li><li><a href="#-mutually-exclusive-options" class="table-of-contents__link toc-highlight">🚫 Mutually Exclusive Options</a></li><li><a href="#-channel-mode-benefits" class="table-of-contents__link toc-highlight">✅ Channel Mode Benefits</a></li></ul></li><li><a href="#configuration" class="table-of-contents__link toc-highlight">Configuration</a><ul><li><a href="#-configuration-priority" class="table-of-contents__link toc-highlight">⚡ Configuration Priority</a></li><li><a href="#-configuration-locations" class="table-of-contents__link toc-highlight">📁 Configuration Locations</a></li><li><a href="#-feature-configuration" class="table-of-contents__link toc-highlight">🎛️ Feature Configuration</a></li></ul></li><li><a href="#template-system" class="table-of-contents__link toc-highlight">Template System</a><ul><li><a href="#template-enabled-flags" class="table-of-contents__link toc-highlight">Template-Enabled Flags</a></li><li><a href="#basic-template-syntax" class="table-of-contents__link toc-highlight">Basic Template Syntax</a></li><li><a href="#core-template-operations" class="table-of-contents__link toc-highlight">Core Template Operations</a></li><li><a href="#advanced-template-operations" class="table-of-contents__link toc-highlight">Advanced Template Operations</a></li><li><a href="#template-examples" class="table-of-contents__link toc-highlight">Template Examples</a></li><li><a href="#range-specifications" class="table-of-contents__link toc-highlight">Range Specifications</a></li></ul></li><li><a href="#examples" class="table-of-contents__link toc-highlight">Examples</a><ul><li><a href="#-quick-start-examples" class="table-of-contents__link toc-highlight">🎯 Quick Start Examples</a></li></ul></li></ul></div></div></div></div></main></div></div></div><footer class="theme-layout-footer footer"><div class="container container-fluid"><div class="footer__bottom text--center"><div class="footer__copyright">Copyright © 2025 alexpasmantier</div></div></div></footer></div>
</body>
</html>