Skip to content

Instantly share code, notes, and snippets.

@mizzy
Last active December 11, 2015 21:49
Show Gist options
  • Select an option

  • Save mizzy/4665462 to your computer and use it in GitHub Desktop.

Select an option

Save mizzy/4665462 to your computer and use it in GitHub Desktop.
#!/usr/bin/env ruby
require 'octokit'
username = 'mizzy'
password = 'xxxxxxxx'
octokit = Octokit::Client.new(:login => username, :password => password)
octokit.orgs.each do |org|
org = org.login
next unless org.match(/^coderwall/)
unless octokit.organization_public_member?(org, username)
puts "Publicize membership of user #{username} in #{org} ..."
octokit.publicize_membership(org, username)
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment