[arm-allstar] #includeifexist does it work?

Doug Crompton wa3dsp at gmail.com
Sat Apr 15 15:41:12 EST 2017


Barry,

 Yes it works in fact I used it in a method to dynamically change courtesy
tones for someone awhile back. Instead of changing the main file the
include file was changed and then rpt.conf was reloaded. This is important
because any changes would not be registered until you reload. Also it is
important to note that in general the last definition is the one that
sticks. So if you defined something in rpt.conf and then redefined it in
the include file that would be the one that is in effect.

So if you dynamically wanted to change something you would do it in a
script... roughly this way....

#!/bin/bash

echo "some-command" > /etc/asterisk/custom/rpt.conf

​/usr/bin/asterisk -rx "rpt reload"

Of course this could be an entire file of commands instead of echoing a
single command -

cp my-commands /etc/asterisk/custom/rpt.conf

I hope that answers your question.
​

*73 Doug*

*WA3DSP*

*http://www.crompton.com/hamradio <http://www.crompton.com/hamradio>*

On Sat, Apr 15, 2017 at 4:14 PM, "Barry Buelow via arm-allstar" <
arm-allstar at hamvoip.org> wrote:

> I'd like to have a standard set of macros across several nodes. It would
> be convenient to have a single file and just upload it, then use an
> #inlcude.
>
> I see at the end of rpt.conf there is such a line.  Does this work?
>
> Thanks
>
> Barry w0iy
>
> _______________________________________________
>
> arm-allstar mailing list
> arm-allstar at hamvoip.org
> http://lists.hamvoip.org/cgi-bin/mailman/listinfo/arm-allstar
>
> Visit the BBB and RPi2/3 web page - http://hamvoip.org
>
>


More information about the arm-allstar mailing list