In elixir code I am looking to change location to a directory and run a script there
File.cd!("/opt/test/", System.cmd("./bin/myscript.sh", []))
The second argument to File.cd! is a function and I thought the System.cmd would satisfy the requirement of being a function but the editor I am using says this statement will never work.
Is there some easier way to change to a directory, and execute a shell script?