diff options
author | Michael Olbrich <m.olbrich@pengutronix.de> | 2014-03-21 08:37:52 +0100 |
---|---|---|
committer | Michael Olbrich <m.olbrich@pengutronix.de> | 2014-03-21 08:38:04 +0100 |
commit | 11e4d3ed5eb8a2064372104a9501985299b3419b (patch) | |
tree | 75bf01905549b513b7bdd3345ec559bf514b31bd /bin | |
parent | ef91050441f5ba8b4c768aa69b50a2c93e6a42c8 (diff) | |
download | ptxdist-11e4d3ed5eb8a2064372104a9501985299b3419b.tar.gz ptxdist-11e4d3ed5eb8a2064372104a9501985299b3419b.tar.xz |
ptxdist: fix logfile fold marker
Signed-off-by: Michael Olbrich <m.olbrich@pengutronix.de>
Diffstat (limited to 'bin')
-rwxr-xr-x | bin/ptxdist | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/bin/ptxdist b/bin/ptxdist index f89456a62..d83d98dde 100755 --- a/bin/ptxdist +++ b/bin/ptxdist @@ -2391,6 +2391,10 @@ setup_path() { # setup_logfile() { + if [ -n "${PTX_LOGFILE}" ]; then + # we were already here + return + fi PTX_LOGFILE="${PTXDIST_PLATFORMDIR}/logfile" local logdir="${PTX_LOGFILE%/*}" @@ -2411,10 +2415,10 @@ setup_logfile() if [ \! -e "${PTX_LOGFILE}" ]; then # let emacs outline mode be compatible to vi's fold mode - echo -e "# -*- mode:outline; outline-regexp:\"{""{{\" -*-\n" > "${PTX_LOGFILE}" + echo "# -*- mode:outline; outline-regexp:\"{""{{\" -*-" > "${PTX_LOGFILE}" # help vim to recognise the fold markers and expand the first level of folding # which in fact is the Emacs setting above - echo "# vim: set fdm=marker fdl=1:" > "${PTX_LOGFILE}" + echo -e "# vim: set fdm=marker fdl=1:\n" >> "${PTX_LOGFILE}" fi # |