Execute commandline call from automation chaiin

I'm looking for a way to execute commandline calls within an automation chain for custom binary transformations. Can this be achieved with Automation Scripting the best solution? Thanks in advance for your help.

0 votes

0 answers



By "commandline calls", do you mean server terminal commands, like:

> echo hello
> ls
> pwd



yes, I need to execute server terminal commands. Do the "Scripting" options allow that by default?

As written in the page about Automation Scripting:

> Automation Scripting is a Nuxeo module which provides ability to create and contribute Automation chain/operation in JavaScript.

So I'm afraid it is not what you are looking for.

There is also the Context.RunScript operation, but it is to manipulate the context variables with a script, not to run shell commands.

A solution would be to create your own Nuxeo operation where you run your shell commands with something like this:

Process p = Runtime.getRuntime().exec("shell command")

You can also set the shell command as a operation parameter.