Search Members Help

» Welcome Guest
[ Log In :: Register ]

Mini-ITX Boards Sale, Fanless BareBones Mini-ITX, Bootable 1G DSL USBs, 533MHz Fanless PC <-- SALE $200 each!
Get The Official Damn Small Linux Book. DSL Market , Great VPS hosting provided by Tektonic
Pages: (2) </ [1] 2 >/

[ Track this topic :: Email this topic :: Print this topic ]

reply to topic new topic new poll
Topic: Fix for wordview xls2html and pptview, filenames with spaces now work< Next Oldest | Next Newest >
cbagger01 Offline





Group: Members
Posts: 4264
Joined: Oct. 2003
Posted: April 18 2005,03:33 QUOTE

See below for some "diffs" that fix the "can't view a file with a space in the name" problem.

Basically, I just added some hard quotes \' in appropriate places for wordview and added some double quotes in appropraite places for xls2html and pptview

wordview.lua.diff:
Code Sample
17,18c17,18
<     execute('/usr/bin/antiword -p letter ' .. input.value .. ' > '.. input.value .. ".ps")
<     execute('/usr/local/bin/ps2pdf ' .. input.value .. ".ps")
---
>     execute('/usr/bin/antiword -p letter \'' .. input.value .. '\' > \''.. input.value .. ".ps\'")
>     execute('/usr/local/bin/ps2pdf \'' .. input.value .. ".ps\'")
24c24
<     execute('/usr/bin/antiword -p letter ' .. input.value .. ' > '.. input.value .. ".ps")
---
>     execute('/usr/bin/antiword -p letter \'' .. input.value .. '\' > \''.. input.value .. ".ps\'")
64c64
<     execute('/usr/bin/antiword -p letter ' .. input.value .. ' > ' .. workfile)
---
>     execute('/usr/bin/antiword -p letter \'' .. input.value .. '\' > ' .. workfile)



xls2html.sh.diff:
Code Sample
19c19
< xlhtml $source > $html
---
> xlhtml "$source" > $html



pptview.sh.diff:
Code Sample
19c19
< ppthtml $source > $html
---
> ppthtml "$source" > $html


I tested all three and they seem to work fine for me.

Please test and add to a future version of DSL if you agree.
Back to top
Profile PM 
tronik Offline





Group: Members
Posts: 182
Joined: Dec. 2004
Posted: April 18 2005,04:26 QUOTE

I concur. I was going to suggest escaping it and using quotes but never got around to it. Army's had me this weekend.

--------------
-william
atlanta, GA, USA

DSL 1.0+2.4.27/sata : P4 2.4norwood : 512ddr2 : nvgf4ti4200-64 : 128mbLexar Jumpdrive Elite
Back to top
Profile PM WEB 
gunnix
Unregistered






Posted: April 18 2005,10:28 QUOTE

I didn't realize ppthtml and xlshtml scripts had the same "problem".
I looked into the lua script as well but didn't really get it right with only the " quotes , thx cbagger!
Back to top
roberts Offline





Group: Members
Posts: 4983
Joined: Oct. 2003
Posted: April 18 2005,17:08 QUOTE

When I wrote
Quote
Sorry, I don't consider that a bug. But a currently unsupported filename nameing convention primarly used by MS. For now there is a feature called rename file.
It was not because of lack of ability or know how but on principle.

It is kinda like the forest and the trees. These three scripts being the trees and DSL being the forest. If I allow spaces in filenames then given that an OS should be consistent should we not also allow spaces in fileanames everywhere. Given that unix traditionally does not allow spaces in filenames and given the fact that most features have been designed not with "spaces" in mind. Would I be so inclined to review each and every feature of the OS from Klaus's scripts to John's perl scripts, to my bash and flua scripts to insure consistency. Really, I don't have that motivation but instead wish to presue new features and continue the development of DSL and not worry about this. I know my standards may be too high to be not practical. It would not be the first time that I have been told that. But it is something that I think about, especially when my name is associated with DSL. Something to think about. It is OK to tell me that I worry too much that this should be an exception. I just don't want to hear next that the myDSL is broken because it doesn't allow spaces in filenames too, or some other such feature is broken because of this.

Something to think about. Thought you should know my thoughts on this subject.
Back to top
Profile PM WEB 
gunnix
Unregistered






Posted: April 18 2005,19:00 QUOTE

Yea, after reading your point of view, it's best to keep the support of spaces in names out of DSL Roberts. You should keep the high standards. And you won't hear me say anything about it anymore ;)

But those doc files are all full of spaces! :s
Heh I'll just get me a rename tool and let the spaces be replaced by _ ... why didn't I think of that earlier?

grtz
Back to top
9 replies since April 18 2005,03:33 < Next Oldest | Next Newest >

[ Track this topic :: Email this topic :: Print this topic ]

Pages: (2) </ [1] 2 >/
reply to topic new topic new poll
Quick Reply: Fix for wordview xls2html and pptview

Do you wish to enable your signature for this post?
Do you wish to enable emoticons for this post?
Track this topic
View All Emoticons
View iB Code