Running a script
To run a Gushio script pass the script to the gushio
executable. If your script needs arguments and/or options, you
can pass them after the script path.
gushio path/to/script_file.js arg1 arg2 --option1 foo --option2 bar baz bau
You can also run remote scripts directly: if the script path is a URL, the gushio
executable automatically retrieves
the remote code before running it.
On Linux and macOS you can also run the script directly:
- Add the shabang to the script (
#!/usr/bin/gushio
or#!/usr/bin/env gushio
) - Make the script executable
chmod +x path/to/script_file.js
- Run the script
path/to/script_file.js arg1 arg2 --option1 foo --option2 bar baz bau
Gushio flags
Gushio can receive options before the script argument. The following options are available:
-v
,--verbose
enable verbose logging (also available by settingGUSHIO_VERBOSE
environment variable).-f <folder>
,--gushio-folder <folder>
change gushio cache folder (also available by settingGUSHIO_FOLDER
environment variable). The default value is the.gushio
folder in the user home directory.-c
,--clean-run
clear gushio cache folder before running the script (dependencies will be re-downloaded).