Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings
This repository was archived by the owner on Sep 2, 2018. It is now read-only.

Commit3765d1d

Browse files
committed
Update usage message
* Update argument naming* Add exit against wrong arguments input
1 parentd9d9612 commit3765d1d

File tree

1 file changed

+7
-3
lines changed

1 file changed

+7
-3
lines changed

‎scripts/fix_diffs.py

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -96,13 +96,17 @@ def main(fp, original_po_commit='HEAD'):
9696
importsys
9797

9898
iflen(sys.argv)<2:
99-
print('Usage: python fix_diffs.py <po_file_path> <original_po_file_commit_hash>')
99+
print('Usage:')
100+
print('\tpython fix_diffs.py <po_file_path> [<original_po_file_commit>]')
101+
print('Option:')
102+
print('\t<original_po_file_commit>: The original .po file(s) commit record (default to HEAD).')
103+
sys.exit(1)
100104

101105
fp='./'+sys.argv[1]
102106
output_lines=None
103107
iflen(sys.argv)==3:
104-
original_hash=sys.argv[2]
105-
output_lines=main(fp,original_hash)
108+
original_commit=sys.argv[2]
109+
output_lines=main(fp,original_commit)
106110
else:
107111
output_lines=main(fp)
108112

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp