main
1# gh-news configuration
2# See https://github.com/chmouel/gh-news for all options
3
4auto_refresh_interval = 240
5api_timeout = 30
6pagination_size = 50
7show_read = false
8participating_only = false
9default_preview_mode = "vertical"
10repos_collapsed = false
11auto_mark_read = false
12org_grouping = "auto"
13list_layout = "two_line"
14
15# Exclusion filters
16exclude_types = ["CheckSuite"]
17exclude_repos = ["openshift-pipelines/operator"]
18
19# Desktop notifications via notify-send
20on_new_notification_command = "notify-send --app-name=gh-news --icon=github --urgency=normal --expire-time=5000 'GitHub: $GH_NEWS_REPO' '$GH_NEWS_TITLE'"
21
22# Custom actions
23[[actions]]
24name = "Open in lazypr"
25command = "lazypr {url}"
26interactive = true
27
28[[actions]]
29name = "Copy URL"
30command = "echo -n {url} | wl-copy"
31interactive = false
32
33[[actions]]
34name = "Open lazyworktree"
35command = "cd $(repo-find {full_name}) && lazyworktree"
36interactive = true
37
38[[actions]]
39name = "Create worktree from PR"
40command = "cd $(repo-find {full_name}) && lazyworktree create --from-pr $(echo {url} | grep -oE 'pull/[0-9]+' | grep -oE '[0-9]+')"
41interactive = true
42
43[[actions]]
44name = "Send /lgtm"
45command = "gh pr comment {number} --repo {owner}/{repo} --body '/lgtm'"
46
47[[actions]]
48name = "Approve + /lgtm"
49command = "gh pr review {number} --repo {owner}/{repo} --approve --body '/lgtm'"
50
51[[actions]]
52name = "Rerun failed checks"
53command = "run_id=$(gh run list --repo {owner}/{repo} --branch $(gh pr view {number} --repo {owner}/{repo} --json headRefName -q .headRefName) --status failure --limit 1 --json databaseId -q '.[0].databaseId') && [ -n \"$run_id\" ] && gh run rerun $run_id --repo {owner}/{repo} --failed && echo 'Reran failed checks' || echo 'No failed runs to rerun'"
54
55[[actions]]
56name = "Approve workflow run (first-time contributor)"
57command = "run_id=$(gh run list --repo {owner}/{repo} --branch $(gh pr view {number} --repo {owner}/{repo} --json headRefName -q .headRefName) --status action_required --limit 1 --json databaseId -q '.[0].databaseId') && [ -n \"$run_id\" ] && gh api --method POST repos/{owner}/{repo}/actions/runs/$run_id/approve && echo 'Workflow run approved' || echo 'No pending approval found'"
58
59[[actions]]
60name = "Send /ok-to-test"
61command = "gh pr comment {number} --repo {owner}/{repo} --body '/ok-to-test'"
62
63[[actions]]
64name = "Show PR diff"
65command = "gh pr diff {number} -R {full_name}"
66show_output = true
67
68[[actions]]
69name = "Review with Pi"
70priority = 1
71command = "cd $(repo-find {full_name}) && if [ {type} = 'PR' ]; then pir '/review {url}'; else pir 'Analyze and summarize this GitHub issue: {url}'; fi"
72interactive = true
73
74# Named views (custom filter presets, press V to switch)
75[[views]]
76name = "Tekton"
77filter = "tektoncd/|openshift-pipelines/"
78
79[[views]]
80name = "Pipelines as Code"
81filter = "pipelines-as-code|pac-"
82
83[[views]]
84name = "Personal"
85filter = "vdemeester/"
86
87[[views]]
88name = "NixOS"
89filter = "NixOS/|nix-community/"