mirror of
https://github.com/alexpasmantier/television.git
synced 2025-07-29 06:11:37 +00:00
1 line
4.0 KiB
JavaScript
1 line
4.0 KiB
JavaScript
"use strict";(self.webpackChunktelevision_website=self.webpackChunktelevision_website||[]).push([[6409],{284:(e,n,t)=>{t.d(n,{A:()=>s});const s=t.p+"assets/images/tv-ansi-git-log-f8bdd17d72bd5108fe53fdae7360cfc7.png"},4871:(e,n,t)=>{t.r(n),t.d(n,{assets:()=>a,contentTitle:()=>l,default:()=>h,frontMatter:()=>o,metadata:()=>s,toc:()=>c});const s=JSON.parse('{"id":"Users/contributing-channels","title":"Contributing new channels","description":"*NOTE: for general setup information before contributing, see Contributing.*","source":"@site/../docs/01-Users/13-contributing-channels.md","sourceDirName":"01-Users","slug":"/Users/contributing-channels","permalink":"/television/docs/Users/contributing-channels","draft":false,"unlisted":false,"tags":[],"version":"current","sidebarPosition":13,"frontMatter":{},"sidebar":"docSidebar","previous":{"title":"Showcase","permalink":"/television/docs/Users/showcase"},"next":{"title":"Contributing","permalink":"/television/docs/Developers/contributing"}}');var i=t(3420),r=t(5404);const o={},l="Contributing new channels",a={},c=[{value:"Examples",id:"examples",level:3},{value:"git-log",id:"git-log",level:4}];function d(e){const n={a:"a",code:"code",em:"em",h1:"h1",h3:"h3",h4:"h4",header:"header",img:"img",li:"li",ol:"ol",p:"p",pre:"pre",strong:"strong",...(0,r.R)(),...e.components};return(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)(n.header,{children:(0,i.jsx)(n.h1,{id:"contributing-new-channels",children:"Contributing new channels"})}),"\n",(0,i.jsx)(n.p,{children:(0,i.jsxs)(n.em,{children:[(0,i.jsx)(n.strong,{children:"NOTE"}),": for general setup information before contributing, see ",(0,i.jsx)(n.a,{href:"/television/docs/Developers/contributing",children:"Contributing"}),"."]})}),"\n",(0,i.jsx)(n.p,{children:"Contributing a new channel is as you might expect, pretty straightforward."}),"\n",(0,i.jsxs)(n.ol,{children:["\n",(0,i.jsxs)(n.li,{children:["Create a new branch, add and commit your new channel's TOML file under ",(0,i.jsx)(n.code,{children:"cable/unix"})," (or ",(0,i.jsx)(n.code,{children:"cable/windows"})," depending on your usecase)."]}),"\n",(0,i.jsxs)(n.li,{children:["[OPTIONAL] Add a screenshot of the channel in ",(0,i.jsx)(n.code,{children:"assets/channels/<os>/"})," (e.g. ",(0,i.jsx)(n.code,{children:"assets/channels/unix/my_channel.png"}),")."]}),"\n",(0,i.jsx)(n.li,{children:"Push your commit and create a PR."}),"\n",(0,i.jsx)(n.li,{children:"The ci should automatically generate the documentation for your channel and pick up the screenshot if available."}),"\n",(0,i.jsxs)(n.li,{children:["If 4. fails, you can generate the docs manually by running:","\n",(0,i.jsx)(n.pre,{children:(0,i.jsx)(n.code,{className:"language-sh",children:"just generate-cable-docs\n"})}),"\n"]}),"\n"]}),"\n",(0,i.jsx)(n.h3,{id:"examples",children:"Examples"}),"\n",(0,i.jsx)(n.h4,{id:"git-log",children:"git-log"}),"\n",(0,i.jsx)(n.pre,{children:(0,i.jsx)(n.code,{className:"language-toml",children:'[metadata]\nname = "git-log"\ndescription = "A channel to select from git log entries"\nrequirements = ["git", "delta"]\n\n[source]\ncommand = "git log --graph --pretty=format:\'%C(yellow)%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset\' --abbrev-commit --color=always"\noutput = "{strip_ansi|split: :1}"\nansi = true\n\n[preview]\ncommand = "git show -p --stat --pretty=fuller --color=always \'{strip_ansi|split: :1}\' | delta"\n'})}),"\n",(0,i.jsx)(n.p,{children:(0,i.jsx)(n.img,{alt:"tv-ansi-git-log.png",src:t(284).A+"",width:"2880",height:"1620"})})]})}function h(e={}){const{wrapper:n}={...(0,r.R)(),...e.components};return n?(0,i.jsx)(n,{...e,children:(0,i.jsx)(d,{...e})}):d(e)}},5404:(e,n,t)=>{t.d(n,{R:()=>o,x:()=>l});var s=t(6672);const i={},r=s.createContext(i);function o(e){const n=s.useContext(r);return s.useMemo((function(){return"function"==typeof e?e(n):{...n,...e}}),[n,e])}function l(e){let n;return n=e.disableParentContext?"function"==typeof e.components?e.components(i):e.components||i:o(e.components),s.createElement(r.Provider,{value:n},e.children)}}}]); |