Skip to content
Find file
Fetching contributors…
Cannot retrieve contributors at this time
executable file 22 lines (16 sloc) 428 Bytes
#!/usr/bin/env ruby
require 'rubygems'
require 'marc'
# quit unless our script gets two command line arguments
unless ARGV.length == 1
puts "Missing input file!"
puts "Usage: ruby marcdump.rb InputFile.mrc\n"
# our input file should be the first command line arg
input_file = ARGV[0]
# reading records from a batch file
reader =
reader.each do | record |
puts record
Jump to Line
Something went wrong with that request. Please try again.