projects
/
platform
/
upstream
/
libpinyin.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
8f6d328
)
refine python code
author
Peng Wu
<alexepico@gmail.com>
Thu, 15 Dec 2011 03:06:08 +0000
(11:06 +0800)
committer
Peng Wu
<alexepico@gmail.com>
Thu, 15 Dec 2011 03:06:08 +0000
(11:06 +0800)
scripts/chewing_enum.h.in
patch
|
blob
|
history
scripts/chewing_table.h.in
patch
|
blob
|
history
scripts/double_pinyin_table.h.in
patch
|
blob
|
history
scripts/pinyin_parser_table.h.in
patch
|
blob
|
history
scripts/utils.py
patch
|
blob
|
history
diff --git
a/scripts/chewing_enum.h.in
b/scripts/chewing_enum.h.in
index
7280b65
..
46072df
100644
(file)
--- a/
scripts/chewing_enum.h.in
+++ b/
scripts/chewing_enum.h.in
@@
-1,6
+1,3
@@
-/* This file is generated by python scripts. Don't edit this file directly.
- */
-
#ifndef CHEWING_ENUM_H
#define CHEWING_ENUM_H
diff --git
a/scripts/chewing_table.h.in
b/scripts/chewing_table.h.in
index
ac01a3a
..
16a05b7
100644
(file)
--- a/
scripts/chewing_table.h.in
+++ b/
scripts/chewing_table.h.in
@@
-1,6
+1,3
@@
-/* This file is generated by python scripts. Don't edit this file directly.
- */
-
#ifndef CHEWING_TABLE_H
#define CHEWING_TABLE_H
diff --git
a/scripts/double_pinyin_table.h.in
b/scripts/double_pinyin_table.h.in
index
7ad1abc
..
15a8ee9
100644
(file)
--- a/
scripts/double_pinyin_table.h.in
+++ b/
scripts/double_pinyin_table.h.in
@@
-1,6
+1,3
@@
-/* This file is generated by python scripts. Don't edit this file directly.
- */
-
#ifndef DOUBLE_PINYIN_TABLE_H
#define DOUBLE_PINYIN_TABLE_H
diff --git
a/scripts/pinyin_parser_table.h.in
b/scripts/pinyin_parser_table.h.in
index
4af0b4b
..
17f5615
100644
(file)
--- a/
scripts/pinyin_parser_table.h.in
+++ b/
scripts/pinyin_parser_table.h.in
@@
-1,6
+1,3
@@
-/* This file is generated by python scripts. Don't edit this file directly.
- */
-
#ifndef PINYIN_PARSER_TABLE_H
#define PINYIN_PARSER_TABLE_H
diff --git
a/scripts/utils.py
b/scripts/utils.py
index
77eecbe
..
391e54f
100644
(file)
--- a/
scripts/utils.py
+++ b/
scripts/utils.py
@@
-22,8
+22,13
@@
import os
+header = '''/* This file is generated by python scripts. Don't edit this file directly.
+ */
+'''
+
def expand_file(filename, get_table_content):
infile = open(filename, "r")
+ print(header)
for line in infile.readlines():
line = line.rstrip(os.linesep)
if len(line) < 3 :