From mboxrd@z Thu Jan 1 00:00:00 1970 Return-path: Received: from ptx.hi.pengutronix.de ([2001:67c:670:100:1d::c0] ident=Debian-exim) by metis.ext.pengutronix.de with esmtp (Exim 4.72) (envelope-from ) id 1YdhoI-0002sX-DM for ptxdist@pengutronix.de; Thu, 02 Apr 2015 18:17:38 +0200 Received: from mol by ptx.hi.pengutronix.de with local (Exim 4.80) (envelope-from ) id 1YdhoI-0005SX-C0 for ptxdist@pengutronix.de; Thu, 02 Apr 2015 18:17:38 +0200 Date: Thu, 2 Apr 2015 18:17:38 +0200 From: Michael Olbrich Message-ID: <20150402161738.GH20251@pengutronix.de> References: MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: Subject: Re: [ptxdist] Scripting of Kconfig options Reply-To: ptxdist@pengutronix.de List-Id: PTXdist Development Mailing List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: ptxdist-bounces@pengutronix.de Errors-To: ptxdist-bounces@pengutronix.de To: ptxdist@pengutronix.de Hi, On Fri, Mar 27, 2015 at 08:29:31PM +0100, Tobias Schmidl wrote: > I'm trying to automate a ptxdist build via Jenkins. Therefore, I need to > select a (known) PTXDist menuconfig option via shell script, i.e. "ptxdist > menuconfig" is not really an option. > > Right now the whole thing is done via sed, but I'm wondering if there is > a more pratical way of choosing an option fron an option group… By 'option group' you mean a 'choice' right? I don't think, that there is some special tool. I'd use sed and then 'fix' the ptxconfig with "ptxdist oldconfig < /dev/null". For a choice that would be: 1. Remove all alternatives 2. Append the option you want at the end of the file 3. Run oldconfig Kconfig will then keep the option you added and adds the others with 'is not set'. This keeps the sed magic simple and still produces a valid ptxconfig. Michael -- Pengutronix e.K. | | Industrial Linux Solutions | http://www.pengutronix.de/ | Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 | Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 | -- ptxdist mailing list ptxdist@pengutronix.de