Blob


1 #!/bin/bash
3 PLAN9=${PLAN9:-/usr/local/plan9}
4 bin=$PLAN9/bin
6 file=$1
8 # Blanks are problematic in filenames: just plumb
9 # the file's content.
10 if echo "$file" | grep -q " "
11 then
12 base=$(basename "$file" | sed 's/ /_/g')
13 attr="action=showdata filename=/BadName/$base"
14 cat $file | "$bin/plumb" -i -d edit -a "$attr"
15 else
16 "$bin/plumb" -d edit "$file"
17 fi