Skip to content

Commit 2a16d03

Browse files
authored
Merge pull request #275 from zhustec/master
Remove trailing extension name
2 parents 51fdc40 + a54a506 commit 2a16d03

File tree

8 files changed

+11
-11
lines changed

8 files changed

+11
-11
lines changed

lib/rake/application.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -687,7 +687,7 @@ def print_rakefile_directory(location) # :nodoc:
687687

688688
def raw_load_rakefile # :nodoc:
689689
rakefile, location = find_rakefile_location
690-
if (! options.ignore_system) &&
690+
if (!options.ignore_system) &&
691691
(options.load_system || rakefile.nil?) &&
692692
system_dir && File.directory?(system_dir)
693693
print_rakefile_directory(location)

lib/rake/file_creation_task.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ module Rake
1212
class FileCreationTask < FileTask
1313
# Is this file task needed? Yes if it doesn't exist.
1414
def needed?
15-
! File.exist?(name)
15+
!File.exist?(name)
1616
end
1717

1818
# Time stamp for file creation task. This time stamp is earlier

lib/rake/file_list.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -385,7 +385,7 @@ def excluded_from_list?(fn)
385385
/~$/
386386
]
387387
DEFAULT_IGNORE_PROCS = [
388-
proc { |fn| fn =~ /(^|[\/\\])core$/ && ! File.directory?(fn) }
388+
proc { |fn| fn =~ /(^|[\/\\])core$/ && !File.directory?(fn) }
389389
]
390390

391391
def import(array) # :nodoc:

lib/rake/file_task.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# frozen_string_literal: true
2-
require "rake/task.rb"
2+
require "rake/task"
33
require "rake/early_time"
44

55
module Rake
@@ -14,7 +14,7 @@ class FileTask < Task
1414
# Is this file task needed? Yes if it doesn't exist, or if its time stamp
1515
# is out of date.
1616
def needed?
17-
! File.exist?(name) || out_of_date?(timestamp) || @application.options.build_all
17+
!File.exist?(name) || out_of_date?(timestamp) || @application.options.build_all
1818
end
1919

2020
# Time stamp for file task.

lib/rake/file_utils.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ module FileUtils
3535
#
3636
# # check exit status after command runs
3737
# sh %{grep pattern file} do |ok, res|
38-
# if ! ok
38+
# if !ok
3939
# puts "pattern not found (status = #{res.exitstatus})"
4040
# end
4141
# end
@@ -111,7 +111,7 @@ def ruby(*args, &block)
111111
# Attempt to do a normal file link, but fall back to a copy if the link
112112
# fails.
113113
def safe_ln(*args)
114-
if ! LN_SUPPORTED[0]
114+
if !LN_SUPPORTED[0]
115115
cp(*args)
116116
else
117117
begin

lib/rake/promise.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -71,12 +71,12 @@ def chore
7171

7272
# Do we have a result for the promise
7373
def result?
74-
! @result.equal?(NOT_SET)
74+
!@result.equal?(NOT_SET)
7575
end
7676

7777
# Did the promise throw an error
7878
def error?
79-
! @error.equal?(NOT_SET)
79+
!@error.equal?(NOT_SET)
8080
end
8181

8282
# Are we done with the promise

lib/rake/scope.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ def path_with_task_name(task_name)
1616
# this trim beyond the toplevel scope.
1717
def trim(n)
1818
result = self
19-
while n > 0 && ! result.empty?
19+
while n > 0 && !result.empty?
2020
result = result.tail
2121
n -= 1
2222
end

lib/rake/task.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -288,7 +288,7 @@ def timestamp
288288
def add_description(description)
289289
return unless description
290290
comment = description.strip
291-
add_comment(comment) if comment && ! comment.empty?
291+
add_comment(comment) if comment && !comment.empty?
292292
end
293293

294294
def comment=(comment) # :nodoc:

0 commit comments

Comments
 (0)