Module: Gitrb::Util

Defined in:
lib/gitrb/util.rb

Class Method Summary collapse

Class Method Details

.read_bytes_until(io, char) ⇒ Object



4
5
6
7
8
9
10
# File 'lib/gitrb/util.rb', line 4

def self.read_bytes_until(io, char)
  str = ''
  while ((ch = io.getc) != char) && !io.eof
    str << ch
  end
  str
end