Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
  • 한국 커뮤니티
0

how to run a render in a terminal (mac os x) from a script?

Explorer ,
Mar 15, 2022 Mar 15, 2022

Hello.

I have a script that generates commands for rendering in the terminal. and writes them to a file. if I copy them and paste them into the terminal, then everything works.
how can I run a render from a js script using this file, or the commands that the script generates?

TOPICS
How to , Scripting
554
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines

correct answers 1 Correct answer

Community Expert , Mar 17, 2022 Mar 17, 2022

you could run something like this:

system.callSystem("chmod u+x "+myFile.fsName)

to change the permission of file myFile to be executable

Translate
LEGEND ,
Mar 15, 2022 Mar 15, 2022

Without actually seeing your script code, nobody can give you a satisfying answer. Generally, though, you should have no problem getting this to work with using the .execute() functions and such.

 

Mylenium

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
Mar 15, 2022 Mar 15, 2022

this does not apply to the code of the script itself. there's nothing interesting there. it is simply written to the command file for rendering. that's it. a file appears on the disk in which these commands are stored. you just need to run it.
on Windows, it is enough to register the bat extension and it can be batFile.execute() and everything will work.
and this won't work on mac os. there it is necessary to give permissions to each file so that it is executable.
I think you can try sending commands directly to system.callSystem(), but I can't figure out how to implement it correctly.
the commands are simple:
"/Applications/Adobe After Effects 2022"/aerender -mp -project "/Users/.../Desktop/2.aep" -sound ON

 

 

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Mar 17, 2022 Mar 17, 2022
LATEST

you could run something like this:

system.callSystem("chmod u+x "+myFile.fsName)

to change the permission of file myFile to be executable

Mathias Möhl - Developer of tools like BeatEdit and Automation Blocks for Premiere Pro and After Effects
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines