josef 0.1.0 → 0.2.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 659488d85b4d808b98bd81d506672e6e66d5b615df9333107d2cffd445ae71f2
4
- data.tar.gz: d6b77ee7df6ac03d6fc2ec9061e90a034704b5d0336170ac195d244408eba788
3
+ metadata.gz: ff15bbffea6f50a5986d0e3b2d50af713366d66b846910ea053fc9bb633d0877
4
+ data.tar.gz: 742331144309a11d30d57862bf152e7528159aab49498d8896f1b1489226c290
5
5
  SHA512:
6
- metadata.gz: 78417ff9f122b2dbbb9191790b576837efd938d2768b45ba58c6d5f47f54599b4215c48088774214ed9d86b53f44fa46d1d5dce07fd4ddbf4ffe8fb5b3282ceb
7
- data.tar.gz: bb5b08e16a59084db95d132dc2fd21d3868eb0fcedd5e4b027cf3c80cb755aab4c51387400fda365a29b2fc66d67f88a575c51802c541c187c882e57aa4ded69
6
+ metadata.gz: aecb121ab5de22cd7812ac984ba2aaf174ddc97bdfd4b7aaac936abba36c9bcdefd400c6947759ffe32eb6826c272a361d16aa56215164cc6de0f53666fb9b1f
7
+ data.tar.gz: bfe23e5a8b06f0e47348024735e7c54cdd2f755e7684b6a946c7f4c8e880bedeffb4368d506537987e131b7ea6facb054e97c0f3cc0bfa35f4d282e271641fa8
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- josef (0.1.0)
4
+ josef (0.2.0)
5
5
  activesupport
6
6
  google-api-client
7
7
  thor
@@ -11,7 +11,17 @@ module Josef
11
11
 
12
12
  def groups!
13
13
  domains.map do | domain |
14
- client.list_groups(domain: domain).groups
14
+ res = client.list_groups(domain: domain)
15
+ domain_groups = res.groups
16
+ next_page_token = res.next_page_token
17
+
18
+ while next_page_token.nil?.!
19
+ res = client.list_groups(domain: domain, page_token: next_page_token)
20
+ next_page_token = res.next_page_token
21
+ domain_groups.concat(res.groups)
22
+ end
23
+
24
+ domain_groups
15
25
  end.flatten.compact
16
26
  end
17
27
 
@@ -8,7 +8,16 @@ module Josef
8
8
  end
9
9
 
10
10
  def members_by(group)
11
- client.list_members(group.id).members
11
+ res = client.list_members(group.id)
12
+ members = res.members
13
+ next_page_token = res.next_page_token
14
+ while next_page_token.nil?.!
15
+ res = client.list_members(group.id, page_token: next_page_token)
16
+ next_page_token = res.next_page_token
17
+ members.concat(res.members)
18
+ end
19
+
20
+ members
12
21
  end
13
22
 
14
23
  def add_member(group_mail_address, member_mail_address)
data/lib/josef/version.rb CHANGED
@@ -1,3 +1,3 @@
1
1
  module Josef
2
- VERSION = "0.1.0"
2
+ VERSION = "0.2.0"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: josef
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - jolantern
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2021-03-12 00:00:00.000000000 Z
11
+ date: 2021-03-15 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: google-api-client