- #Bash script send growl notification full
- #Bash script send growl notification mac
- #Bash script send growl notification windows
#Bash script send growl notification mac
Both of these edits are to the “sudoers" file, and that is accessed by typing “visudo” as the root user from the terminal or ssh (this is the same in OS X, if you’re wondering, but you don’t need to be root to sleep a Mac from the command line). Since you don’t want to render as root, you’ll need to do two things to get that portion of the script working for normal users: set up your user with sudo (do as root) permissions and disable the prompt for permission to run the pm-suspend command with sudo (you won’t be around when it pops up to ask for permission to do that at the end of the render). Linux being Linux, and because criminal masterminds love nothing more than to maliciously put computers to sleep, you have to be root to sleep the machine from the command line. To sleep my machines, regardless of platform, I just type "sm" in the terminal or over ssh. Since retyping all of these sleep commands gets tedious and remembering them is worse, look into making an alias to it and for other long commands or to binary paths you may forget. Here is an outline of the Cygwin power management commands. You can set up the Cygwin PATH variable for the Render binary in the same way as you do for Linux or OS X, since all three use the BASH shell by default. cygdrive/c/Program\ Files/Autodesk/Maya2015/bin/Render -r mr -s 1 -e 24 /path/to/file.mb
%windir%\\system32\\rundll32.exe PowrProf.dll, SetSuspendState 0,1,0 Render -r mr -s 1 -e 24 C:\path\to\file.mb (command prompt syntax) Osascript -e 'tell application "Finder" to sleep' So if I’m rendering the first 24 frames of an animation for mental ray for Maya on any given platform and want to sleep the machine at the end, my executable plain text batch file would look like this: To get your host machine to sleep at the end of the batch, you simply add the sleep command for your respective OS at the end of the executable batch script. If you are using a renderer like V-Ray or mental ray that is configured to automatically use the referenced muscle, then these command renders will use all those machines as well.
#Bash script send growl notification windows
There is a good guide for Maya and Windows here, and that also applies to other applications, like Cinema 4D.īasically, the idea is the same for all: you use a PATH variable to point your system to the folder with the binary that does the rendering, open a terminal/command prompt, and type Render /path/to/yourfile.mb and you’re rendering.
#Bash script send growl notification full
If you’re looking to get up and running with command line renders without having to point to the long full path (/Applications/Autodesk/Maya2014/Maya.app/Contents/MacOS/Render or "/Applications/CINEMA 4D R12/CINEMA 4D.app/Contents/MacOS/CINEMA 4D"įor example), I wrote a guide for OS X here, and that setup workflow also applies to other applications other than Maya. …and to put all the machines to sleep once the jobs are done so I use as little energy as possible. Since I do my batch renders from a command line script-actually, I cheat a little, and my V-Ray Tuner script writes them for me-I like to add a few things to the batch script to give me added notifications via Growl. It's also a good example of how you can get a render queue manager feature without a render manager.
You can skip this portion if you don't intend to do any power management, but this could be something worth doing after you are set up with networked renders. Advanced setup: Sleeping and waking up remotely