lib/git/multi.rb in git-multi-1.0.7 vs lib/git/multi.rb in git-multi-1.0.8
- old
+ new
@@ -33,11 +33,11 @@
TOKEN = git_option('github.token', DEFAULT_TOKEN)
CACHE = File.join(HOME, '.git', 'multi')
REPOSITORIES = File.join(CACHE, 'repositories.byte')
- USER = git_option('github.user')
+ USERS = git_list('github.users')
ORGANIZATIONS = git_list('github.organizations')
MAN_PAGE = File.expand_path('../../man/git-multi.1', __dir__)
HTML_PAGE = File.expand_path('../../man/git-multi.html', __dir__)
@@ -55,21 +55,21 @@
repos[org] = Dir.new(WORKAREA).git_repos(org)
}
def local_repositories
(
- @local_user_repositories[USER] +
+ USERS.map { |user| @local_user_repositories[user] } +
ORGANIZATIONS.map { |org| @local_org_repositories[org] }
).flatten
end
#
# remote repositories (on GitHub)
#
def github_repositories
@github_repositories ||= (
- Git::Hub.user_repositories(USER) +
+ USERS.map { |user| Git::Hub.user_repositories(user) } +
ORGANIZATIONS.map { |org| Git::Hub.org_repositories(org) }
).flatten
end
def refresh_repositories