[PATCH 1/5] hid.lst is not used any more.
Jan Holesovsky
kendy at suse.cz
Thu May 19 13:04:00 PDT 2011
---
helpcontent2/to-wiki/wikiconv2.py | 21 +--------------------
1 files changed, 1 insertions(+), 20 deletions(-)
diff --git a/helpcontent2/to-wiki/wikiconv2.py b/helpcontent2/to-wiki/wikiconv2.py
index 6a3d766..7d5cc3e 100755
--- a/helpcontent2/to-wiki/wikiconv2.py
+++ b/helpcontent2/to-wiki/wikiconv2.py
@@ -13,9 +13,6 @@ titles = []
# map of id -> localized text
localization_data = {}
-# content of the hid.lst file for easier searching
-hid_lst = {}
-
# to collect a list of pages that will be redirections to the pages with nice
# names
redirects = []
@@ -118,16 +115,6 @@ replace_text_list = \
["$PRODUCTNAME", "{{ProductName}}"]
]
-def load_hid_lst():
- global hid_lst
- hid_lst = {}
- file = codecs.open("helpers/hid.lst", "r", "utf-8")
- for line in file:
- ids = line.strip().split(" ")
- if len(ids) == 2:
- hid_lst[ids[0].upper()] = ids[1]
- file.close()
-
def get_link_filename(link, name):
text = link.strip()
fragment = ''
@@ -397,12 +384,7 @@ class Bookmark(ElementBase):
self.app = parser.current_app_raw
self.target = parser.wiki_page_name
self.authoritative = parser.follow_embed
- if name.find('.uno:') == 0 or name.find('.HelpId:') == 0:
- self.redirect = name
- elif name.upper() in hid_lst:
- self.redirect = hid_lst[name.upper()]
- #else:
- # sys.stderr.write('Unhandled redirect "%s"\n'% name)
+ self.redirect = name
def get_all(self):
global redirects
@@ -1281,7 +1263,6 @@ def convert(generate_redirects, lang, sdf_file):
global images
images = set()
- load_hid_lst()
loadallfiles("alltitles.csv")
if lang != '':
--
1.7.3.1
--=-V1EnKp/ZAFsH3LYVmbTj
Content-Disposition: attachment; filename="0002-Adapt-to-the-translations-repository.patch"
Content-Type: text/x-patch; name="0002-Adapt-to-the-translations-repository.patch"; charset="UTF-8"
Content-Transfer-Encoding: 7bit
More information about the LibreOffice
mailing list