MuranoCLI 3.2.1 → 3.2.2.beta.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Rakefile +7 -0
- data/lib/MrMurano/Business.rb +10 -0
- data/lib/MrMurano/Gateway.rb +1 -1
- data/lib/MrMurano/commands/business.rb +0 -25
- data/lib/MrMurano/commands/member.rb +103 -0
- data/lib/MrMurano/commands/solution_picker.rb +1 -1
- data/lib/MrMurano/commands.rb +1 -0
- data/lib/MrMurano/version.rb +1 -1
- metadata +5 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: f04979f9c6537564334a7b27e3bcbcb8170f2d03bbd8671ff2a4cd1ded574e2b
|
4
|
+
data.tar.gz: 1f64fcef2dc2f78af895963e13fd6aa33ddd142ec7f582625325985ad26fc3e7
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 9d0cf2a926767fcba117514e27845ec796be9bae47cd1472d1a9e3774b6664f1121e1415f719de97947d7e5885270c6fd57e53d0667005bed4d7360e723b670a
|
7
|
+
data.tar.gz: 875ef855f9f777409d055518eadae32d25fd1442cd47fe9fd3679e2e3f65d0a095a6047a8d0869f74bf2d91df3b40f0a1b48fc58dd111383b568cefe2a05bc8c
|
data/Rakefile
CHANGED
data/lib/MrMurano/Business.rb
CHANGED
@@ -156,6 +156,16 @@ The network child business ID is not specified. For help, run:
|
|
156
156
|
get("business/#{bid}/member/")
|
157
157
|
end
|
158
158
|
|
159
|
+
def invite_member(email)
|
160
|
+
put("business/#{bid}/member/#{email}")
|
161
|
+
end
|
162
|
+
|
163
|
+
def remove_member(email)
|
164
|
+
delete("business/#{bid}/member/#{email}")
|
165
|
+
end
|
166
|
+
|
167
|
+
# ---------------------------------------------------------------------
|
168
|
+
|
159
169
|
def fetch_network
|
160
170
|
whirly_msg("Fetching Business details (#{pretty_name_and_id}) / network...")
|
161
171
|
get("business/#{bid}/network")
|
data/lib/MrMurano/Gateway.rb
CHANGED
@@ -229,7 +229,7 @@ module MrMurano
|
|
229
229
|
@here << item.reject { |k, _v| %i[synckey synctype].include? k }
|
230
230
|
end
|
231
231
|
|
232
|
-
def diff_download(tmp_path, merged)
|
232
|
+
def diff_download(tmp_path, merged, _options)
|
233
233
|
@there = list if @there.nil?
|
234
234
|
items = @there.select { |item| item[:alias] == merged[:alias] }
|
235
235
|
if items.length > 1
|
@@ -265,31 +265,6 @@ command 'business show' do |c|
|
|
265
265
|
end
|
266
266
|
end
|
267
267
|
|
268
|
-
command 'business members' do |c|
|
269
|
-
c.syntax = %(murano business members)
|
270
|
-
# (lb): Use leading space so there's more than one space in --help
|
271
|
-
# after the command name.
|
272
|
-
c.summary = %( Show Business members)
|
273
|
-
c.description = %(
|
274
|
-
Show Business members.
|
275
|
-
).strip
|
276
|
-
c.project_not_required = true
|
277
|
-
|
278
|
-
c.action do |args, options|
|
279
|
-
c.verify_arg_count!(args)
|
280
|
-
|
281
|
-
biz = MrMurano::Business.new
|
282
|
-
biz.must_business_id!
|
283
|
-
|
284
|
-
MrMurano::Verbose.whirly_start 'Fetching business members...'
|
285
|
-
members = biz.fetch_member
|
286
|
-
MrMurano::Verbose.whirly_stop
|
287
|
-
|
288
|
-
acc = MrMurano::Account.new
|
289
|
-
cmd_business_output_members(acc, members, options)
|
290
|
-
end
|
291
|
-
end
|
292
|
-
|
293
268
|
command 'business set name' do |c|
|
294
269
|
c.syntax = %(murano business set name <name>)
|
295
270
|
# (lb): Use leading space so there's more than one space in --help
|
@@ -0,0 +1,103 @@
|
|
1
|
+
# Copyright © 2016-2017 Exosite LLC. All Rights Reserved
|
2
|
+
# License: PROPRIETARY. See LICENSE.txt.
|
3
|
+
# frozen_string_literal: true
|
4
|
+
|
5
|
+
# vim:tw=0:ts=2:sw=2:et:ai
|
6
|
+
# Unauthorized copying of this file is strictly prohibited.
|
7
|
+
|
8
|
+
require 'MrMurano/verbosing'
|
9
|
+
require 'MrMurano/Business'
|
10
|
+
|
11
|
+
command :member do |cmd|
|
12
|
+
cmd.syntax = %(murano member)
|
13
|
+
cmd.summary = %(About member)
|
14
|
+
cmd.description = %(Commands for working with business user members.)
|
15
|
+
cmd.project_not_required = true
|
16
|
+
cmd.subcmdgrouphelp = true
|
17
|
+
cmd.action do |_args, _options|
|
18
|
+
::Commander::UI.enable_paging unless $cfg['tool.no-page']
|
19
|
+
say MrMurano::SubCmdGroupHelp.new(cmd).get_help
|
20
|
+
end
|
21
|
+
end
|
22
|
+
|
23
|
+
command 'member list' do |c|
|
24
|
+
c.syntax = %(murano member list)
|
25
|
+
# (lb): Use leading space so there's more than one space in --help
|
26
|
+
# after the command name.
|
27
|
+
c.summary = %( Show Business members)
|
28
|
+
c.description = %(
|
29
|
+
Show Business members.
|
30
|
+
).strip
|
31
|
+
c.project_not_required = true
|
32
|
+
|
33
|
+
c.action do |args, options|
|
34
|
+
c.verify_arg_count!(args)
|
35
|
+
|
36
|
+
biz = MrMurano::Business.new
|
37
|
+
biz.must_business_id!
|
38
|
+
|
39
|
+
MrMurano::Verbose.whirly_start 'Fetching business members...'
|
40
|
+
members = biz.fetch_member
|
41
|
+
MrMurano::Verbose.whirly_stop
|
42
|
+
|
43
|
+
acc = MrMurano::Account.new
|
44
|
+
cmd_business_output_members(acc, members, options)
|
45
|
+
end
|
46
|
+
end
|
47
|
+
alias_command 'business members', 'member list'
|
48
|
+
alias_command 'members list', 'member list'
|
49
|
+
|
50
|
+
command 'member add' do |c|
|
51
|
+
c.syntax = %(murano member add)
|
52
|
+
# (lb): Use leading space so there's more than one space in --help
|
53
|
+
# after the command name.
|
54
|
+
c.summary = %( Invite new member to Business)
|
55
|
+
# MAYBE: (lb): Is there a business need for a bulk-invite command?
|
56
|
+
# E.g., `murano member add email1@tld.com email2@tld.com ...`
|
57
|
+
c.description = %(
|
58
|
+
Invite new member to Business.
|
59
|
+
).strip
|
60
|
+
c.project_not_required = true
|
61
|
+
|
62
|
+
c.action do |args, _options|
|
63
|
+
c.verify_arg_count!(args, 1, ['Missing <member email>'])
|
64
|
+
invitee_email = args[0]
|
65
|
+
|
66
|
+
biz = MrMurano::Business.new
|
67
|
+
biz.must_business_id!
|
68
|
+
|
69
|
+
MrMurano::Verbose.whirly_start 'Adding business member...'
|
70
|
+
response = biz.invite_member(invitee_email)
|
71
|
+
MrMurano::Verbose.whirly_stop
|
72
|
+
exit 1 if response.nil?
|
73
|
+
end
|
74
|
+
end
|
75
|
+
alias_command 'business member add', 'member add'
|
76
|
+
|
77
|
+
command 'member remove' do |c|
|
78
|
+
c.syntax = %(murano member remove)
|
79
|
+
# (lb): Use leading space so there's more than one space in --help
|
80
|
+
# after the command name.
|
81
|
+
c.summary = %( Remove member from Business)
|
82
|
+
# MAYBE: (lb): Is there a business need for a bulk-remove command?
|
83
|
+
# E.g., `murano member remove email1@tld.com email2@tld.com ...`
|
84
|
+
c.description = %(
|
85
|
+
Remove member from Business.
|
86
|
+
).strip
|
87
|
+
c.project_not_required = true
|
88
|
+
|
89
|
+
c.action do |args, _options|
|
90
|
+
c.verify_arg_count!(args, 1, ['Missing <member email>'])
|
91
|
+
member_email = args[0]
|
92
|
+
|
93
|
+
biz = MrMurano::Business.new
|
94
|
+
biz.must_business_id!
|
95
|
+
|
96
|
+
MrMurano::Verbose.whirly_start 'Removing business member...'
|
97
|
+
response = biz.remove_member(member_email)
|
98
|
+
MrMurano::Verbose.whirly_stop
|
99
|
+
exit 1 if response.nil?
|
100
|
+
end
|
101
|
+
end
|
102
|
+
alias_command 'business member remove', 'member remove'
|
103
|
+
|
@@ -530,7 +530,7 @@ module MrMurano
|
|
530
530
|
menu.flow = :columns_across
|
531
531
|
# NOTE: There are 2 human friendly identifiers, :name and :domain.
|
532
532
|
solz.sort_by(&:domain).each do |option|
|
533
|
-
menu.choice(option.
|
533
|
+
menu.choice(option.name) do
|
534
534
|
sol = option
|
535
535
|
end
|
536
536
|
end
|
data/lib/MrMurano/commands.rb
CHANGED
@@ -26,6 +26,7 @@ require 'MrMurano/commands/init'
|
|
26
26
|
require 'MrMurano/commands/link'
|
27
27
|
require 'MrMurano/commands/login'
|
28
28
|
require 'MrMurano/commands/logs'
|
29
|
+
require 'MrMurano/commands/member'
|
29
30
|
require 'MrMurano/commands/mock'
|
30
31
|
require 'MrMurano/commands/network'
|
31
32
|
require 'MrMurano/commands/postgresql'
|
data/lib/MrMurano/version.rb
CHANGED
@@ -26,7 +26,7 @@ module MrMurano
|
|
26
26
|
# '3.0.0-beta.2' is changed to '3.0.0.pre.beta.2'
|
27
27
|
# which breaks our build (which expects the version to match herein).
|
28
28
|
# So stick to using the '.pre.X' syntax, which ruby/gems knows.
|
29
|
-
VERSION = '3.2.1'
|
29
|
+
VERSION = '3.2.2.beta.1'
|
30
30
|
EXE_NAME = File.basename($PROGRAM_NAME)
|
31
31
|
SIGN_UP_URL = 'https://exosite.com/signup/'
|
32
32
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: MuranoCLI
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 3.2.1
|
4
|
+
version: 3.2.2.beta.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Michael Conrad Tadpol Tilstra
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2018-08-
|
11
|
+
date: 2018-08-24 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: certified
|
@@ -530,6 +530,7 @@ files:
|
|
530
530
|
- lib/MrMurano/commands/link.rb
|
531
531
|
- lib/MrMurano/commands/login.rb
|
532
532
|
- lib/MrMurano/commands/logs.rb
|
533
|
+
- lib/MrMurano/commands/member.rb
|
533
534
|
- lib/MrMurano/commands/mock.rb
|
534
535
|
- lib/MrMurano/commands/network.rb
|
535
536
|
- lib/MrMurano/commands/password.rb
|
@@ -576,9 +577,9 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
576
577
|
version: '2.0'
|
577
578
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
578
579
|
requirements:
|
579
|
-
- - "
|
580
|
+
- - ">"
|
580
581
|
- !ruby/object:Gem::Version
|
581
|
-
version:
|
582
|
+
version: 1.3.1
|
582
583
|
requirements: []
|
583
584
|
rubyforge_project:
|
584
585
|
rubygems_version: 2.7.6
|