some more stuff
Browse files- caption/locales/ja/LC_MESSAGES/wdv3.po +20 -8
- utils/compile_translations +66 -0
- utils/locales/ja/LC_MESSAGES/compile_translations.po +39 -0
- utils/locales/ja/LC_MESSAGES/concat_captions.po +19 -4
- utils/locales/ja/LC_MESSAGES/concat_captions_prefix_filename.po +27 -0
- utils/locales/ja/LC_MESSAGES/concat_captions_wdv3.po +30 -0
- utils/locales/ja/LC_MESSAGES/cringehash.po +24 -0
- utils/locales/ja/LC_MESSAGES/extract_description.po +30 -0
- utils/locales/ja/LC_MESSAGES/img_remove_white_border.po +24 -0
- utils/locales/ja/LC_MESSAGES/keyframe.po +27 -0
- utils/locales/ja/LC_MESSAGES/nocap.po +24 -0
- utils/locales/ja/LC_MESSAGES/remove_extra_whitespace.po +18 -0
- utils/locales/ja/LC_MESSAGES/remove_grandfathered.po +18 -0
- utils/locales/ja/LC_MESSAGES/shortcode.po +27 -0
- utils/locales/ja/LC_MESSAGES/tags2txt_safe.po +18 -0
- utils/locales/ja/LC_MESSAGES/txt2e621.po +15 -0
- utils/locales/ja/LC_MESSAGES/txt2emoji.po +27 -0
- utils/locales/ja/LC_MESSAGES/txt2tags.po +21 -0
- utils/locales/ja/LC_MESSAGES/yiffdata.po +24 -0
- utils/txt2emoji +18 -0
caption/locales/ja/LC_MESSAGES/wdv3.po
CHANGED
@@ -8,14 +8,26 @@ msgstr ""
|
|
8 |
"Content-Type: text/plain; charset=UTF-8\n"
|
9 |
"Content-Transfer-Encoding: 8bit\n"
|
10 |
|
11 |
-
msgid "
|
12 |
-
msgstr "
|
13 |
|
14 |
-
msgid "Model
|
15 |
-
msgstr "
|
16 |
|
17 |
-
msgid "
|
18 |
-
msgstr "{}
|
19 |
|
20 |
-
msgid "
|
21 |
-
msgstr "{}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
8 |
"Content-Type: text/plain; charset=UTF-8\n"
|
9 |
"Content-Transfer-Encoding: 8bit\n"
|
10 |
|
11 |
+
msgid "Processing image: {}"
|
12 |
+
msgstr "画像を処理中: {}"
|
13 |
|
14 |
+
msgid "Model loaded successfully"
|
15 |
+
msgstr "モデルの読み込みが完了しました"
|
16 |
|
17 |
+
msgid "Error loading model: {}"
|
18 |
+
msgstr "モデルの読み込み中にエラー: {}"
|
19 |
|
20 |
+
msgid "Generated tags for {}"
|
21 |
+
msgstr "{}のタグを生成しました"
|
22 |
+
|
23 |
+
msgid "Saved tags to {}"
|
24 |
+
msgstr "タグを{}に保存しました"
|
25 |
+
|
26 |
+
msgid "Invalid image format: {}"
|
27 |
+
msgstr "無効な画像形式です: {}"
|
28 |
+
|
29 |
+
msgid "Using model architecture: {}"
|
30 |
+
msgstr "使用するモデルアーキテクチャ: {}"
|
31 |
+
|
32 |
+
msgid "Processing batch {} of {}"
|
33 |
+
msgstr "バッチ{}/{}を処理中"
|
utils/compile_translations
ADDED
@@ -0,0 +1,66 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
#!/usr/bin/env python
|
2 |
+
# -*- coding: utf-8 -*-
|
3 |
+
#
|
4 |
+
# .poファイルを.moファイルにコンパイルする
|
5 |
+
# Compile .po files to .mo files
|
6 |
+
|
7 |
+
import os
|
8 |
+
import subprocess
|
9 |
+
from pathlib import Path
|
10 |
+
import logging
|
11 |
+
|
12 |
+
# Set up logging
|
13 |
+
logging.basicConfig(
|
14 |
+
level=logging.INFO,
|
15 |
+
format='%(levelname)s: %(message)s'
|
16 |
+
)
|
17 |
+
|
18 |
+
def compile_po_files(start_dir='.'):
|
19 |
+
"""
|
20 |
+
Find and compile all .po files in subdirectories to .mo files
|
21 |
+
"""
|
22 |
+
success_count = 0
|
23 |
+
error_count = 0
|
24 |
+
|
25 |
+
# Convert to Path object
|
26 |
+
start_path = Path(start_dir)
|
27 |
+
|
28 |
+
# Find all .po files
|
29 |
+
po_files = list(start_path.rglob('*.po'))
|
30 |
+
|
31 |
+
if not po_files:
|
32 |
+
logging.warning("No .po files found")
|
33 |
+
return
|
34 |
+
|
35 |
+
logging.info(f"Found {len(po_files)} .po files")
|
36 |
+
|
37 |
+
for po_file in po_files:
|
38 |
+
mo_file = po_file.with_suffix('.mo')
|
39 |
+
|
40 |
+
try:
|
41 |
+
# Run msgfmt
|
42 |
+
subprocess.run(['msgfmt', str(po_file), '-o', str(mo_file)],
|
43 |
+
check=True,
|
44 |
+
capture_output=True,
|
45 |
+
text=True)
|
46 |
+
logging.info(f"✓ Compiled {po_file}")
|
47 |
+
success_count += 1
|
48 |
+
|
49 |
+
except subprocess.CalledProcessError as e:
|
50 |
+
logging.error(f"✗ Failed to compile {po_file}")
|
51 |
+
logging.error(f"Error: {e.stderr}")
|
52 |
+
error_count += 1
|
53 |
+
|
54 |
+
except FileNotFoundError:
|
55 |
+
logging.error("msgfmt command not found. Please install gettext.")
|
56 |
+
return
|
57 |
+
|
58 |
+
# Print summary
|
59 |
+
logging.info("\nSummary:")
|
60 |
+
logging.info(f"Total files processed: {len(po_files)}")
|
61 |
+
logging.info(f"Successfully compiled: {success_count}")
|
62 |
+
if error_count > 0:
|
63 |
+
logging.error(f"Failed compilations: {error_count}")
|
64 |
+
|
65 |
+
if __name__ == '__main__':
|
66 |
+
compile_po_files()
|
utils/locales/ja/LC_MESSAGES/compile_translations.po
ADDED
@@ -0,0 +1,39 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
msgid ""
|
2 |
+
msgstr ""
|
3 |
+
"Project-Id-Version: compile_translations\n"
|
4 |
+
"Report-Msgid-Bugs-To: \n"
|
5 |
+
"POT-Creation-Date: 2024-03-21 12:00+0000\n"
|
6 |
+
"Language: ja\n"
|
7 |
+
"MIME-Version: 1.0\n"
|
8 |
+
"Content-Type: text/plain; charset=UTF-8\n"
|
9 |
+
"Content-Transfer-Encoding: 8bit\n"
|
10 |
+
|
11 |
+
msgid "No .po files found"
|
12 |
+
msgstr ".poファイルが見つかりません"
|
13 |
+
|
14 |
+
msgid "Found {} .po files"
|
15 |
+
msgstr "{}個の.poファイルが見つかりました"
|
16 |
+
|
17 |
+
msgid "✓ Compiled {}"
|
18 |
+
msgstr "✓ {}をコンパイルしました"
|
19 |
+
|
20 |
+
msgid "✗ Failed to compile {}"
|
21 |
+
msgstr "✗ {}のコンパイルに失敗しました"
|
22 |
+
|
23 |
+
msgid "Error: {}"
|
24 |
+
msgstr "エラー: {}"
|
25 |
+
|
26 |
+
msgid "msgfmt command not found. Please install gettext."
|
27 |
+
msgstr "msgfmtコマンドが見つかりません。gettextをインストールしてください。"
|
28 |
+
|
29 |
+
msgid "Summary:"
|
30 |
+
msgstr "概要:"
|
31 |
+
|
32 |
+
msgid "Total files processed: {}"
|
33 |
+
msgstr "処理されたファイル総数: {}"
|
34 |
+
|
35 |
+
msgid "Successfully compiled: {}"
|
36 |
+
msgstr "コンパイル成功: {}"
|
37 |
+
|
38 |
+
msgid "Failed compilations: {}"
|
39 |
+
msgstr "コンパイル失敗: {}"
|
utils/locales/ja/LC_MESSAGES/concat_captions.po
CHANGED
@@ -8,8 +8,23 @@ msgstr ""
|
|
8 |
"Content-Type: text/plain; charset=UTF-8\n"
|
9 |
"Content-Transfer-Encoding: 8bit\n"
|
10 |
|
11 |
-
msgid "
|
12 |
-
msgstr "{}
|
13 |
|
14 |
-
msgid "
|
15 |
-
msgstr "{}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
8 |
"Content-Type: text/plain; charset=UTF-8\n"
|
9 |
"Content-Transfer-Encoding: 8bit\n"
|
10 |
|
11 |
+
msgid "Processing directory: {}"
|
12 |
+
msgstr "ディレクトリを処理中: {}"
|
13 |
|
14 |
+
msgid "Concatenating files for {}"
|
15 |
+
msgstr "{}のファイルを連結中"
|
16 |
+
|
17 |
+
msgid "Missing caption file for {}"
|
18 |
+
msgstr "{}のキャプションファイルが見つかりません"
|
19 |
+
|
20 |
+
msgid "Missing tags file for {}"
|
21 |
+
msgstr "{}のタグファイルが見つかりません"
|
22 |
+
|
23 |
+
msgid "Created concatenated file: {}"
|
24 |
+
msgstr "連結ファイルを作成しました: {}"
|
25 |
+
|
26 |
+
msgid "Dry run: would create {}"
|
27 |
+
msgstr "ドライラン: {}を作成します"
|
28 |
+
|
29 |
+
msgid "Error processing file {}: {}"
|
30 |
+
msgstr "ファイル{}の処理中にエラー: {}"
|
utils/locales/ja/LC_MESSAGES/concat_captions_prefix_filename.po
ADDED
@@ -0,0 +1,27 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
msgid ""
|
2 |
+
msgstr ""
|
3 |
+
"Project-Id-Version: concat_captions_prefix_filename\n"
|
4 |
+
"Report-Msgid-Bugs-To: \n"
|
5 |
+
"POT-Creation-Date: 2024-03-21 12:00+0000\n"
|
6 |
+
"Language: ja\n"
|
7 |
+
"MIME-Version: 1.0\n"
|
8 |
+
"Content-Type: text/plain; charset=UTF-8\n"
|
9 |
+
"Content-Transfer-Encoding: 8bit\n"
|
10 |
+
|
11 |
+
msgid "Processing directory: {}"
|
12 |
+
msgstr "ディレクトリを処理中: {}"
|
13 |
+
|
14 |
+
msgid "Concatenating captions for {}"
|
15 |
+
msgstr "{}のキャプションを連結中"
|
16 |
+
|
17 |
+
msgid "Missing caption file for {}"
|
18 |
+
msgstr "{}のキャプションファイルが見つかりません"
|
19 |
+
|
20 |
+
msgid "Created concatenated file: {}"
|
21 |
+
msgstr "連結ファイルを作成しました: {}"
|
22 |
+
|
23 |
+
msgid "Dry run: would create {}"
|
24 |
+
msgstr "ドライラン: {}を作成します"
|
25 |
+
|
26 |
+
msgid "Error processing file {}: {}"
|
27 |
+
msgstr "ファイル{}の処理中にエラー: {}"
|
utils/locales/ja/LC_MESSAGES/concat_captions_wdv3.po
ADDED
@@ -0,0 +1,30 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
msgid ""
|
2 |
+
msgstr ""
|
3 |
+
"Project-Id-Version: concat_captions_wdv3\n"
|
4 |
+
"Report-Msgid-Bugs-To: \n"
|
5 |
+
"POT-Creation-Date: 2024-03-21 12:00+0000\n"
|
6 |
+
"Language: ja\n"
|
7 |
+
"MIME-Version: 1.0\n"
|
8 |
+
"Content-Type: text/plain; charset=UTF-8\n"
|
9 |
+
"Content-Transfer-Encoding: 8bit\n"
|
10 |
+
|
11 |
+
msgid "Processing directory: {}"
|
12 |
+
msgstr "ディレクトリを処理中: {}"
|
13 |
+
|
14 |
+
msgid "Concatenating files for {}"
|
15 |
+
msgstr "{}のファイルを連結中"
|
16 |
+
|
17 |
+
msgid "Missing caption file for {}"
|
18 |
+
msgstr "{}のキャプションファイルが見つかりません"
|
19 |
+
|
20 |
+
msgid "Missing WD file for {}"
|
21 |
+
msgstr "{}のWDファイルが見つかりません"
|
22 |
+
|
23 |
+
msgid "Created concatenated file: {}"
|
24 |
+
msgstr "連結ファイルを作成しました: {}"
|
25 |
+
|
26 |
+
msgid "Dry run: would create {}"
|
27 |
+
msgstr "ドライラン: {}を作成します"
|
28 |
+
|
29 |
+
msgid "Error processing file {}: {}"
|
30 |
+
msgstr "ファイル{}の処理中にエラー: {}"
|
utils/locales/ja/LC_MESSAGES/cringehash.po
ADDED
@@ -0,0 +1,24 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
msgid ""
|
2 |
+
msgstr ""
|
3 |
+
"Project-Id-Version: cringehash\n"
|
4 |
+
"Report-Msgid-Bugs-To: \n"
|
5 |
+
"POT-Creation-Date: 2024-03-21 12:00+0000\n"
|
6 |
+
"Language: ja\n"
|
7 |
+
"MIME-Version: 1.0\n"
|
8 |
+
"Content-Type: text/plain; charset=UTF-8\n"
|
9 |
+
"Content-Transfer-Encoding: 8bit\n"
|
10 |
+
|
11 |
+
msgid "Processing image: {}"
|
12 |
+
msgstr "画像を処理中: {}"
|
13 |
+
|
14 |
+
msgid "Generated blurhash: {}"
|
15 |
+
msgstr "生成されたblurhash: {}"
|
16 |
+
|
17 |
+
msgid "Error processing {}: {}"
|
18 |
+
msgstr "{}の処理中にエラー: {}"
|
19 |
+
|
20 |
+
msgid "Saved blurhash to {}"
|
21 |
+
msgstr "blurhashを{}に保存しました"
|
22 |
+
|
23 |
+
msgid "Invalid image format: {}"
|
24 |
+
msgstr "無効な画像形式です: {}"
|
utils/locales/ja/LC_MESSAGES/extract_description.po
ADDED
@@ -0,0 +1,30 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
msgid ""
|
2 |
+
msgstr ""
|
3 |
+
"Project-Id-Version: extract_description\n"
|
4 |
+
"Report-Msgid-Bugs-To: \n"
|
5 |
+
"POT-Creation-Date: 2024-03-21 12:00+0000\n"
|
6 |
+
"Language: ja\n"
|
7 |
+
"MIME-Version: 1.0\n"
|
8 |
+
"Content-Type: text/plain; charset=UTF-8\n"
|
9 |
+
"Content-Transfer-Encoding: 8bit\n"
|
10 |
+
|
11 |
+
msgid "Processing directory: {}"
|
12 |
+
msgstr "ディレクトリを処理中:{}"
|
13 |
+
|
14 |
+
msgid "Found {} JSON files"
|
15 |
+
msgstr "JSONファイルが{}個見つかりました"
|
16 |
+
|
17 |
+
msgid "Processing {}"
|
18 |
+
msgstr "{}を処理中"
|
19 |
+
|
20 |
+
msgid "Error reading JSON file {}: {}"
|
21 |
+
msgstr "JSONファイル{}の読み込み中にエラー:{}"
|
22 |
+
|
23 |
+
msgid "No 'description' field found in {}"
|
24 |
+
msgstr "{}に'description'フィールドが見つかりません"
|
25 |
+
|
26 |
+
msgid "Wrote caption to {}"
|
27 |
+
msgstr "キャプションを{}に書き込みました"
|
28 |
+
|
29 |
+
msgid "Error writing caption file {}: {}"
|
30 |
+
msgstr "キャプションファイル{}の書き込み中にエラー:{}"
|
utils/locales/ja/LC_MESSAGES/img_remove_white_border.po
ADDED
@@ -0,0 +1,24 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
msgid ""
|
2 |
+
msgstr ""
|
3 |
+
"Project-Id-Version: img_remove_white_border\n"
|
4 |
+
"Report-Msgid-Bugs-To: \n"
|
5 |
+
"POT-Creation-Date: 2024-03-21 12:00+0000\n"
|
6 |
+
"Language: ja\n"
|
7 |
+
"MIME-Version: 1.0\n"
|
8 |
+
"Content-Type: text/plain; charset=UTF-8\n"
|
9 |
+
"Content-Transfer-Encoding: 8bit\n"
|
10 |
+
|
11 |
+
msgid "Processing image: {}"
|
12 |
+
msgstr "画像を処理中: {}"
|
13 |
+
|
14 |
+
msgid "Removed white border from {}"
|
15 |
+
msgstr "{}から白い境界を削除しました"
|
16 |
+
|
17 |
+
msgid "No white border found in {}"
|
18 |
+
msgstr "{}に白い境界が見つかりません"
|
19 |
+
|
20 |
+
msgid "Error processing image {}: {}"
|
21 |
+
msgstr "画像{}の処理中にエラー: {}"
|
22 |
+
|
23 |
+
msgid "Saved processed image to {}"
|
24 |
+
msgstr "処理済み画像を{}に保存しました"
|
utils/locales/ja/LC_MESSAGES/keyframe.po
ADDED
@@ -0,0 +1,27 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
msgid ""
|
2 |
+
msgstr ""
|
3 |
+
"Project-Id-Version: keyframe\n"
|
4 |
+
"Report-Msgid-Bugs-To: \n"
|
5 |
+
"POT-Creation-Date: 2024-03-21 12:00+0000\n"
|
6 |
+
"Language: ja\n"
|
7 |
+
"MIME-Version: 1.0\n"
|
8 |
+
"Content-Type: text/plain; charset=UTF-8\n"
|
9 |
+
"Content-Transfer-Encoding: 8bit\n"
|
10 |
+
|
11 |
+
msgid "Extracting keyframes from {}"
|
12 |
+
msgstr "{}からキーフレームを抽出中"
|
13 |
+
|
14 |
+
msgid "Output directory: {}"
|
15 |
+
msgstr "出力ディレクトリ: {}"
|
16 |
+
|
17 |
+
msgid "Extracted {} keyframes"
|
18 |
+
msgstr "{}個のキーフレームを抽出しました"
|
19 |
+
|
20 |
+
msgid "Error during extraction: {}"
|
21 |
+
msgstr "抽出中にエラーが発生: {}"
|
22 |
+
|
23 |
+
msgid "Processing video file..."
|
24 |
+
msgstr "動画ファイルを処理中..."
|
25 |
+
|
26 |
+
msgid "Keyframe extraction complete"
|
27 |
+
msgstr "キーフレーム抽出が完了しました"
|
utils/locales/ja/LC_MESSAGES/nocap.po
ADDED
@@ -0,0 +1,24 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
msgid ""
|
2 |
+
msgstr ""
|
3 |
+
"Project-Id-Version: nocap\n"
|
4 |
+
"Report-Msgid-Bugs-To: \n"
|
5 |
+
"POT-Creation-Date: 2024-03-21 12:00+0000\n"
|
6 |
+
"Language: ja\n"
|
7 |
+
"MIME-Version: 1.0\n"
|
8 |
+
"Content-Type: text/plain; charset=UTF-8\n"
|
9 |
+
"Content-Transfer-Encoding: 8bit\n"
|
10 |
+
|
11 |
+
msgid "Checking for images without captions in {}"
|
12 |
+
msgstr "{}内のキャプションのない画像を確認中"
|
13 |
+
|
14 |
+
msgid "Found image without caption: {}"
|
15 |
+
msgstr "キャプションのない画像が見つかりました: {}"
|
16 |
+
|
17 |
+
msgid "All images have captions in {}"
|
18 |
+
msgstr "{}内の全ての画像にキャプションがあります"
|
19 |
+
|
20 |
+
msgid "Error accessing directory {}: {}"
|
21 |
+
msgstr "ディレクトリ{}へのアクセス中にエラーが発生: {}"
|
22 |
+
|
23 |
+
msgid "Debug mode enabled"
|
24 |
+
msgstr "デバッグモードが有効です"
|
utils/locales/ja/LC_MESSAGES/remove_extra_whitespace.po
ADDED
@@ -0,0 +1,18 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
msgid ""
|
2 |
+
msgstr ""
|
3 |
+
"Project-Id-Version: remove_extra_whitespace\n"
|
4 |
+
"Report-Msgid-Bugs-To: \n"
|
5 |
+
"POT-Creation-Date: 2024-03-21 12:00+0000\n"
|
6 |
+
"Language: ja\n"
|
7 |
+
"MIME-Version: 1.0\n"
|
8 |
+
"Content-Type: text/plain; charset=UTF-8\n"
|
9 |
+
"Content-Transfer-Encoding: 8bit\n"
|
10 |
+
|
11 |
+
msgid "Processing file: {}"
|
12 |
+
msgstr "ファイルを処理中:{}"
|
13 |
+
|
14 |
+
msgid "Error processing file {}: {}"
|
15 |
+
msgstr "ファイル{}の処理中にエラー:{}"
|
16 |
+
|
17 |
+
msgid "Processing directory: {}"
|
18 |
+
msgstr "ディレクトリを処理中:{}"
|
utils/locales/ja/LC_MESSAGES/remove_grandfathered.po
ADDED
@@ -0,0 +1,18 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
msgid ""
|
2 |
+
msgstr ""
|
3 |
+
"Project-Id-Version: remove_grandfathered\n"
|
4 |
+
"Report-Msgid-Bugs-To: \n"
|
5 |
+
"POT-Creation-Date: 2024-03-21 12:00+0000\n"
|
6 |
+
"Language: ja\n"
|
7 |
+
"MIME-Version: 1.0\n"
|
8 |
+
"Content-Type: text/plain; charset=UTF-8\n"
|
9 |
+
"Content-Transfer-Encoding: 8bit\n"
|
10 |
+
|
11 |
+
msgid "Processing file: {}"
|
12 |
+
msgstr "ファイルを処理中: {}"
|
13 |
+
|
14 |
+
msgid "Removed {} instances of grandfathered content from {}"
|
15 |
+
msgstr "{}から{}個の古い内容を削除しました"
|
16 |
+
|
17 |
+
msgid "Error processing file {}: {}"
|
18 |
+
msgstr "ファイル{}の処理中にエラーが発生しました: {}"
|
utils/locales/ja/LC_MESSAGES/shortcode.po
ADDED
@@ -0,0 +1,27 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
msgid ""
|
2 |
+
msgstr ""
|
3 |
+
"Project-Id-Version: shortcode\n"
|
4 |
+
"Report-Msgid-Bugs-To: \n"
|
5 |
+
"POT-Creation-Date: 2024-03-21 12:00+0000\n"
|
6 |
+
"Language: ja\n"
|
7 |
+
"MIME-Version: 1.0\n"
|
8 |
+
"Content-Type: text/plain; charset=UTF-8\n"
|
9 |
+
"Content-Transfer-Encoding: 8bit\n"
|
10 |
+
|
11 |
+
msgid "Error reading JSON file {}: {}"
|
12 |
+
msgstr "JSONファイル{}の読み込み中にエラー: {}"
|
13 |
+
|
14 |
+
msgid "Generated shortcode for {}"
|
15 |
+
msgstr "{}のショートコードを生成しました"
|
16 |
+
|
17 |
+
msgid "Saved shortcode to {}"
|
18 |
+
msgstr "ショートコードを{}に保存しました"
|
19 |
+
|
20 |
+
msgid "Processing JSON file: {}"
|
21 |
+
msgstr "JSONファイルを処理中: {}"
|
22 |
+
|
23 |
+
msgid "Invalid JSON format in {}"
|
24 |
+
msgstr "{}のJSONフォーマットが無効です"
|
25 |
+
|
26 |
+
msgid "Required field missing in {}: {}"
|
27 |
+
msgstr "{}に必須フィールドがありません: {}"
|
utils/locales/ja/LC_MESSAGES/tags2txt_safe.po
ADDED
@@ -0,0 +1,18 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
msgid ""
|
2 |
+
msgstr ""
|
3 |
+
"Project-Id-Version: tags2txt_safe\n"
|
4 |
+
"Report-Msgid-Bugs-To: \n"
|
5 |
+
"POT-Creation-Date: 2024-03-21 12:00+0000\n"
|
6 |
+
"Language: ja\n"
|
7 |
+
"MIME-Version: 1.0\n"
|
8 |
+
"Content-Type: text/plain; charset=UTF-8\n"
|
9 |
+
"Content-Transfer-Encoding: 8bit\n"
|
10 |
+
|
11 |
+
msgid "Skipping {}: {} already exists"
|
12 |
+
msgstr "{}をスキップ: {}は既に存在します"
|
13 |
+
|
14 |
+
msgid "Would copy {} to {}"
|
15 |
+
msgstr "{}を{}にコピーします"
|
16 |
+
|
17 |
+
msgid "Copied {} to {}"
|
18 |
+
msgstr "{}を{}にコピーしました"
|
utils/locales/ja/LC_MESSAGES/txt2e621.po
ADDED
@@ -0,0 +1,15 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
msgid ""
|
2 |
+
msgstr ""
|
3 |
+
"Project-Id-Version: txt2e621\n"
|
4 |
+
"Report-Msgid-Bugs-To: \n"
|
5 |
+
"POT-Creation-Date: 2024-03-21 12:00+0000\n"
|
6 |
+
"Language: ja\n"
|
7 |
+
"MIME-Version: 1.0\n"
|
8 |
+
"Content-Type: text/plain; charset=UTF-8\n"
|
9 |
+
"Content-Transfer-Encoding: 8bit\n"
|
10 |
+
|
11 |
+
msgid "Enter the target directory (leave blank for current directory): "
|
12 |
+
msgstr "対象ディレクトリを入力してください(空白の場合は現在のディレクトリ):"
|
13 |
+
|
14 |
+
msgid "Renamed {} to {}"
|
15 |
+
msgstr "{}を{}に名前変更しました"
|
utils/locales/ja/LC_MESSAGES/txt2emoji.po
ADDED
@@ -0,0 +1,27 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
msgid ""
|
2 |
+
msgstr ""
|
3 |
+
"Project-Id-Version: txt2emoji\n"
|
4 |
+
"Report-Msgid-Bugs-To: \n"
|
5 |
+
"POT-Creation-Date: 2024-03-21 12:00+0000\n"
|
6 |
+
"Language: ja\n"
|
7 |
+
"MIME-Version: 1.0\n"
|
8 |
+
"Content-Type: text/plain; charset=UTF-8\n"
|
9 |
+
"Content-Transfer-Encoding: 8bit\n"
|
10 |
+
|
11 |
+
msgid "Enter the target directory (leave blank for current directory): "
|
12 |
+
msgstr "対象ディレクトリを入力してください(空白の場合は現在のディレクトリ):"
|
13 |
+
|
14 |
+
msgid "Processing text: {}"
|
15 |
+
msgstr "テキストを処理中: {}"
|
16 |
+
|
17 |
+
msgid "Generated emojis: {}"
|
18 |
+
msgstr "生成された絵文字: {}"
|
19 |
+
|
20 |
+
msgid "Saved emojis to {}"
|
21 |
+
msgstr "絵文字を{}に保存しました"
|
22 |
+
|
23 |
+
msgid "Error processing {}: {}"
|
24 |
+
msgstr "{}の処理中にエラー: {}"
|
25 |
+
|
26 |
+
msgid "Explanation saved to {}"
|
27 |
+
msgstr "説明を{}に保存しました"
|
utils/locales/ja/LC_MESSAGES/txt2tags.po
ADDED
@@ -0,0 +1,21 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
msgid ""
|
2 |
+
msgstr ""
|
3 |
+
"Project-Id-Version: txt2tags\n"
|
4 |
+
"Report-Msgid-Bugs-To: \n"
|
5 |
+
"POT-Creation-Date: 2024-03-21 12:00+0000\n"
|
6 |
+
"Language: ja\n"
|
7 |
+
"MIME-Version: 1.0\n"
|
8 |
+
"Content-Type: text/plain; charset=UTF-8\n"
|
9 |
+
"Content-Transfer-Encoding: 8bit\n"
|
10 |
+
|
11 |
+
msgid "Enter the target directory (leave blank for current directory): "
|
12 |
+
msgstr "対象ディレクトリを入力してください(空白の場合は現在のディレクトリ):"
|
13 |
+
|
14 |
+
msgid "Renamed {} to {}"
|
15 |
+
msgstr "{}を{}に名前変更しました"
|
16 |
+
|
17 |
+
msgid "Error: Directory {} does not exist"
|
18 |
+
msgstr "エラー: ディレクトリ{}が存在しません"
|
19 |
+
|
20 |
+
msgid "No .txt files found in {}"
|
21 |
+
msgstr "{}に.txtファイルが見つかりません"
|
utils/locales/ja/LC_MESSAGES/yiffdata.po
ADDED
@@ -0,0 +1,24 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
msgid ""
|
2 |
+
msgstr ""
|
3 |
+
"Project-Id-Version: yiffdata\n"
|
4 |
+
"Report-Msgid-Bugs-To: \n"
|
5 |
+
"POT-Creation-Date: 2024-03-21 12:00+0000\n"
|
6 |
+
"Language: ja\n"
|
7 |
+
"MIME-Version: 1.0\n"
|
8 |
+
"Content-Type: text/plain; charset=UTF-8\n"
|
9 |
+
"Content-Transfer-Encoding: 8bit\n"
|
10 |
+
|
11 |
+
msgid "Processing directory: {}"
|
12 |
+
msgstr "ディレクトリを処理中: {}"
|
13 |
+
|
14 |
+
msgid "No blurhash file found for {}"
|
15 |
+
msgstr "{}のblurhashファイルが見つかりません"
|
16 |
+
|
17 |
+
msgid "No caption file found for {}"
|
18 |
+
msgstr "{}のキャプションファイルが見つかりません"
|
19 |
+
|
20 |
+
msgid "Error processing image {}: {}"
|
21 |
+
msgstr "画像{}の処理中にエラーが発生しました: {}"
|
22 |
+
|
23 |
+
msgid "Successfully processed {} and created JSON file"
|
24 |
+
msgstr "{}を処理し、JSONファイルを作成しました"
|
utils/txt2emoji
CHANGED
@@ -20,10 +20,28 @@ from emoji import EMOJI_DATA
|
|
20 |
import argparse
|
21 |
from pathlib import Path
|
22 |
import re
|
|
|
|
|
23 |
|
24 |
# Download required NLTK data (only needed once)
|
25 |
nltk.download('punkt', quiet=True)
|
26 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
27 |
def get_emoji_mapping():
|
28 |
"""Create a mapping of words to emojis."""
|
29 |
emoji_map = {}
|
|
|
20 |
import argparse
|
21 |
from pathlib import Path
|
22 |
import re
|
23 |
+
import locale
|
24 |
+
import gettext
|
25 |
|
26 |
# Download required NLTK data (only needed once)
|
27 |
nltk.download('punkt', quiet=True)
|
28 |
|
29 |
+
def setup_i18n():
|
30 |
+
"""Set up internationalization"""
|
31 |
+
try:
|
32 |
+
locale.setlocale(locale.LC_ALL, '')
|
33 |
+
current_locale = locale.getlocale()[0]
|
34 |
+
locale_path = Path(__file__).parent / 'locales'
|
35 |
+
|
36 |
+
trans = gettext.translation('txt2emoji', locale_path, languages=[current_locale])
|
37 |
+
trans.install()
|
38 |
+
return trans.gettext
|
39 |
+
except:
|
40 |
+
return gettext.gettext
|
41 |
+
|
42 |
+
# Initialize translation
|
43 |
+
_ = setup_i18n()
|
44 |
+
|
45 |
def get_emoji_mapping():
|
46 |
"""Create a mapping of words to emojis."""
|
47 |
emoji_map = {}
|