rbdo 1.1.1 → 1.1.2

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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 728838f4331018a66d4dc5650d59a5c4a807c7114677432018998548cc73a426
4
- data.tar.gz: dd2f6dedbf9fe654403942babad1f5519dc834dc6d3e63c7cbeec89b02abc3a1
3
+ metadata.gz: d5b18ae751462fb00ad41c3fc00a7340e167eb79a2e588325c3f6a2faf0465d1
4
+ data.tar.gz: 279bfd0b4c7c01cd5cad64909d6979e6691466bef0e0bf1b080f6f9dfb503371
5
5
  SHA512:
6
- metadata.gz: 47ecd90a2cb3c14ea4cbf5fe2d12b768228641dccc51632d803912185b16bb39b395cf5715333647af687c75c99154fa5279c4d7de0250bbd2fb19db5fb96e73
7
- data.tar.gz: e7378ea28ab3f644c29833dd51186810b56c5f85a50573d4f2241d7167626b482cf0c385a4ba725ffc78547d22a7cad7ca634fa806ac287677e628836c17b56d
6
+ metadata.gz: 3c7dbdd4a5e2d475d51558cba0210cafabbc6019759c9688333a334ed64ebe8d9fc967376e514b1c43ba11fbe70e81df525f4ad25b02134847b730b7be1c6c5a
7
+ data.tar.gz: 9ea4bf02b65d5e5f011490515bcc04032bfade33cd511facde436ef2b9835fa4600c39d3b62d7d42cee16eec435d779e0455bd80c4deedfb9e7752958976c8bf
data/README.md CHANGED
@@ -1,41 +1,43 @@
1
1
  # rbdo: a simple todo app in cli
2
2
 
3
+ [![Gem Version](https://badge.fury.io/rb/rbdo.svg)](https://rubygems.org/gems/rbdo)
4
+
3
5
  ## commands
4
6
 
5
7
  ### .add
6
8
 
7
- `./rbdo.rb add --text="netflix and chill" --date=28/01/2019 --time=18:03`
9
+ `rbdo add --text="netflix and chill" --date=28/01/2019 --time=18:03`
8
10
 
9
11
  ### .ls
10
12
 
11
- `./rbdo.rb ls` or `./rbdo.rb ls --date=28/01/2019`
13
+ `rbdo ls`
12
14
 
13
15
  ### .rm
14
16
 
15
- `./rbdo.rb rm --index=5`
17
+ `rbdo rm --index=5`
16
18
 
17
19
  ## arguments
18
20
 
19
21
  ### --text
20
22
 
21
- text/content of the todo entry.
23
+ content of the todo entry.
22
24
 
23
- `./rbdo.rb add --text="netflix and chill"`
25
+ `rbdo add --text="netflix and chill"`
24
26
 
25
27
  ### --date
26
28
 
27
29
  date of the todo entry. (year and month are optional)
28
30
 
29
- `./rbdo.rb ls --date=28/01/2019`
31
+ `rbdo add --date=28/01/2019 --text="netflix and chill"`
30
32
 
31
33
  ### --time
32
34
 
33
35
  time of the todo entry. (minute and second are optional)
34
36
 
35
- `./rbdo.rb add --text=todo --time=18:03:08`
37
+ `rbdo add --time=18:03:08 --text=todo`
36
38
 
37
39
  ### --index
38
40
 
39
41
  index of the todo entry required for the rm command.
40
42
 
41
- `./rbdo.rb rm --index=5`
43
+ `rbdo rm --index=5`
@@ -18,7 +18,7 @@
18
18
  # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
19
19
  # SOFTWARE.
20
20
 
21
- require 'tty-markdown'
21
+ require 'pastel'
22
22
  require_relative 'command'
23
23
 
24
24
  module RBDO
@@ -33,7 +33,41 @@ module RBDO
33
33
  def handle(argv)
34
34
  return false unless @command.handle(argv).instance_of?(Hash)
35
35
 
36
- puts TTY::Markdown.parse_file("#{__dir__}/../../../README.md")
36
+ pastel = Pastel.new
37
+ header = pastel.bright_yellow.bold.underline.detach
38
+ section = pastel.bright_cyan.bold.detach
39
+ command = pastel.black.on_white.detach
40
+
41
+ puts <<~HELP
42
+ #{header['commands']}
43
+
44
+ #{section['.add']}
45
+ #{command['rbdo add --text="blah" --date=28/01/2019']}
46
+
47
+ #{section['.ls']}
48
+ #{command['rbdo ls']}
49
+
50
+ #{section['.rm']}
51
+ #{command['rbdo rm --index=5']}
52
+
53
+ #{header['arguments']}
54
+
55
+ #{section['--text']}
56
+ content of the todo entry. example:
57
+ #{command['rbdo add --text="blah"']}
58
+
59
+ #{section['--date']}
60
+ date of the todo entry (year and month are optional). example:
61
+ #{command['rbdo add --date=28/01/2019 --text="blah"']}
62
+
63
+ #{section['--time']}
64
+ time of the todo entry (minute and second are optional). example:
65
+ #{command['rbdo add --time=18:03:08 --text="blah"']}
66
+
67
+ #{section['--time']}
68
+ index of the todo entry required for the rm command. example:
69
+ #{command['rbdo rm --index=5']}
70
+ HELP
37
71
  true
38
72
  end
39
73
  end
@@ -19,5 +19,5 @@
19
19
  # SOFTWARE.
20
20
 
21
21
  module RBDO
22
- VERSION = '1.1.1'.freeze
22
+ VERSION = '1.1.2'.freeze
23
23
  end
@@ -22,6 +22,6 @@ Gem::Specification.new do |spec|
22
22
  spec.require_paths = ['lib']
23
23
 
24
24
  spec.required_ruby_version = '>= 2.2'
25
- spec.add_runtime_dependency 'tty-markdown', '~> 0.4.0'
25
+ spec.add_runtime_dependency 'pastel', '~> 0.7.2'
26
26
  spec.add_development_dependency 'bundler', '~> 1.17'
27
27
  end
metadata CHANGED
@@ -1,29 +1,29 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rbdo
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.1.1
4
+ version: 1.1.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - personinblack
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2018-11-11 00:00:00.000000000 Z
11
+ date: 2018-11-13 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
- name: tty-markdown
14
+ name: pastel
15
15
  requirement: !ruby/object:Gem::Requirement
16
16
  requirements:
17
17
  - - "~>"
18
18
  - !ruby/object:Gem::Version
19
- version: 0.4.0
19
+ version: 0.7.2
20
20
  type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
24
  - - "~>"
25
25
  - !ruby/object:Gem::Version
26
- version: 0.4.0
26
+ version: 0.7.2
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: bundler
29
29
  requirement: !ruby/object:Gem::Requirement