summaryrefslogtreecommitdiff
path: root/geturl.rb
diff options
context:
space:
mode:
authorhaturatu <taro@eyes4you.org>2024-10-09 01:36:19 +0900
committerhaturatu <taro@eyes4you.org>2024-10-09 01:36:19 +0900
commit031b8014901bd101d92af148a841e9b9c8fb59f5 (patch)
treee284928681323b7bebf08f34bb15db8a11a20f5c /geturl.rb
parent736e6f490c6a9555141188c78c6aa48782d3b5b6 (diff)
fi
Diffstat (limited to 'geturl.rb')
-rwxr-xr-xgeturl.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/geturl.rb b/geturl.rb
index 804ed91..c5422c3 100755
--- a/geturl.rb
+++ b/geturl.rb
@@ -7,7 +7,7 @@ require 'nokogiri'
require 'charlock_holmes'
require 'unicode_utils'
-$FILE_PATH = './ok'
+$FILE_PATH = '/Your/URLs/list/file'
$RESULT_FILE = 'Result'
$OTHER_ERROR_FILE = 'Other'
$CONCURRENCY = 10
@@ -17,7 +17,7 @@ def is_garbled?(text)
end
def clean_title(title)
- title = title.chars.reject { |ch| UnicodeUtils.general_category(ch).start_with?('C') && !['(', ')', '[', ']', '{', '}', '【', '】', '「', '」', '(' ,')' ].include?(ch) }.join
+ title = title.chars.reject { |ch| UnicodeUtils.general_category(ch).start_with?('C') && !['(', ')', '[', ']', '{', '}', '【', '】', '【', '】', '「', '」', '(' ,')' ].include?(ch) }.join
title = UnicodeUtils.nfkc(title)
title = title.chars.select(&:valid_encoding?).join
title.strip