mailcvt 0.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,6 @@
1
+ = mailcvt
2
+
3
+ Describe your project here
4
+
5
+ :include:mailcvt.rdoc
6
+
@@ -0,0 +1,83 @@
1
+ #!/usr/bin/env ruby
2
+ require 'gli'
3
+ begin # XXX: Remove this begin/rescue before distributing your app
4
+ require 'mailcvt'
5
+ rescue LoadError
6
+ STDERR.puts "In development, you need to use `bundle exec bin/mailcvt` to run your app"
7
+ STDERR.puts "At install-time, RubyGems will make sure lib, etc. are in the load path"
8
+ STDERR.puts "Feel free to remove this message from bin/mailcvt now"
9
+ exit 64
10
+ end
11
+
12
+ include GLI::App
13
+
14
+ program_desc 'Describe your application here'
15
+
16
+ version Mailcvt::VERSION
17
+
18
+ desc 'Describe some switch here'
19
+ switch [:s,:switch]
20
+
21
+ desc 'Describe some flag here'
22
+ default_value 'the default'
23
+ arg_name 'The name of the argument'
24
+ flag [:f,:flagname]
25
+
26
+ desc 'Describe write here'
27
+ arg_name 'Describe arguments to write here'
28
+ command :write do |c|
29
+ c.desc 'Describe a switch to write'
30
+ c.switch :s
31
+
32
+ c.desc 'Describe a flag to write'
33
+ c.default_value 'default'
34
+ c.flag :f
35
+ c.action do |global_options,options,args|
36
+
37
+ # Your command logic here
38
+
39
+ # If you have any errors, just raise them
40
+ # raise "that command made no sense"
41
+
42
+ puts "write command ran"
43
+ end
44
+ end
45
+
46
+ desc 'Describe read here'
47
+ arg_name 'Describe arguments to read here'
48
+ command :read do |c|
49
+ c.action do |global_options,options,args|
50
+ puts "read command ran"
51
+ end
52
+ end
53
+
54
+ desc 'Describe daemon here'
55
+ arg_name 'Describe arguments to daemon here'
56
+ command :daemon do |c|
57
+ c.action do |global_options,options,args|
58
+ puts "daemon command ran"
59
+ end
60
+ end
61
+
62
+ pre do |global,command,options,args|
63
+ # Pre logic here
64
+ # Return true to proceed; false to abort and not call the
65
+ # chosen command
66
+ # Use skips_pre before a command to skip this block
67
+ # on that command only
68
+ true
69
+ end
70
+
71
+ post do |global,command,options,args|
72
+ # Post logic here
73
+ # Use skips_post before a command to skip this
74
+ # block on that command only
75
+ end
76
+
77
+ on_error do |exception|
78
+ # Error logic here
79
+ # return false to skip default error handling
80
+ true
81
+ end
82
+
83
+ exit run(ARGV)
@@ -0,0 +1,4 @@
1
+ require 'mailcvt/version.rb'
2
+
3
+ # Add requires for other files you add to your project here, so
4
+ # you just need to require this one file in your bin file
@@ -0,0 +1,3 @@
1
+ module Mailcvt
2
+ VERSION = '0.0.1'
3
+ end
@@ -0,0 +1,5 @@
1
+ = mailcvt
2
+
3
+ Generate this with
4
+ mailcvt rdoc
5
+ After you have described your command line interface
metadata ADDED
@@ -0,0 +1,128 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: mailcvt
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.0.1
5
+ prerelease:
6
+ platform: ruby
7
+ authors:
8
+ - ryu-kahou
9
+ autorequire:
10
+ bindir: bin
11
+ cert_chain: []
12
+ date: 2013-07-11 00:00:00.000000000 Z
13
+ dependencies:
14
+ - !ruby/object:Gem::Dependency
15
+ name: rake
16
+ requirement: !ruby/object:Gem::Requirement
17
+ none: false
18
+ requirements:
19
+ - - ! '>='
20
+ - !ruby/object:Gem::Version
21
+ version: '0'
22
+ type: :development
23
+ prerelease: false
24
+ version_requirements: !ruby/object:Gem::Requirement
25
+ none: false
26
+ requirements:
27
+ - - ! '>='
28
+ - !ruby/object:Gem::Version
29
+ version: '0'
30
+ - !ruby/object:Gem::Dependency
31
+ name: rdoc
32
+ requirement: !ruby/object:Gem::Requirement
33
+ none: false
34
+ requirements:
35
+ - - ! '>='
36
+ - !ruby/object:Gem::Version
37
+ version: '0'
38
+ type: :development
39
+ prerelease: false
40
+ version_requirements: !ruby/object:Gem::Requirement
41
+ none: false
42
+ requirements:
43
+ - - ! '>='
44
+ - !ruby/object:Gem::Version
45
+ version: '0'
46
+ - !ruby/object:Gem::Dependency
47
+ name: aruba
48
+ requirement: !ruby/object:Gem::Requirement
49
+ none: false
50
+ requirements:
51
+ - - ! '>='
52
+ - !ruby/object:Gem::Version
53
+ version: '0'
54
+ type: :development
55
+ prerelease: false
56
+ version_requirements: !ruby/object:Gem::Requirement
57
+ none: false
58
+ requirements:
59
+ - - ! '>='
60
+ - !ruby/object:Gem::Version
61
+ version: '0'
62
+ - !ruby/object:Gem::Dependency
63
+ name: gli
64
+ requirement: !ruby/object:Gem::Requirement
65
+ none: false
66
+ requirements:
67
+ - - '='
68
+ - !ruby/object:Gem::Version
69
+ version: 2.7.0
70
+ type: :runtime
71
+ prerelease: false
72
+ version_requirements: !ruby/object:Gem::Requirement
73
+ none: false
74
+ requirements:
75
+ - - '='
76
+ - !ruby/object:Gem::Version
77
+ version: 2.7.0
78
+ description:
79
+ email: jiapeng.com@gmail.com
80
+ executables:
81
+ - mailcvt
82
+ extensions: []
83
+ extra_rdoc_files:
84
+ - README.rdoc
85
+ - mailcvt.rdoc
86
+ files:
87
+ - bin/mailcvt
88
+ - lib/mailcvt/version.rb
89
+ - lib/mailcvt.rb
90
+ - README.rdoc
91
+ - mailcvt.rdoc
92
+ homepage: http://github.com/ryu-kahou/mailcvt
93
+ licenses: []
94
+ post_install_message:
95
+ rdoc_options:
96
+ - --title
97
+ - mailcvt
98
+ - --main
99
+ - README.rdoc
100
+ - -ri
101
+ require_paths:
102
+ - lib
103
+ - lib
104
+ required_ruby_version: !ruby/object:Gem::Requirement
105
+ none: false
106
+ requirements:
107
+ - - ! '>='
108
+ - !ruby/object:Gem::Version
109
+ version: '0'
110
+ segments:
111
+ - 0
112
+ hash: -1803101067780984176
113
+ required_rubygems_version: !ruby/object:Gem::Requirement
114
+ none: false
115
+ requirements:
116
+ - - ! '>='
117
+ - !ruby/object:Gem::Version
118
+ version: '0'
119
+ segments:
120
+ - 0
121
+ hash: -1803101067780984176
122
+ requirements: []
123
+ rubyforge_project:
124
+ rubygems_version: 1.8.25
125
+ signing_key:
126
+ specification_version: 3
127
+ summary: Convert mail to a one line log message.
128
+ test_files: []