very_safe_rm 0.2.6 → 0.2.7

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 8242f26620b7c9650da6ad127f77ecd3e52992d0
4
- data.tar.gz: 3bc08c375cce30f9a395395616c02d5c9e93b8ea
3
+ metadata.gz: 7fb6bd8e3a478f2d01b8cfbd590caaeb3127e041
4
+ data.tar.gz: e0ea48605fdf5360269fd54af0b8835945b8a328
5
5
  SHA512:
6
- metadata.gz: e498cff33226dd84da0e3b231751892c526665364a2e8909d14f0b6399508549c123312376889fb1ce778b7ab911f74d31dbd9e2dbd648b86bfc58e38c25734e
7
- data.tar.gz: 346283fae911a0b950d0a35054cf5a4ab3a30d0da04a9dd60b80e5e5d04ea69323f0e5eb9ee6b8ccfdc86d2915e2e1af3fe11a12e462d8e8040d42777638c63d
6
+ metadata.gz: 9f03cb71491b2ad80ed2ec7d44667fd63f2b065ae5ae656bbf95a3c714ebed96c6428bca29cce4e54b12944f4a9c66f9e1ba31bae15611dd207251d2a62166b2
7
+ data.tar.gz: cef4759af80c54cba694460d236cf9e5037be0877c39f621b3ba0c0a45cac1ff910695f87fd59d5c6d340d3418da7330d55a37511509d543ce91b104b8d2024f
@@ -2,7 +2,7 @@ module VerySafeRm
2
2
  # TODO
3
3
  module RM
4
4
  def self.rm(file, args)
5
- system "rm #{args.join ' '} -- #{file}"
5
+ system %(rm #{args.join ' '} -- "#{file}")
6
6
  end
7
7
 
8
8
  def self.do_rm(file, args)
@@ -13,7 +13,7 @@ module VerySafeRm
13
13
 
14
14
  def self.rm_one(file, args)
15
15
  return RM.rm file, [] unless File.exist? file
16
- filesystem = `stat -fc %T #{file}`
16
+ filesystem = `stat -fc %T "#{file}"`
17
17
  if filesystem == 'nilfs' then RM.rm file, ['-r', '-v', '-f']
18
18
  elsif Dir.empty? file then RM.rm file, ['-r', '-f', '-v']
19
19
  elsif File.empty? file then RM.rm file, ['-f', '-v']
@@ -1,3 +1,3 @@
1
1
  module VerySafeRm
2
- VERSION = "0.2.6"
2
+ VERSION = "0.2.7"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: very_safe_rm
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.6
4
+ version: 0.2.7
5
5
  platform: ruby
6
6
  authors:
7
7
  - 71e6fd52
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2017-10-04 00:00:00.000000000 Z
11
+ date: 2017-10-12 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler