turbot/github_sherlock
Loading controls...

Control: Branches should automatically be deleted after merging in each public repository

Description

Automatically delete branches after merging to maintain only your active branches.

Usage

Run the control in your terminal:

powerpipe control run github_sherlock.control.public_repo_delete_branch_on_merge_enabled

Snapshot and share results via Turbot Pipes:

powerpipe login
powerpipe control run github_sherlock.control.public_repo_delete_branch_on_merge_enabled --share

Steampipe Tables

SQL

select
url as resource,
case
when delete_branch_on_merge then 'ok'
else 'alarm'
end as status,
name_with_owner || ' delete branch on merge is ' || case
when(delete_branch_on_merge) :: bool then 'enabled'
else 'disabled'
end || '.' as reason,
name_with_owner
from
github_my_repository
where
visibility = 'PUBLIC'
and is_fork = false

Tags