cmd_tools 6.0.1 → 7.0.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml ADDED
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: ea749109fd43a86d8d34e5e4e9a7166ac2e8fc71
4
+ data.tar.gz: bf3df36a6d55723a35259e663de41116bf3c5f6d
5
+ SHA512:
6
+ metadata.gz: 1bbe831e11c271662bc850b1f7539a0541133272c3d2f3cbfcdf25971b9dcbdce7c8e2c66d7b6eb6ce7547009e2cc003b6bdf3ffa9d81299aadc6d4ebb485483
7
+ data.tar.gz: 8fd18d1a5f8ec0d2a7ef05b100cfe255c51094bc8c93f896efb2772c548467e1d1e460449e7bad37e6366841d711f3045080054b7656933d34f1797d1f2f1b3e
data/cmd_tools.gemspec CHANGED
@@ -22,5 +22,5 @@ to see details.
22
22
  EOS
23
23
  s.executables << 'cmd_tools'
24
24
  s.post_install_message = "\n#{::CmdTools::RECOMMENDED_SHELL_SETTINGS}\n"
25
- s.required_ruby_version = '~> 1.9'
25
+ s.required_ruby_version = '>= 1.9'
26
26
  end
@@ -16,7 +16,7 @@ module ::CmdTools::Command::Backup
16
16
  nested_bak_dir_reg = /\A#{bak_dir}\/.*#{BAK_DIR_HEAD}\d{12}\z/
17
17
  FileUtils.mkdir_p(bak_dir)
18
18
  (files.flatten.map{|f| f.chomp('/')} - ['.', '..', bak_dir])\
