katip 0.1.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 ADDED
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: b509ee7719357955f294253549faefd8fbecab36
4
+ data.tar.gz: 545696486d5e36617a756b23842fe527f12ac08c
5
+ SHA512:
6
+ metadata.gz: 1e2e0384b0f8db3b13d9a44c56f4ddf066e45057cc779832efcd76c65ed7da5e5b57ad6eb8c4936acd4686f6a3ee0156e4e537cfb36560e527b862c165f8d412
7
+ data.tar.gz: 6341ea1ecff7baab2a252b0040ef7ff6ec787fa5d7bb7952f48060947c95fe2ccd8f309959eecc502780a782d1fdb2dbfb547239e0e18a6f3fb74bd601dade58
data/CHANGELOG.md ADDED
@@ -0,0 +1,8 @@
1
+
2
+ #### [Current]
3
+
4
+ #### []
5
+ * [18fba8f](../../commit/18fba8f) #3 Add logger file __(Murat Kemal BAYGÜN)__
6
+ * [105af37](../../commit/105af37) Update readme __(Murat Kemal BAYGÜN)__
7
+ * [bc56515](../../commit/bc56515) Initial commit __(Murat Kemal BAYGÜN)__
8
+ * [1b1d477](../../commit/1b1d477) Initial commit __(Murat Kemal BAYGÜN)__
data/Gemfile ADDED
@@ -0,0 +1,4 @@
1
+ source 'https://rubygems.org'
2
+
3
+ # Specify your gem's dependencies in katip.gemspec
4
+ gemspec
data/Gemfile.lock ADDED
@@ -0,0 +1,17 @@
1
+ PATH
2
+ remote: .
3
+ specs:
4
+ katip (0.1.0)
5
+
6
+ GEM
7
+ remote: https://rubygems.org/
8
+ specs:
9
+ rake (10.1.0)
10
+
11
+ PLATFORMS
12
+ ruby
13
+
14
+ DEPENDENCIES
15
+ bundler (~> 1.3)
16
+ katip!
17
+ rake
data/README.md ADDED
@@ -0,0 +1,14 @@
1
+ Katip
2
+ =========
3
+
4
+ This is a Change Logging gem for a git initialized project.
5
+
6
+ Planned to design a rake which dumps the change log as a list grouped by version tags. Log rows will contain links to commits, commit note and contributer name.
7
+
8
+ #### Links to resources
9
+
10
+ * Disqussion http://stackoverflow.com/questions/7387612/git-changelog-how-to-get-all-changes-up-to-a-specific-tag
11
+ * Example bash https://github.com/kandanapp/kandan/blob/master/gen-changelog.sh
12
+ * Example output https://github.com/kandanapp/kandan/blob/master/CHANGELOG.md
13
+ * https://github.com/pcreux/pimpmychangelog this repo add support github issue and authors
14
+
data/Rakefile ADDED
@@ -0,0 +1 @@
1
+ require "bundler/gem_tasks"
data/katip.gemspec ADDED
@@ -0,0 +1,23 @@
1
+ # coding: utf-8
2
+ lib = File.expand_path('../lib', __FILE__)
3
+ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
4
+ require 'katip/version'
5
+
6
+ Gem::Specification.new do |spec|
7
+ spec.name = 'katip'
8
+ spec.version = Katip::VERSION
9
+ spec.authors = %w[lab2023]
10
+ spec.email = %w[info@lab2023.com]
11
+ spec.description = %q{This is a Change Logging gem for a git initialized project.}
12
+ spec.summary = %q{Planned to design a rake which dumps the change log as a list grouped by version tags. Log rows will contain links to commits, commit note and contributer name.}
13
+ spec.homepage = 'https://github.com/kebab-project/katip'
14
+ spec.license = 'MIT'
15
+
16
+ spec.files = `git ls-files`.split($/)
17
+ spec.require_paths = %w[lib]
18
+
19
+ spec.add_development_dependency 'bundler', '~> 1.3'
20
+ spec.add_development_dependency 'rake'
21
+
22
+ spec.extra_rdoc_files = %w[README.md CHANGELOG.md]
23
+ end
data/lib/katip.rb ADDED
@@ -0,0 +1,51 @@
1
+ require 'katip/version'
2
+
3
+ module Katip
4
+ require 'katip/railtie' if defined?(Rails)
5
+
6
+ @@daktilo = <<-SHELL
7
+ # Get tags as an array
8
+ TAGS_ARRAY=(`git for-each-ref --sort='*authordate' --format='%(tag)' refs/tags | grep -v '^$'`)
9
+
10
+ repo_url="../../commit/"
11
+
12
+ # Set User defined file if exist else use default
13
+ if [ -n "$1" ]; then
14
+ OUTPUT=$1
15
+ else
16
+ OUTPUT="CHANGELOG.md"
17
+ fi
18
+
19
+ # Calculate the tag count
20
+ SIZE=${#TAGS_ARRAY[@]}
21
+
22
+ echo "\n#### [Current]" > $OUTPUT
23
+
24
+ # Iterate reversly on tags
25
+ for (( i = SIZE - 1; i >= 0 ; i-- ));
26
+ do
27
+ CURR_TAG=${TAGS_ARRAY[$i]}
28
+ echo "" >> $OUTPUT
29
+ if [ $PREV_TAG ];then
30
+ echo "#### [$PREV_TAG]" >> $OUTPUT
31
+ fi
32
+ git log --pretty=format:" * [%h]($repo_url%h) %s __(%an)__" $CURR_TAG..$PREV_TAG | grep -v "Merge branch " >> $OUTPUT
33
+ PREV_TAG=$CURR_TAG
34
+ done
35
+
36
+ # Dump change log for first tag
37
+ FIRST=$(git tag -l | head -1)
38
+ echo "\n#### [$FIRST]" >> $OUTPUT
39
+
40
+ git log --pretty=format:" * [%h]($repo_url%h) %s __(%an)__" $FIRST | grep -v "Merge branch " >> $OUTPUT
41
+ SHELL
42
+
43
+ def self.set(param)
44
+ @@daktilo = param
45
+ end
46
+
47
+ def self.get
48
+ @@daktilo
49
+ end
50
+
51
+ end
@@ -0,0 +1,12 @@
1
+ require 'katip'
2
+ require 'rails'
3
+
4
+ module Katip
5
+ class Railtie < Rails::Railtie
6
+ railtie_name :katip
7
+
8
+ rake_tasks do
9
+ load "tasks/katip.rake"
10
+ end
11
+ end
12
+ end
@@ -0,0 +1,3 @@
1
+ module Katip
2
+ VERSION = '0.1.0'
3
+ end
@@ -0,0 +1,7 @@
1
+ namespace :katip do
2
+ desc 'Create CHANGELOG.md'
3
+ task :create => [:environment] do
4
+ puts 'Create CHANGELOG.md'
5
+ exec Katip.get
6
+ end
7
+ end
metadata ADDED
@@ -0,0 +1,86 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: katip
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.1.0
5
+ platform: ruby
6
+ authors:
7
+ - lab2023
8
+ autorequire:
9
+ bindir: bin
10
+ cert_chain: []
11
+ date: 2013-07-18 00:00:00.000000000 Z
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: bundler
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - ~>
18
+ - !ruby/object:Gem::Version
19
+ version: '1.3'
20
+ type: :development
21
+ prerelease: false
22
+ version_requirements: !ruby/object:Gem::Requirement
23
+ requirements:
24
+ - - ~>
25
+ - !ruby/object:Gem::Version
26
+ version: '1.3'
27
+ - !ruby/object:Gem::Dependency
28
+ name: rake
29
+ requirement: !ruby/object:Gem::Requirement
30
+ requirements:
31
+ - - '>='
32
+ - !ruby/object:Gem::Version
33
+ version: '0'
34
+ type: :development
35
+ prerelease: false
36
+ version_requirements: !ruby/object:Gem::Requirement
37
+ requirements:
38
+ - - '>='
39
+ - !ruby/object:Gem::Version
40
+ version: '0'
41
+ description: This is a Change Logging gem for a git initialized project.
42
+ email:
43
+ - info@lab2023.com
44
+ executables: []
45
+ extensions: []
46
+ extra_rdoc_files:
47
+ - README.md
48
+ - CHANGELOG.md
49
+ files:
50
+ - CHANGELOG.md
51
+ - Gemfile
52
+ - Gemfile.lock
53
+ - README.md
54
+ - Rakefile
55
+ - katip.gemspec
56
+ - lib/katip.rb
57
+ - lib/katip/railtie.rb
58
+ - lib/katip/version.rb
59
+ - lib/tasks/katip.rake
60
+ homepage: https://github.com/kebab-project/katip
61
+ licenses:
62
+ - MIT
63
+ metadata: {}
64
+ post_install_message:
65
+ rdoc_options: []
66
+ require_paths:
67
+ - lib
68
+ required_ruby_version: !ruby/object:Gem::Requirement
69
+ requirements:
70
+ - - '>='
71
+ - !ruby/object:Gem::Version
72
+ version: '0'
73
+ required_rubygems_version: !ruby/object:Gem::Requirement
74
+ requirements:
75
+ - - '>='
76
+ - !ruby/object:Gem::Version
77
+ version: '0'
78
+ requirements: []
79
+ rubyforge_project:
80
+ rubygems_version: 2.0.5
81
+ signing_key:
82
+ specification_version: 4
83
+ summary: Planned to design a rake which dumps the change log as a list grouped by
84
+ version tags. Log rows will contain links to commits, commit note and contributer
85
+ name.
86
+ test_files: []