David Klaverstyn
2009-Apr-14 00:28 UTC
[asterisk-users] Changing menuselect values from CLI and not TUI
Hi All, I'm in the process of writing an install script and I would like to change some settings for the install process but I don't want the user to go into menuselect and make the changes manually. Is there a way to make the changes to menuselect from the CLI? As an example, selecting the iLBC codec. menuselect codec ilbc on Regards David. -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.digium.com/pipermail/asterisk-users/attachments/20090414/9ed1c4f1/attachment.htm
Paul Hales
2009-Apr-14 01:16 UTC
[asterisk-users] Changing menuselect values from CLI and not TUI
Is a drive image out of the question? PaulH David Klaverstyn wrote:> > Hi All, > > I?m in the process of writing an install script and I would like to > change some settings for the install process but I don?t want the user > to go into menuselect and make the changes manually. > > Is there a way to make the changes to menuselect from the CLI? > > As an example, selecting the iLBC codec. > > menuselect codec ilbc on > > Regards > > David. > > ------------------------------------------------------------------------ > > _______________________________________________ > -- Bandwidth and Colocation Provided by http://www.api-digital.com -- > > asterisk-users mailing list > To UNSUBSCRIBE or update options visit: > http://lists.digium.com/mailman/listinfo/asterisk-users
Laurent Steffan
2009-Apr-14 06:23 UTC
[asterisk-users] Changing menuselect values from CLI and not TUI
Le Tue, 14 Apr 2009 10:28:42 +1000, David Klaverstyn <dave at klaverstyn.com.au> a ?crit :> Hi All, > > I'm in the process of writing an install script and I would like to > change some settings for the install process but I don't want the > user to go into menuselect and make the changes manually. > > Is there a way to make the changes to menuselect from the CLI? > > As an example, selecting the iLBC codec. > menuselect codec ilbc on > > Regards > David.You might try to manipulate within your script the output of menuselect (that would be "menuseleect.makeopts" if you haven't changed the default). It seems rather straightforward to change or delete variables and their values. Another posssibility is to directly modify the input tree for menuselect; for instance, selecting by default the ilbc codec, as per your example, could be achieved by taking out the "<defaultenabled>no</defaultenabled>" phrase in the XML description of the ilbc codec option. The choice between these two methods (and maybe others...) probably depends on the structure of your install script, and the frequency of the changes to the install options. Best regards, Laurent -- Laurent Steffan Consultant VOIP Web: http://VOIP.nc
Tzafrir Cohen
2009-Apr-14 18:12 UTC
[asterisk-users] Changing menuselect values from CLI and not TUI
On Tue, Apr 14, 2009 at 10:28:42AM +1000, David Klaverstyn wrote:> Hi All, > > I'm in the process of writing an install script and I would like to change some settings for the install process but I don't want the user to go into menuselect and make the changes manually. > > Is there a way to make the changes to menuselect from the CLI? > > As an example, selecting the iLBC codec. > menuselect codec ilbc onOn the Debian package I generally patch source files and XML SPECs to set / reset the "defaltenable" options. The problem with patching the output of menuselect is that menuselect is run on each tim you un 'make'. This is why I never bothered adding such an option to dummy-select. OTOH, in dummy-select the configuration is straight-forward: echo enable codec_ilbc >build_tools/conf Menuselect uses the same file as both an input and an output, and this makes it very confusing and error-prone. -- Tzafrir Cohen icq#16849755 jabber:tzafrir.cohen at xorcom.com +972-50-7952406 mailto:tzafrir.cohen at xorcom.com http://www.xorcom.com iax:guest at local.xorcom.com/tzafrir