Sha256: 2adde5b5ae73640f1327877cb59f2e40a71143f5ab722e2f19638e3e70652303
Contents?: true
Size: 952 Bytes
Versions: 3
Compression:
Stored size: 952 Bytes
Contents
#!/usr/bin/env ruby require "bundler/inline" gemfile do source "https://rubygems.org" gem "multi_repo", require: "multi_repo/cli", path: File.expand_path("..", __dir__) end opts = Optimist.options do opt :org, "The organization to reenable workflows in", :type => :string, :required => true opt :extra_repos, "Extra repos to reenable workflows in", :type => :strings, :default => [] MultiRepo::CLI.common_options(self, :only => :dry_run) end github = MultiRepo::Service::Github.new(**opts.slice(:dry_run)) repos = (github.org_repo_names(opts[:org]) + opts[:extra_repos]).sort repos.each do |repo_name| puts MultiRepo::CLI.header(repo_name) disabled_workflows = github.disabled_workflows(repo_name) if disabled_workflows.any? disabled_workflows.each do |w| puts "** Enabling #{w.html_url} (#{w.id})" github.enable_workflow(repo_name, w.id) end else puts "** No disabled workflows found" end puts end
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
multi_repo-0.2.1 | scripts/reenable_repo_workflows |
multi_repo-0.2.0 | scripts/reenable_repo_workflows |
multi_repo-0.1.2 | scripts/reenable_repo_workflows |