Ñò 4Mc@s(ddkZd„Zdhd„ZdS(iÿÿÿÿNcCs¬t|ƒtjo|idƒ}n|idƒo|iddƒn|idƒdjo d|dS|idƒdjo d|dSd|id|ƒdSdS(s8 quote a string so that it can be passed as a parameter sutf-8s\s\\t'it"N(ttypetunicodetencodet startswithtreplacetfind(tstringtapos((s>/home/sa3ruby/intertwingly.net/code/venus/planet/shell/xslt.pytquotes  cCsîy1ddk}ddk}|i|ƒ}d}Wn d}nXd}|o¦|i|ƒ} |i| ƒ} x.|iƒD] } t|| ddƒ|| %st (tPopentPIPEtxsltproct-tstdintstdouttstderr($tlibxml2tlibxslttparseDoctNonet parseFiletparseStylesheetDoctkeysR tapplyStylesheettsaveResultToFilenamet serializetfreeStylesheettfreeDoctwarningsthasattrR tRuntimeWarningtosttmpnamtopentwritetclosetitemsRtsystemtjointunlinktsyst subprocessRRtsumt communicatetplanettloggerterror(tscripttdoct output_filetoptionsRRtdomtdocfiletresulttstyledoctstyletkeytoutputR"tfiletcmdoptstvalueR.RRt_[1]tprocRR2((s>/home/sa3ruby/intertwingly.net/code/venus/planet/shell/xslt.pytrunsd           ,#   5 (R%R RRE(((s>/home/sa3ruby/intertwingly.net/code/venus/planet/shell/xslt.pyts