19
- .select{|f| File.exist?(f)}\
19
+ .select{|f| File.exist?(f) || File.symlink?(f)}\
20
20
  .each{|f|
21
21
  dest = get_dest(bak_dir, f, time_stamp)
22
22
  begin
@@ -17,7 +17,7 @@ module ::CmdTools::Command::EmacsLaunch
17
17
  files_str = files.flatten.shelljoin
18
18
  case mode
19
19
  when :gui
20
- if is_gui_running?
20
+ if gui_running?
21
21
  emacsclient_open(files_str)
22
22
  else
23
23
  spawn "emacsclient -c -n #{files_str}"
@@ -35,17 +35,19 @@ module ::CmdTools::Command::EmacsLaunch
35
35
  exec "emacsclient -e '(kill-emacs)'" if daemon_running?
36
36
  end
37
37
 
38
- private
38
+ class << self
39
+ private
39
40
 
40
- def self.daemon_running?
41
- system "emacsclient -e '()' > #{File::NULL} 2>&1"
42
- end
41
+ def daemon_running?
42
+ system "emacsclient -e '()' > #{File::NULL} 2>&1"
43
+ end
43
44
 
44
- def self.is_gui_running?
45
- ::CmdTools::Config.emacs_window_systems.include?(`emacsclient -e "(window-system)"`.strip)
46
- end
45
+ def gui_running?
46
+ ::CmdTools::Config.emacs_window_systems.include?(`emacsclient -e "(window-system)"`.strip)
47
+ end
47
48
 
48
- def self.emacsclient_open(files_str)
49
- spawn "emacsclient -n #{files_str}"
49
+ def emacsclient_open(files_str)
50
+ spawn "emacsclient -n #{files_str}"
51
+ end
50
52
  end
51
53
  end
@@ -12,7 +12,7 @@ module ::CmdTools::Command::Trash
12
12
  time = Time.now.ymdhms
13
13
  prefix = File.join(TRASH_DIR, time) + '.'
14
14
  (files.flatten - ['.', '..'])\
15
- .select{|f| File.exist?(f)}\
15
+ .select{|f| File.exist?(f) || File.symlink?(f)}\
16
16
  .each{|f|
17
17
  begin
18
18
  FileUtils.mv(f, prefix + File.basename(f))
@@ -1,3 +1,3 @@
1
1
  module CmdTools
2
- VERSION = '6.0.1'
2
+ VERSION = '7.0.0'
3
3
  end
metadata CHANGED
@@ -1,47 +1,49 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: cmd_tools
3
3
  version: !ruby/object:Gem::Version
4
- version: 6.0.1
5
- prerelease:
4
+ version: 7.0.0
6
5
  platform: ruby
7
6
  authors:
8
7
  - kshramt
9
8
  autorequire:
10
9
  bindir: bin
11
10
  cert_chain: []
12
- date: 2012-12-25 00:00:00.000000000 Z
11
+ date: 2013-04-29 00:00:00.000000000 Z
13
12
  dependencies:
14
13
  - !ruby/object:Gem::Dependency
15
14
  name: ruby_patch
16
- requirement: &2152833160 !ruby/object:Gem::Requirement
17
- none: false
15
+ requirement: !ruby/object:Gem::Requirement
18
16
  requirements:
19
17
  - - ~>
20
18
  - !ruby/object:Gem::Version
21
19
  version: '2.0'
22
20
  type: :runtime
23
21
  prerelease: false
24
- version_requirements: *2152833160
22
+ version_requirements: !ruby/object:Gem::Requirement
23
+ requirements:
24
+ - - ~>
25
+ - !ruby/object:Gem::Version
26
+ version: '2.0'
25
27
  - !ruby/object:Gem::Dependency
26
28
  name: thor
27
- requirement: &2152832680 !ruby/object:Gem::Requirement
28
- none: false
29
+ requirement: !ruby/object:Gem::Requirement
29
30
  requirements:
30
31
  - - ~>
31
32
  - !ruby/object:Gem::Version
32
33
  version: '0.16'
33
34
  type: :runtime
34
35
  prerelease: false
35
- version_requirements: *2152832680
36
- description: ! 'Command line tools. Please type
37
-
36
+ version_requirements: !ruby/object:Gem::Requirement
37
+ requirements:
38
+ - - ~>
39
+ - !ruby/object:Gem::Version
40
+ version: '0.16'
41
+ description: |
42
+ Command line tools. Please type
38
43
 
39
44
  $ cmd_tools help
40
45
 
41
-
42
46
  to see details.
43
-
44
- '
45
47
  email:
46
48
  executables:
47
49
  - cmd_tools
@@ -57,7 +59,6 @@ files:
57
59
  - bin/command/emacs_stop
58
60
  - bin/command/min_max
59
61
  - bin/command/tsh
60
- - bin/command/uncomment
61
62
  - cmd_tools.gemspec
62
63
  - lib/cmd_tools.rb
63
64
  - lib/cmd_tools/application.rb
@@ -73,34 +74,29 @@ files:
73
74
  - test/test_command.rb
74
75
  homepage:
75
76
  licenses: []
76
- post_install_message: ! '
77
+ metadata: {}
78
+ post_install_message: |2+
77
79
 
78
80
  # CmdTools
81
+ export PATH=${HOME}/.gem/ruby/1.9.1/gems/cmd_tools-7.0.0/bin/command:${PATH}
79
82
 
80
- export PATH=${HOME}/.gem/ruby/1.9.1/gems/cmd_tools-6.0.1/bin/command:${PATH}
81
-
82
-
83
- '
84
83
  rdoc_options: []
85
84
  require_paths:
86
85
  - lib
87
86
  required_ruby_version: !ruby/object:Gem::Requirement
88
- none: false
89
87
  requirements:
90
- - - ~>
88
+ - - '>='
91
89
  - !ruby/object:Gem::Version
92
90
  version: '1.9'
93
91
  required_rubygems_version: !ruby/object:Gem::Requirement
94
- none: false
95
92
  requirements:
96
- - - ! '>='
93
+ - - '>='
97
94
  - !ruby/object:Gem::Version
98
95
  version: '0'
99
96
  requirements: []
100
97
  rubyforge_project:
101
- rubygems_version: 1.8.15
98
+ rubygems_version: 2.0.0
102
99
  signing_key:
103
- specification_version: 3
100
+ specification_version: 4
104
101
  summary: Command line tools.
105
102
  test_files: []
106
- has_rdoc:
@@ -1,2 +0,0 @@
1
- #!/bin/sh
2
- sed -e '/^ *#/d' "$@"