Class: Imap::Backup::CLI
- Inherits:
-
Thor
- Object
- Thor
- Imap::Backup::CLI
show all
- Includes:
- Helpers
- Defined in:
- lib/imap/backup/cli.rb
Defined Under Namespace
Modules: Helpers
Classes: Backup, Folders, Local, Restore, Setup, Status
Class Method Summary
collapse
Instance Method Summary
collapse
Methods included from Helpers
#each_connection, #symbolized
Class Method Details
.accounts_option ⇒ Object
25
26
27
28
29
30
31
32
|
# File 'lib/imap/backup/cli.rb', line 25
def self.accounts_option
method_option(
"accounts",
type: :string,
banner: "a comma-separated list of accounts (defaults to all configured accounts)",
aliases: ["-a"]
)
end
|
.exit_on_failure? ⇒ Boolean
21
22
23
|
# File 'lib/imap/backup/cli.rb', line 21
def self.exit_on_failure?
true
end
|
Instance Method Details
#backup ⇒ Object
43
44
45
|
# File 'lib/imap/backup/cli.rb', line 43
def backup
Backup.new(symbolized(options)).run
end
|
#folders ⇒ Object
55
56
57
|
# File 'lib/imap/backup/cli.rb', line 55
def folders
Folders.new(symbolized(options)).run
end
|
#restore ⇒ Object
66
67
68
|
# File 'lib/imap/backup/cli.rb', line 66
def restore
Restore.new(symbolized(options)).run
end
|
#setup ⇒ Object
75
76
77
|
# File 'lib/imap/backup/cli.rb', line 75
def setup
Setup.new().run
end
|
#status ⇒ Object
84
85
86
|
# File 'lib/imap/backup/cli.rb', line 84
def status
Status.new(symbolized(options)).run
end
|