robin-chit 0.0.5 → 0.0.6

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.
Files changed (2) hide show
  1. data/lib/chit.rb +6 -3
  2. metadata +1 -1
data/lib/chit.rb CHANGED
@@ -3,7 +3,7 @@ $:.unshift File.dirname(__FILE__)
3
3
 
4
4
  module Chit
5
5
  extend self
6
- VERSION = '0.0.5'
6
+ VERSION = '0.0.6'
7
7
 
8
8
  defaults = {
9
9
  'root' => File.join("#{ENV['HOME']}",".chit")
@@ -103,7 +103,7 @@ module Chit
103
103
  def search_title
104
104
  reg = Regexp.compile("^#{@sheet}")
105
105
  files = all_sheets.select {|sheet| sheet =~ reg }
106
- puts files.sort.join("\n")
106
+ puts " " + files.sort.join("\n ")
107
107
  true
108
108
  end
109
109
 
@@ -133,7 +133,10 @@ module Chit
133
133
  puts "Private chit initialized."
134
134
  else
135
135
  puts "Initialize private chit from scratch to #{CONFIG['root']}/private"
136
- Git.init(private_path)
136
+ git = Git.init(private_path)
137
+ FileUtils.touch(File.join(CONFIG['root'],'private','.gitignore'))
138
+ git.add
139
+ git.commit_all("init private repository")
137
140
  puts "Private chit initialized."
138
141
  end
139
142
  else
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: robin-chit
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.5
4
+ version: 0.0.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - Robin Lu