mirror of
https://github.com/jimeh/dotfiles.git
synced 2026-02-19 04:46:41 +00:00
18 lines
318 B
Ruby
Executable File
18 lines
318 B
Ruby
Executable File
#! /usr/bin/env ruby
|
|
|
|
ARGV.each do |path|
|
|
print "Checking \"#{path}\"... "
|
|
|
|
if !File.exists?(path)
|
|
puts "FILE NOT FOUND"
|
|
next
|
|
end
|
|
|
|
checksum = `crc32 "#{path}"`.strip.upcase
|
|
if File.basename(path).upcase.include?(checksum)
|
|
puts "MATCH (#{checksum})"
|
|
else
|
|
puts "FAIL (#{checksum})"
|
|
end
|
|
end
|