summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/scripts/lilyglyphs
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2013-10-02 22:18:36 +0000
committerKarl Berry <karl@freefriends.org>2013-10-02 22:18:36 +0000
commit92ad4fed0cb600ce55fffacc7e982fbaf955fc44 (patch)
treef28e49ec646b60fb99d783afd1a2bc68b07bf835 /Master/texmf-dist/scripts/lilyglyphs
parent3bf8ee8a87097403ef040c9a3c4ee0f3866eb2cd (diff)
lilyglyphs (2oct13)
git-svn-id: svn://tug.org/texlive/trunk@31814 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/scripts/lilyglyphs')
-rwxr-xr-xMaster/texmf-dist/scripts/lilyglyphs/lily-glyph-commands.py31
-rwxr-xr-xMaster/texmf-dist/scripts/lilyglyphs/lily-image-commands.py31
-rwxr-xr-xMaster/texmf-dist/scripts/lilyglyphs/lily-rebuild-pdfs.py31
-rwxr-xr-xMaster/texmf-dist/scripts/lilyglyphs/lilyglyphs_common.py2
4 files changed, 5 insertions, 90 deletions
diff --git a/Master/texmf-dist/scripts/lilyglyphs/lily-glyph-commands.py b/Master/texmf-dist/scripts/lilyglyphs/lily-glyph-commands.py
index ad6429338db..691652ece6d 100755
--- a/Master/texmf-dist/scripts/lilyglyphs/lily-glyph-commands.py
+++ b/Master/texmf-dist/scripts/lilyglyphs/lily-glyph-commands.py
@@ -40,36 +40,7 @@
# #
# ########################################################################
-import os, sys, argparse
-
-# import common library, depending on its location
-scr_path, scr_name = os.path.split(sys.argv[0])
-if not 'lilyglyphs_common.py' in os.listdir(scr_path):
- # the library is not in the same dir as the script
- # first check if we're in a CTAN archive directory structure
- libpath = os.path.normpath(os.path.join(scr_path, '..', 'lib'))
- if 'lilyglyphs_common.py' in os.listdir(libpath):
- # we're in a CTAN archive
- sys.path.append(libpath)
- else:
- # we're not in a CTAN archive
- # so we assume we're in a TeX installation.
- import subprocess
- try:
- # use TeX's kpsewhich tool to locate the library file
- # in the TeX installation
- lib = subprocess.check_output(["kpsewhich",
- "--progname=lilyglyphs",
- "--format=texmfscripts",
- "lilyglyphs_common.py"])
- except:
- print '\nCommon library \"lilyglyphs_common.py\" not found.'
- print 'Please refer to the manual for possible solutions.'
- sys.exit(2)
- # add the found path to Python's search path
- sys.path.append(os.path.split(lib)[0])
-
-import lilyglyphs_common as lg
+import os, sys, argparse, lilyglyphs_common as lg
def main(input_file):
"""Do the main work of the script"""
diff --git a/Master/texmf-dist/scripts/lilyglyphs/lily-image-commands.py b/Master/texmf-dist/scripts/lilyglyphs/lily-image-commands.py
index 4415876aa7b..fce67ad53c2 100755
--- a/Master/texmf-dist/scripts/lilyglyphs/lily-image-commands.py
+++ b/Master/texmf-dist/scripts/lilyglyphs/lily-image-commands.py
@@ -32,36 +32,7 @@
# %
# %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-import os, sys, getopt, datetime, subprocess, argparse
-
-# import common library, depending on its location
-scr_path, scr_name = os.path.split(sys.argv[0])
-if not 'lilyglyphs_common.py' in os.listdir(scr_path):
- # the library is not in the same dir as the script
- # first check if we're in a CTAN archive directory structure
- libpath = os.path.normpath(os.path.join(scr_path, '..', 'lib'))
- if 'lilyglyphs_common.py' in os.listdir(libpath):
- # we're in a CTAN archive
- sys.path.append(libpath)
- else:
- # we're not in a CTAN archive
- # so we assume we're in a TeX installation.
- import subprocess
- try:
- # use TeX's kpsewhich tool to locate the library file
- # in the TeX installation
- lib = subprocess.check_output(["kpsewhich",
- "--progname=lilyglyphs",
- "--format=texmfscripts",
- "lilyglyphs_common.py"])
- except:
- print '\nCommon library \"lilyglyphs_common.py\" not found.'
- print 'Please refer to the manual for possible solutions.'
- sys.exit(2)
- # add the found path to Python's search path
- sys.path.append(os.path.split(lib)[0])
-
-import lilyglyphs_common as lg
+import os, sys, getopt, datetime, subprocess, argparse, lilyglyphs_common as lg
diff --git a/Master/texmf-dist/scripts/lilyglyphs/lily-rebuild-pdfs.py b/Master/texmf-dist/scripts/lilyglyphs/lily-rebuild-pdfs.py
index 77dedfaaffe..b74ab26c6bf 100755
--- a/Master/texmf-dist/scripts/lilyglyphs/lily-rebuild-pdfs.py
+++ b/Master/texmf-dist/scripts/lilyglyphs/lily-rebuild-pdfs.py
@@ -49,36 +49,7 @@
# #
# ########################################################################
-import os, sys, subprocess, argparse
-
-# import common library, depending on its location
-scr_path, scr_name = os.path.split(sys.argv[0])
-if not 'lilyglyphs_common.py' in os.listdir(scr_path):
- # the library is not in the same dir as the script
- # first check if we're in a CTAN archive directory structure
- libpath = os.path.normpath(os.path.join(scr_path, '..', 'lib'))
- if 'lilyglyphs_common.py' in os.listdir(libpath):
- # we're in a CTAN archive
- sys.path.append(libpath)
- else:
- # we're not in a CTAN archive
- # so we assume we're in a TeX installation.
- import subprocess
- try:
- # use TeX's kpsewhich tool to locate the library file
- # in the TeX installation
- lib = subprocess.check_output(["kpsewhich",
- "--progname=lilyglyphs",
- "--format=texmfscripts",
- "lilyglyphs_common.py"])
- except:
- print '\nCommon library \"lilyglyphs_common.py\" not found.'
- print 'Please refer to the manual for possible solutions.'
- sys.exit(2)
- # add the found path to Python's search path
- sys.path.append(os.path.split(lib)[0])
-
-import lilyglyphs_common as lg
+import os, sys, subprocess, argparse, lilyglyphs_common as lg
def main():
diff --git a/Master/texmf-dist/scripts/lilyglyphs/lilyglyphs_common.py b/Master/texmf-dist/scripts/lilyglyphs/lilyglyphs_common.py
index 5e988065d62..8e5d00b90fd 100755
--- a/Master/texmf-dist/scripts/lilyglyphs/lilyglyphs_common.py
+++ b/Master/texmf-dist/scripts/lilyglyphs/lilyglyphs_common.py
@@ -305,6 +305,8 @@ def read_input_file(in_file):
"""Reads the input source file and stores it
in the global variable definitions_file"""
global definitions_file
+
+ in_file = os.path.normpath(in_file)
print 'Read input file ' + in_file