Re: python script result

Gregory Pittman <gpittman-s/[email protected]>
Newsgroups gmane.comp.graphics.scribus
Message-ID <[email protected]>
On 4/20/21 5:15 PM, JLuc wrote:
> Hello,
> 
> I'd like to use the page count of a document in a shell script (linux)
> A python script can access that count with `scribus.pageCount()`
> 
> How can scribus script can output this as a string,
> so it's used in a shell script afterward ?
> 

Hi JLuc,

I would say just experiment. 
If a Scribus script writes to a file, what does a shell script say when it reads the file?
You could write the python so that it saves str(value), though when the shell script reads the file, that may not make any difference.
On the other hand, when python reads a file, it reads numbers as strings, so you have to convert to use them as a number in python.

Greg


___
Scribus Mailing List: [email protected]
Edit your options or unsubscribe:
http://lists.scribus.net/mailman/listinfo/scribus
See also:
http://wiki.scribus.net
http://forums.scribus.net
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.