Skip to content

Enabled Repos #23

@geoffreywiseman

Description

@geoffreywiseman

There's a setting to indicate if GitHub Actions is enabled on all, selected, or none workflows. The bash extension used this to help indicate which repos to target:

    enabled_repos=$(gh api "/orgs/$org_name/actions/permissions" --jq ".enabled_repositories")
    case "$enabled_repos" in
        all)
        echo "- GitHub Actions enabled on All Repos"
        print_org_repos "$org_name" "All Repos" "repos"
        ;;
        selected)
        echo "- GitHub Actions enabled on Selected Repos"
        print_org_repos "$org_name" "Selected Repos" "actions/permissions/repositories"
        ;;
        none)
        echo "- GitHub Actions is not enabled on any repositories"
        ;;
        *)
        echo "- GitHub Actions is enabled on $enabled_repos?"
    esac
}

Might as well reproduce that logic somewhat, although again may be necessary to consider the code structure since we're mapping from orgs to repos before processing.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions