Sha256: 328f51bd633b3325e8ddfb72ccbc612d310bd4e75f2f0af5154c566b05aeaaeb
Contents?: true
Size: 442 Bytes
Versions: 46
Compression:
Stored size: 442 Bytes
Contents
# -*- coding: utf-8 -*- module GrenFileTest IGNORE_FILE = /(\A#.*#\Z)|(~\Z)|(\A\.#)|(\.d\Z)|(\.map\Z)|(\.MAP\Z)/ IGNORE_DIR = /(\A\.svn\Z)|(\A\.git\Z)|(\ACVS\Z)/ def self.ignoreDir?(fpath) IGNORE_DIR.match(File.basename(fpath)) end def self.ignoreFile?(fpath) IGNORE_FILE.match(File.basename(fpath)) end def self.binary?(fpath) s = File.read(fpath, 1024) or return false return s.index("\x00") end end
Version data entries
46 entries across 46 versions & 3 rubygems