~ubuntu-branches/ubuntu/natty/moin/natty-updates

« back to all changes in this revision

Viewing changes to MoinMoin/filter/application_msword.py

  • Committer: Bazaar Package Importer
  • Author(s): Jonas Smedegaard
  • Date: 2008-06-22 21:17:13 UTC
  • mto: This revision was merged to the branch mainline in revision 18.
  • Revision ID: james.westby@ubuntu.com-20080622211713-inlv5k4eifxckelr
ImportĀ upstreamĀ versionĀ 1.7.0

Show diffs side-by-side

added added

removed removed

Lines of Context:
4
4
 
5
5
    Depends on: antiword command from antiword package
6
6
 
7
 
    @copyright: 2006-2008 MoinMoin:ThomasWaldmann
 
7
    @copyright: 2006 MoinMoin:ThomasWaldmann
8
8
    @license: GNU GPL, see COPYING for details.
9
9
"""
10
10
 
11
 
import os
12
 
 
13
11
from MoinMoin.filter import execfilter
14
12
 
15
13
def execute(indexobj, filename):
16
 
    cmd = "antiword %s"
17
 
    if os.name == 'posix':
18
 
        cmd = "HOME=/tmp " + cmd  # no HOME makes antiword complain (on Linux)
19
 
    return execfilter(cmd, filename)
 
14
    return execfilter("HOME=/tmp antiword '%s'", filename) # no HOME makes antiword complain
20
15