From d6bdc618e4fd92ea0be794800b73a78d2fb9991f Mon Sep 17 00:00:00 2001 From: pks Date: Mon, 8 Apr 2024 09:08:13 +0000 Subject: select-from: large files --- select-from | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'select-from') diff --git a/select-from b/select-from index e06e4fb..0ccfeac 100755 --- a/select-from +++ b/select-from @@ -11,8 +11,8 @@ opts = Optimist::options do end accept = {} -f = ReadFile.new opts[:index] -f.readlines_strip.each { |line| +f = File.open opts[:index] +f.each_line { |line| i = line.strip.to_i accept[i] = true -- cgit v1.2.3