fe_core_ext 0.9.0 → 0.11.1

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
  SHA256:
3
- metadata.gz: 0ad61cadab269ee32452f5beffbbea704da10b231c4283d6e36d50bf15b88f5b
4
- data.tar.gz: 9a8dbf59f02483aee9579ef822a8ba959da000ce30102b25ebd8522d6d32a500
3
+ metadata.gz: ad6343d63437a657f4dbde3f98b6bdca17d5df33f8e8f90e1ca4db43527e1f60
4
+ data.tar.gz: 7f963b9bd854709fbd3340d9dc64aa1982daa16ef3c2570e60ad84523aaceb86
5
5
  SHA512:
6
- metadata.gz: 2c0559268079f39269f6b9af9c2509577abd9f18ff8d2037dc71fd30fce96576425e6a1cda15dac89ad81afdf1b5ee50ebbdda373c9044b2f4ea384a730071da
7
- data.tar.gz: 4b3df4d8d22ea1e737d0bd93262ba555eddc28919a483641fc4c54dc931b182aa7a3fb2126c5bcd2aed15b8b6ab4a2c8633e7cd8acb7df1930667b6af7e9256c
6
+ metadata.gz: 7c38d35d96d71b246b87381c6bbe130aa158b411f22f697d23ad9d9b529d2c42030dad9c12a5de6a7501cfedf3a990904999f18a8e33db8337b19fccd4fd0d1b
7
+ data.tar.gz: f96c3906315cf51ba426a61aa05b3af80ae65e5f93f037e74ebe27c150d29f06af3e0558b5bbe16382ede15f0b45f8d5ac4409fbb054c38dcbbb10e86f735081
data/Rakefile CHANGED
@@ -1,6 +1,6 @@
1
1
  require 'bundler/gem_tasks'
2
- require 'rspec/core/rake_task'
3
-
4
- RSpec::Core::RakeTask.new(:spec)
2
+ # require 'rspec/core/rake_task'
3
+ #
4
+ # RSpec::Core::RakeTask.new(:spec)
5
5
 
6
6
  task :default => :spec
@@ -20,8 +20,8 @@ Gem::Specification.new do |spec|
20
20
  spec.require_paths = ['lib']
21
21
 
22
22
  spec.add_runtime_dependency 'activesupport'
23
- spec.add_development_dependency 'bundler', '~> 1.10'
24
- spec.add_development_dependency 'rake', '~> 10.0'
23
+ spec.add_development_dependency 'bundler', '~> 2.1'
24
+ spec.add_development_dependency 'rake', '~> 12.3'
25
25
  spec.add_development_dependency 'rspec', '~> 0'
26
26
  spec.add_development_dependency 'selenium-webdriver', '~> 0'
27
27
  end
@@ -19,6 +19,15 @@ module FeCoreExt::CoreExt::Date
19
19
  end
20
20
 
21
21
  module FeCoreExt::CoreExt::DateClassMethods
22
+ def parsable?(string)
23
+ begin
24
+ parse(string)
25
+ true
26
+ rescue ArgumentError
27
+ false
28
+ end
29
+ end
30
+
22
31
  def parse_as_future(string)
23
32
  date = parse(string)
24
33
  date > current ? date : date + 1.year
@@ -37,9 +37,19 @@ module FeCoreExt::CoreExt::PathnameClassMethods
37
37
  def join(*args)
38
38
  new(File.join(*args))
39
39
  end
40
+
41
+ def mktmpdir(prefix_suffix=nil, tmpdir=nil)
42
+ if block_given?
43
+ Dir.mktmpdir prefix_suffix, tmpdir do |dir|
44
+ yield new(dir)
45
+ end
46
+ else
47
+ new(Dir.mktmpdir(prefix_suffix, tmpdir))
48
+ end
49
+ end
40
50
  end
41
51
 
42
52
  class Pathname
43
53
  extend FeCoreExt::CoreExt::PathnameClassMethods
44
54
  include FeCoreExt::CoreExt::Pathname
45
- end
55
+ end
@@ -22,6 +22,6 @@ end
22
22
 
23
23
  class URI::Generic
24
24
  def basename
25
- File.basename(path)
25
+ ::File.basename(path)
26
26
  end
27
27
  end
@@ -1,3 +1,3 @@
1
1
  module FeCoreExt
2
- VERSION = '0.9.0'
3
- end
2
+ VERSION = '0.11.1'
3
+ end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fe_core_ext
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.9.0
4
+ version: 0.11.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Tetsu
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2019-04-30 00:00:00.000000000 Z
11
+ date: 2020-09-16 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activesupport
@@ -30,28 +30,28 @@ dependencies:
30
30
  requirements:
31
31
  - - "~>"
32
32
  - !ruby/object:Gem::Version
33
- version: '1.10'
33
+ version: '2.1'
34
34
  type: :development
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
38
  - - "~>"
39
39
  - !ruby/object:Gem::Version
40
- version: '1.10'
40
+ version: '2.1'
41
41
  - !ruby/object:Gem::Dependency
42
42
  name: rake
43
43
  requirement: !ruby/object:Gem::Requirement
44
44
  requirements:
45
45
  - - "~>"
46
46
  - !ruby/object:Gem::Version
47
- version: '10.0'
47
+ version: '12.3'
48
48
  type: :development
49
49
  prerelease: false
50
50
  version_requirements: !ruby/object:Gem::Requirement
51
51
  requirements:
52
52
  - - "~>"
53
53
  - !ruby/object:Gem::Version
54
- version: '10.0'
54
+ version: '12.3'
55
55
  - !ruby/object:Gem::Dependency
56
56
  name: rspec
57
57
  requirement: !ruby/object:Gem::Requirement
@@ -131,7 +131,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
131
131
  version: '0'
132
132
  requirements: []
133
133
  rubyforge_project:
134
- rubygems_version: 2.7.6
134
+ rubygems_version: 2.7.6.2
135
135
  signing_key:
136
136
  specification_version: 4
137
137
  summary: Core class extensions