codelog 0.4.0 → 0.5.0
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 +5 -5
- data/CHANGELOG.md +6 -1
- data/lib/codelog/cli.rb +3 -1
- data/lib/codelog/command/new.rb +11 -3
- data/lib/codelog/version.rb +1 -1
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
|
-
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
2
|
+
SHA1:
|
3
|
+
metadata.gz: 0f1e5ce48ce1d8a919fc4c121090b8f5efdb908e
|
4
|
+
data.tar.gz: efb600d1427eb7b60773cd1c186035fd972dbf3d
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 86a05331db80325f448a3a09c59a8d43a15c9d83bed1d8026038ae26e901b3687738141fd419a6066a903f1e8fd4c09b9a1e526794375d1d493f74706343f543
|
7
|
+
data.tar.gz: fb3404f11c69905bb8e5639d8c9c80bef154ca01ddff8eeea0a768f0bf9886f9ff1575a6dd081aa4bd5ce233440b9ddb6ce39e3e954e6c21e39907aa3b1a986a
|
data/CHANGELOG.md
CHANGED
@@ -3,6 +3,11 @@ All notable changes to this project will be documented in this file.
|
|
3
3
|
The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/)
|
4
4
|
and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html).
|
5
5
|
|
6
|
+
## 0.5.0
|
7
|
+
### Added
|
8
|
+
- Ability to edit the created changefile by running `codelog new <-e|--edit>`
|
9
|
+
|
10
|
+
---
|
6
11
|
## 0.4.0
|
7
12
|
### Fixed
|
8
13
|
- Nested YML entries were print as hashes. Now codelog generates a nested Markdown
|
@@ -10,7 +15,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.
|
|
10
15
|
---
|
11
16
|
## 0.3.1
|
12
17
|
### Fixed
|
13
|
-
- Non-default input date
|
18
|
+
- Non-default input date format
|
14
19
|
|
15
20
|
---
|
16
21
|
## 0.3.0
|
data/lib/codelog/cli.rb
CHANGED
@@ -10,8 +10,10 @@ module Codelog
|
|
10
10
|
end
|
11
11
|
|
12
12
|
desc 'new', 'Generate a file from the template for the unreleased changes'
|
13
|
+
method_option :edit, desc: 'Opens the default system editor after creating a changefile',
|
14
|
+
aliases: '-e', type: :boolean
|
13
15
|
def new
|
14
|
-
Codelog::Command::New.run
|
16
|
+
Codelog::Command::New.run options
|
15
17
|
end
|
16
18
|
|
17
19
|
desc 'release [VERSION] <RELEASE_DATE>', 'Generate new release updating changelog'
|
data/lib/codelog/command/new.rb
CHANGED
@@ -5,11 +5,11 @@ module Codelog
|
|
5
5
|
class New
|
6
6
|
include FileUtils
|
7
7
|
|
8
|
-
def self.run
|
9
|
-
Codelog::Command::New.new.run
|
8
|
+
def self.run(options)
|
9
|
+
Codelog::Command::New.new.run options
|
10
10
|
end
|
11
11
|
|
12
|
-
def run
|
12
|
+
def run(options)
|
13
13
|
chdir Dir.pwd do
|
14
14
|
# This script create a change file for the changelog documentation.
|
15
15
|
|
@@ -17,11 +17,19 @@ module Codelog
|
|
17
17
|
|
18
18
|
puts "== Creating #{full_file_name} change file based on example =="
|
19
19
|
system! "cp changelogs/template.yml #{full_file_name}"
|
20
|
+
system! "#{default_editor} #{full_file_name}" if options[:edit]
|
20
21
|
end
|
21
22
|
end
|
22
23
|
|
23
24
|
private
|
24
25
|
|
26
|
+
def default_editor
|
27
|
+
# Looks for the default editor in VISUAL and EDITOR system variables
|
28
|
+
# if no variable is set it defaults to nano
|
29
|
+
|
30
|
+
'${VISUAL:-${EDITOR:-nano}}'
|
31
|
+
end
|
32
|
+
|
25
33
|
def system!(*args)
|
26
34
|
system(*args) || abort("\n== Command #{args} failed ==")
|
27
35
|
end
|
data/lib/codelog/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: codelog
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.5.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Luís Bevilacqua
|
@@ -12,7 +12,7 @@ authors:
|
|
12
12
|
autorequire:
|
13
13
|
bindir: bin
|
14
14
|
cert_chain: []
|
15
|
-
date: 2018-02-
|
15
|
+
date: 2018-02-16 00:00:00.000000000 Z
|
16
16
|
dependencies:
|
17
17
|
- !ruby/object:Gem::Dependency
|
18
18
|
name: thor
|
@@ -150,7 +150,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
150
150
|
version: '0'
|
151
151
|
requirements: []
|
152
152
|
rubyforge_project:
|
153
|
-
rubygems_version: 2.
|
153
|
+
rubygems_version: 2.6.8
|
154
154
|
signing_key:
|
155
155
|
specification_version: 4
|
156
156
|
summary: A gem to help with changelog management
|