handle paths with embedded spaces
This commit is contained in:
parent
699fb34bb0
commit
14194e30d8
@ -1,5 +1,5 @@
|
||||
#!/bin/sh
|
||||
# @(#$Id: rcldjvu,v 1.1 2006-02-03 10:53:34 dockes Exp $ (C) 2005 J.F.Dockes
|
||||
# @(#$Id: rcldjvu,v 1.2 2006-04-04 16:03:28 dockes Exp $ (C) 2005 J.F.Dockes
|
||||
|
||||
# This program is free software; you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
@ -78,7 +78,7 @@ fi
|
||||
# in C/awk \-escaped notation. Awk can only process this in string
|
||||
# constants, so we have a first awk pass to create an awk program to parse
|
||||
# the string as a constant (...). This is not exactly robust or nice
|
||||
title=`djvused $infile -e 'select 1;output-ant' | \
|
||||
title=`djvused "$infile" -e 'select 1;output-ant' | \
|
||||
grep ' (title ' | sed -e 's/^.* (title //' -e 's/)$//' |\
|
||||
awk '
|
||||
{
|
||||
@ -96,7 +96,7 @@ cat <<EOF
|
||||
<pre>
|
||||
EOF
|
||||
|
||||
djvutxt $infile | sed -e 's/[ ][ ]*$//' | \
|
||||
djvutxt "$infile" | sed -e 's/[ ][ ]*$//' | \
|
||||
awk '
|
||||
BEGIN {
|
||||
cont = ""
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
#!/bin/sh
|
||||
# @(#$Id: rclmedia,v 1.1 2006-03-28 09:38:12 dockes Exp $ (C) 2004 J.F.Dockes
|
||||
# @(#$Id: rclmedia,v 1.2 2006-04-04 16:03:28 dockes Exp $ (C) 2004 J.F.Dockes
|
||||
#================================================================
|
||||
# rclmedia
|
||||
# Handle media files for recoll. This currently returns an empty
|
||||
@ -61,7 +61,7 @@ echo '<meta http-equiv="Content-Type" content="text/html;charset=UTF-8">'
|
||||
echo '</head><body>'
|
||||
echo '<pre>'
|
||||
if test X$cmdsok = X1 ; then
|
||||
id3info $infile | \
|
||||
id3info "$infile" | \
|
||||
sed -e 's/</</g' -e 's/&/&/g' -e 's/===.*://' | \
|
||||
grep -v 'Tag information for'
|
||||
fi
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
#!/bin/sh
|
||||
# @(#$Id: rclps,v 1.6 2006-02-03 10:53:35 dockes Exp $ (C) 2004 J.F.Dockes
|
||||
# @(#$Id: rclps,v 1.7 2006-04-04 16:03:28 dockes Exp $ (C) 2004 J.F.Dockes
|
||||
# Parts taken from Estraier:
|
||||
#================================================================
|
||||
# Estraier: a personal full-text search system
|
||||
@ -34,7 +34,7 @@ then
|
||||
fi
|
||||
|
||||
infile="$1"
|
||||
if test X$infile = X- ; then
|
||||
if test "X$infile" = X- ; then
|
||||
cmd=$decoder
|
||||
else
|
||||
cmd="$decoder $1"
|
||||
@ -67,7 +67,7 @@ checkcmds()
|
||||
checkcmds $decoder iconv awk
|
||||
|
||||
# check the input file existence
|
||||
if test X$infile != X- -a ! -f "$infile"
|
||||
if test "X$infile" != X- -a ! -f "$infile"
|
||||
then
|
||||
printf '%s: %s: no such file\n' "$progname" "$infile"
|
||||
exit 1
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
#!/bin/sh
|
||||
# @(#$Id: rclsoff,v 1.5 2006-01-27 13:37:31 dockes Exp $ (C) 2004 J.F.Dockes
|
||||
# @(#$Id: rclsoff,v 1.6 2006-04-04 16:03:28 dockes Exp $ (C) 2004 J.F.Dockes
|
||||
# Parts taken from Estraier:
|
||||
#================================================================
|
||||
# Estraier: a personal full-text search system
|
||||
@ -84,7 +84,7 @@ cleanup()
|
||||
trap cleanup EXIT SIGHUP SIGQUIT SIGINT SIGTERM
|
||||
|
||||
# Unzip the input file and change to the unzipped directory
|
||||
unzip -q -d $tmpdir/rclsofftmp $infile
|
||||
unzip -q -d $tmpdir/rclsofftmp "$infile"
|
||||
cd $tmpdir/rclsofftmp
|
||||
|
||||
# Note: there can be newlines inside the description field, we don't want
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user