standup_md 0.2.1 → 0.3.4
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 +4 -4
- data/.gitignore +1 -0
- data/Gemfile.lock +8 -2
- data/README.md +149 -117
- data/bin/standup +1 -1
- data/doc/README_md.html +141 -96
- data/doc/StandupMD.html +96 -1326
- data/doc/StandupMD/Cli.html +124 -479
- data/doc/StandupMD/Cli/Helpers.html +167 -0
- data/doc/StandupMD/Config.html +230 -0
- data/doc/StandupMD/Config/Cli.html +364 -0
- data/doc/StandupMD/Config/Entry.html +296 -0
- data/doc/StandupMD/Config/EntryList.html +212 -0
- data/doc/StandupMD/Config/File.html +613 -0
- data/doc/StandupMD/Entry.html +478 -0
- data/doc/StandupMD/EntryList.html +759 -0
- data/doc/StandupMD/File.html +614 -0
- data/doc/created.rid +15 -5
- data/doc/index.html +151 -94
- data/doc/js/search_index.js +1 -1
- data/doc/js/search_index.js.gz +0 -0
- data/doc/table_of_contents.html +226 -72
- data/lib/standup_md.rb +28 -545
- data/lib/standup_md/cli.rb +63 -246
- data/lib/standup_md/cli/helpers.rb +167 -0
- data/lib/standup_md/config.rb +47 -0
- data/lib/standup_md/config/cli.rb +109 -0
- data/lib/standup_md/config/entry.rb +68 -0
- data/lib/standup_md/config/entry_list.rb +31 -0
- data/lib/standup_md/config/file.rb +209 -0
- data/lib/standup_md/entry.rb +122 -0
- data/lib/standup_md/entry_list.rb +166 -0
- data/lib/standup_md/file.rb +183 -0
- data/lib/standup_md/file/helpers.rb +62 -0
- data/lib/standup_md/version.rb +5 -5
- data/standup_md.gemspec +1 -0
- metadata +35 -2
@@ -0,0 +1,62 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
module StandupMD
|
4
|
+
class File
|
5
|
+
|
6
|
+
##
|
7
|
+
# Module responsible for reading and writing standup files.
|
8
|
+
module Helpers # :nodoc:
|
9
|
+
|
10
|
+
private
|
11
|
+
|
12
|
+
def is_header?(line) # :nodoc:
|
13
|
+
line.match(header_regex)
|
14
|
+
end
|
15
|
+
|
16
|
+
def is_sub_header?(line) # :nodoc:
|
17
|
+
line.match(sub_header_regex)
|
18
|
+
end
|
19
|
+
|
20
|
+
def header_regex # :nodoc:
|
21
|
+
%r{^#{'#' * StandupMD.config.file.header_depth}\s+}
|
22
|
+
end
|
23
|
+
|
24
|
+
def sub_header_regex # :nodoc:
|
25
|
+
%r{^#{'#' * StandupMD.config.file.sub_header_depth}\s+}
|
26
|
+
end
|
27
|
+
|
28
|
+
def bullet_character_regex # :nodoc:
|
29
|
+
%r{\s*#{StandupMD.config.file.bullet_character}\s*}
|
30
|
+
end
|
31
|
+
|
32
|
+
def determine_section_type(line) # :nodoc:
|
33
|
+
line = line.sub(%r{^\#{#{StandupMD.config.file.sub_header_depth}}\s*}, '')
|
34
|
+
[
|
35
|
+
StandupMD.config.file.current_header,
|
36
|
+
StandupMD.config.file.previous_header,
|
37
|
+
StandupMD.config.file.impediments_header,
|
38
|
+
StandupMD.config.file.notes_header
|
39
|
+
].each { |header| return header if line.include?(header) }
|
40
|
+
raise "Unrecognized header [#{line}]"
|
41
|
+
end
|
42
|
+
|
43
|
+
def new_entry(record) # :nodoc:
|
44
|
+
Entry.new(
|
45
|
+
Date.strptime(record['header'], StandupMD.config.file.header_date_format),
|
46
|
+
record[StandupMD.config.file.current_header],
|
47
|
+
record[StandupMD.config.file.previous_header],
|
48
|
+
record[StandupMD.config.file.impediments_header],
|
49
|
+
record[StandupMD.config.file.notes_header]
|
50
|
+
)
|
51
|
+
end
|
52
|
+
|
53
|
+
def header(date)
|
54
|
+
'#' * StandupMD.config.file.header_depth + ' ' + date.strftime(StandupMD.config.file.header_date_format)
|
55
|
+
end
|
56
|
+
|
57
|
+
def sub_header(sh)
|
58
|
+
'#' * StandupMD.config.file.sub_header_depth + ' ' + sh
|
59
|
+
end
|
60
|
+
end
|
61
|
+
end
|
62
|
+
end
|
data/lib/standup_md/version.rb
CHANGED
data/standup_md.gemspec
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: standup_md
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.3.4
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Evan Gray
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2020-
|
11
|
+
date: 2020-06-17 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rake
|
@@ -50,6 +50,20 @@ dependencies:
|
|
50
50
|
- - ">="
|
51
51
|
- !ruby/object:Gem::Version
|
52
52
|
version: 3.3.5
|
53
|
+
- !ruby/object:Gem::Dependency
|
54
|
+
name: simplecov
|
55
|
+
requirement: !ruby/object:Gem::Requirement
|
56
|
+
requirements:
|
57
|
+
- - ">="
|
58
|
+
- !ruby/object:Gem::Version
|
59
|
+
version: '0'
|
60
|
+
type: :development
|
61
|
+
prerelease: false
|
62
|
+
version_requirements: !ruby/object:Gem::Requirement
|
63
|
+
requirements:
|
64
|
+
- - ">="
|
65
|
+
- !ruby/object:Gem::Version
|
66
|
+
version: '0'
|
53
67
|
description: Generate and edit standups in markdown format
|
54
68
|
email: evanthegrayt@vivaldi.net
|
55
69
|
executables:
|
@@ -69,6 +83,15 @@ files:
|
|
69
83
|
- doc/README_md.html
|
70
84
|
- doc/StandupMD.html
|
71
85
|
- doc/StandupMD/Cli.html
|
86
|
+
- doc/StandupMD/Cli/Helpers.html
|
87
|
+
- doc/StandupMD/Config.html
|
88
|
+
- doc/StandupMD/Config/Cli.html
|
89
|
+
- doc/StandupMD/Config/Entry.html
|
90
|
+
- doc/StandupMD/Config/EntryList.html
|
91
|
+
- doc/StandupMD/Config/File.html
|
92
|
+
- doc/StandupMD/Entry.html
|
93
|
+
- doc/StandupMD/EntryList.html
|
94
|
+
- doc/StandupMD/File.html
|
72
95
|
- doc/created.rid
|
73
96
|
- doc/css/fonts.css
|
74
97
|
- doc/css/rdoc.css
|
@@ -115,6 +138,16 @@ files:
|
|
115
138
|
- doc/table_of_contents.html
|
116
139
|
- lib/standup_md.rb
|
117
140
|
- lib/standup_md/cli.rb
|
141
|
+
- lib/standup_md/cli/helpers.rb
|
142
|
+
- lib/standup_md/config.rb
|
143
|
+
- lib/standup_md/config/cli.rb
|
144
|
+
- lib/standup_md/config/entry.rb
|
145
|
+
- lib/standup_md/config/entry_list.rb
|
146
|
+
- lib/standup_md/config/file.rb
|
147
|
+
- lib/standup_md/entry.rb
|
148
|
+
- lib/standup_md/entry_list.rb
|
149
|
+
- lib/standup_md/file.rb
|
150
|
+
- lib/standup_md/file/helpers.rb
|
118
151
|
- lib/standup_md/version.rb
|
119
152
|
- standup_md.gemspec
|
120
153
|
homepage: https://evanthegrayt.github.io/standup_md/
|