In case others would like to know, I found the solution which was simply to add the binary path to $PATH in /etc/bash/bashrc export PATH=$PATH:/usr/local/ffmpeg-3.1.3-64bit-static/
I can now launch ffmpeg from a bash script, for example, just by adding "ffmpeg" with no need to source the full path or assign it to a variable within the script. Pretty straightforward stuff... Cheers, Michael On 30 September 2016 at 10:41, Michael Garrett <[email protected]> wrote: > Hi Chris, > > Thanks, I've checked the first link before (I'm on Linux). I already tried > alias expansion, but will try again. > > When I say "alias", I guess I mean any variable that can be recalled > between logins. So if aliases are specifically for .bashrc then a variable > somewhere will hopefully do the trick. > > Michael > > > On Friday, September 30, 2016, christoph manz <[email protected]> wrote: > >> hi Michael, >> >> my unix skills are not too great either, but got curious and it seems to >> me that aliases are not expanded in non-interactive shell sessions. these >> links might be worth a read: >> >> http://stackoverflow.com/questions/1615877/why-aliases-in-a- >> non-interactive-bash-shell-do-not-work >> >> http://superuser.com/questions/386345/what-is-the-correct-wa >> y-to-alias-applications-in-os-x-through-bash >> >> bests >> chris >> >> >> >> >> On 9/29/16 at 12:03 AM, [email protected] (Michael Garrett) wrote: >> >> Does anyone have a solution they can share about how to get an alias >>> working in a bash script? In unix nomenclature, I mean an alias to a >>> binary >>> (such as nuke, ffmpeg, whatever) that will execute in a non-interactive >>> non-login shell context. >>> >>> My unix skills are not the greatest, and googling has not yielded a >>> result >>> that works for me. >>> >>> I thought initially my aliases would work in /etc/bash.bashrc since they >>> are available to all users, but it's ignored by the bash script. >>> >>> My current solution has been to add the path to the binary directly to >>> the >>> script, but it would obviously be better to abstract it out. Is there any >>> way to add a C-style "include" in the script header, and where would I >>> store the alias definitions in that case? >>> >>> Thanks for any help, >>> Michael >>> >>> >>> ----- >>> _______________________________________________ >>> Nuke-users mailing list >>> [email protected], http://forums.thefoundry.co.uk/ >>> http://support.thefoundry.co.uk/cgi-bin/mailman/listinfo/nuke-users >>> >> >> _______________________________________________ >> Nuke-users mailing list >> [email protected], http://forums.thefoundry.co.uk/ >> http://support.thefoundry.co.uk/cgi-bin/mailman/listinfo/nuke-users >> >
_______________________________________________ Nuke-users mailing list [email protected], http://forums.thefoundry.co.uk/ http://support.thefoundry.co.uk/cgi-bin/mailman/listinfo/nuke-users
