hiki2yard 0.1.1 → 0.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
  SHA1:
3
- metadata.gz: 3213039e80799fcb8245845bf54d01ec4f55f6ac
4
- data.tar.gz: 71e9b033a35755487e35fe3a078307c5d7eb487b
3
+ metadata.gz: 3dea9d3f8d30290d68b415caa381334cda8bbc80
4
+ data.tar.gz: 1d8329b5fa7a7bc39b5c52181283d23f1c8747f1
5
5
  SHA512:
6
- metadata.gz: 1799d0d2bdacfe66202cd1ec51b9bc86ef3a567d932ef382201e34adc8e2d830d6ffc485c2dfc7b9ddc115eea44ed6a619a30e91c2b6399e1546bb28c926b4d8
7
- data.tar.gz: 5c0af4fd576567e0973dd8b51d298a658cf15f0c7a746a9381b9dcb771590cd2c720e817dee36e821ff1952a4f037181acc36361946db8b7cc912c88e307cbb8
6
+ metadata.gz: 1b10974eb32c5e43b61c6b801762ffee5cb1cb54b071bb5b87d3db06de22fc752c1f5754b81e29b019adbb39ad82d7b7d062eb348257188722ab4977e9dac46c
7
+ data.tar.gz: 12558bb962caf426b3e6dde17fa1d9dd0a1a0621f3a05f8a8d8e33d6ce5622f3354830be8aba2dd638d539419a95dac9bb073646c810d17633f7080e135672e4
data/Rakefile CHANGED
@@ -5,6 +5,10 @@ require 'fileutils'
5
5
  p base_path = File.expand_path('..', __FILE__)
6
6
  p basename = File.basename(base_path)
7
7
 
8
+ task :default do
9
+ system 'rake -T'
10
+ end
11
+
8
12
  desc "make documents by yard"
9
13
  task :yard => [:hiki2md] do
10
14
  YARD::Rake::YardocTask.new
data/lib/hiki2yard.rb CHANGED
@@ -1,7 +1,8 @@
1
1
  # -*- coding: utf-8 -*-
2
2
  require 'optparse'
3
+ require 'fileutils'
3
4
  require "hiki2yard/version"
4
- require 'hikiutils'
5
+
5
6
 
6
7
  module Hiki2yard
7
8
  class Command
@@ -13,8 +14,9 @@ module Hiki2yard
13
14
  @argv = argv
14
15
  @source_path = File.expand_path('..', __FILE__)
15
16
  @target_path = Dir.pwd
16
- p @base_name=File.basename(@target_path)
17
- p @source_path,@target_path
17
+ @base_name=File.basename(@target_path)
18
+ print "source_path= \'#{@source_path}\'\n"
19
+ print "target_path= \'#{@target_path}\'\n"
18
20
  @opts={}
19
21
  end
20
22
 
@@ -50,6 +52,7 @@ module Hiki2yard
50
52
  def rev_rakefile
51
53
  source=File.join(@source_path,'hiki2yard','new_rakefile')
52
54
  target=File.join(@target_path,'Rakefile')
55
+ p @opts[:force]
53
56
  if @opts[:force] then
54
57
  copy_file_even_if_exists(source, target)
55
58
  else
@@ -68,7 +71,10 @@ module Hiki2yard
68
71
  end
69
72
 
70
73
  def copy_file_if_not_exists(source, target)
71
- return if File::exists?(target)
74
+ if File::exists?(target)
75
+ print "File #{target} exists, not copy.\n"
76
+ return
77
+ end
72
78
  FileUtils.cp(source,target,:verbose=>true) # :noop=>true)
73
79
  end
74
80
 
@@ -5,6 +5,10 @@ require 'fileutils'
5
5
  p base_path = File.expand_path('..', __FILE__)
6
6
  p basename = File.basename(base_path)
7
7
 
8
+ task :default do
9
+ system 'rake -T'
10
+ end
11
+
8
12
  desc "make documents by yard"
9
13
  task :yard => [:hiki2md] do
10
14
  YARD::Rake::YardocTask.new
@@ -1,3 +1,3 @@
1
1
  module Hiki2yard
2
- VERSION = "0.1.1"
2
+ VERSION = "0.1.2"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: hiki2yard
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.1
4
+ version: 0.1.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Shigeto R. Nishitani