Sha256: f45b7e90c41bb759b0cb98fde9765048ccbe906a16b7660cedb090348443d1c5
Contents?: true
Size: 307 Bytes
Versions: 3
Compression:
Stored size: 307 Bytes
Contents
class Pathname # Reads the first line of the file # # Captures the best practice from this post at stack overflow: # https://stackoverflow.com/questions/1490138/reading-the-first-line-of-a-file-in-ruby # # Credit: Ryan Duryea def readline(*args) open { |f| f.readline(*args) } end end
Version data entries
3 entries across 3 versions & 2 rubygems
Version | Path |
---|---|
facets-glimmer-3.2.0 | lib/standard/facets/pathname/readline.rb |
facets-3.1.0 | lib/standard/facets/pathname/readline.rb |
facets-3.0.0 | lib/standard/facets/pathname/readline.rb |