Archi Forum

Archi Plug-ins => jArchi => Topic started by: Iver on April 16, 2021, 03:10:56 AM

Title: How can I write to a file that I specify programmatically?
Post by: Iver on April 16, 2021, 03:10:56 AM
Hi,

I know how to write to a file that I specify using window.promptSaveFile(...), but I would like to run a script from the ACLI in which the file path and name is specified in the script itself or passed as an argument to the script (via the ACLI, as documented in the wiki). 

I can't seem to figure out how to open such a file in a jArchi script.  How can I do this?

Regards,

Iver
Title: Re: How can I write to a file that I specify programmatically?
Post by: Jean-Baptiste Sarrodie on April 16, 2021, 08:30:24 AM
Hi,

You can use this piece of code: https://raw.githubusercontent.com/archi-contribs/jarchi-community-script-pack/main/Export%20To/Single-page%20HTML%20Export/libs/nashorn-polyfills.js

Regards,

JB