lib/linguist/generated.rb in github-linguist-7.2.0 vs lib/linguist/generated.rb in github-linguist-7.3.0
- old
+ new
@@ -97,11 +97,11 @@
# Internal: Is the blob an Xcode file?
#
# Generated if the file extension is an Xcode
# file extension.
#
- # Returns true of false.
+ # Returns true or false.
def xcode_file?
['.nib', '.xcworkspacedata', '.xcuserstate'].include?(extname)
end
# Internal: Is the blob part of Pods/, which contains dependencies not meant for humans in pull requests.
@@ -299,22 +299,22 @@
PROTOBUF_EXTENSIONS = ['.py', '.java', '.h', '.cc', '.cpp', '.rb']
# Internal: Is the blob a C++, Java or Python source file generated by the
# Protocol Buffer compiler?
#
- # Returns true of false.
+ # Returns true or false.
def generated_protocol_buffer?
return false unless PROTOBUF_EXTENSIONS.include?(extname)
return false unless lines.count > 1
return lines[0].include?("Generated by the protocol buffer compiler. DO NOT EDIT!")
end
# Internal: Is the blob a Javascript source file generated by the
# Protocol Buffer compiler?
#
- # Returns true of false.
+ # Returns true or false.
def generated_javascript_protocol_buffer?
return false unless extname == ".js"
return false unless lines.count > 6
return lines[5].include?("GENERATED CODE -- DO NOT EDIT!")
@@ -330,11 +330,11 @@
return lines.first(6).any? { |l| l.include?("Autogenerated by Thrift Compiler") }
end
# Internal: Is the blob a C/C++ header generated by the Java JNI tool javah?
#
- # Returns true of false.
+ # Returns true or false.
def generated_jni_header?
return false unless extname == '.h'
return false unless lines.count > 2
return lines[0].include?("/* DO NOT EDIT THIS FILE - it is machine generated */") &&
@@ -430,10 +430,10 @@
#
# GFortran module files contain:
# GFORTRAN module version 'x' created from
# on the first line.
#
- # Return true of false
+ # Return true or false
def generated_module?
return false unless extname == '.mod'
return false unless lines.count > 1
return lines[0].include?("PCBNEW-LibModule-V") ||
lines[0].include?("GFORTRAN module version '")