Skip to content

grosser/organization_audit

Repository files navigation

Audit all repos of your organization or user

Install

gem install organization_audit

Usage

Token has to be passed or is fetched from git config github.token.

require 'organization_audit'

OrganizationAudit.all(user: "anamartinez").each do |repo|
  if !repo.private? && repo.gem? && repo.content("Gemfile").to_s.include?("rake")
    puts "#{repo.name} includes rake!"
  end
end

Commandline tool: fetch :user/:token/:organization/:ignore/:ignore_gems from ARGV

options = {}
OptionParser.new do |parser|
  parser.banner = "My shiny tool"
  OrganizationAudit.optparse(parser, options)
end.parse!

Options

  • :user
  • :organization
  • :token (see below)

Token

create a token that has access to your repositories

curl -v -u your-user-name -X POST https://api.github.com/authorizations --data '{"scopes":["repo"]}'
enter your password -> TOKEN

Related

Author

Michael Grosser
michael@grosser.it
License: MIT
Build Status

About

Audit all repos of your organization or user

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages