]> git.phdru.name Git - phdru.name/phdru.name.git/blobdiff - dotfiles2html/dotfiles2html.py
Feat(dotfiles2html.py): Process `mc.ext.ini`
[phdru.name/phdru.name.git] / dotfiles2html / dotfiles2html.py
index a5065cdb16d3ff9f89ea73287ffa7ab266c10909..af0076e9c38d4fd6059de305d0366006ac155dc1 100755 (executable)
@@ -21,7 +21,7 @@ home_file_types = (
      ("gitconfig", "gitconfig"), ("vimrc", "vim"),
 )
 
-mc_file_types = (("mc.ext", "conf"), ("menu", "conf"))
+mc_file_types = (("mc.ext", "conf"), ("mc.ext.i", "conf"), ("menu", "conf"))
 
 python_file_types = (
     ("init.py", "python"),
@@ -83,7 +83,7 @@ def process_dotfile(i, fname, ftype, file_types):
 
     text = re.sub('cgmem_nice \\d+ ', '', text)
 
-    if fname in ('mailcap', 'mc.ext', 'menu'):
+    if fname in ('mailcap', 'mc.ext', 'mc.ext.ini', 'menu'):
         text = text.replace('mplay', 'mplayer')
         text = text.replace('mplayerer', 'mplayer')
         if fname == 'mailcap':
@@ -136,6 +136,11 @@ def process_files(file_types):
         if not os.path.exists(fname):
             continue
 
+        if fname == 'mc.ext.i' and not os.path.exists('mc.ext.ini'):
+            os.rename('mc.ext.i', 'mc.ext.ini')
+        if fname == 'mc.ext.i':
+            fname = 'mc.ext.ini'
+
         process_dotfile(i, fname, ftype, file_types)