From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from list by lists.gnu.org with archive (Exim 4.71) id 1XSplj-0002ps-SS for mharc-grub-devel@gnu.org; Sat, 13 Sep 2014 12:01:47 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:41069) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XSplc-0002dw-UD for grub-devel@gnu.org; Sat, 13 Sep 2014 12:01:46 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1XSplV-0004Wh-Oz for grub-devel@gnu.org; Sat, 13 Sep 2014 12:01:40 -0400 Received: from mail-lb0-x231.google.com ([2a00:1450:4010:c04::231]:36848) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XSplV-0004WT-IN for grub-devel@gnu.org; Sat, 13 Sep 2014 12:01:33 -0400 Received: by mail-lb0-f177.google.com with SMTP id l4so2440043lbv.22 for ; Sat, 13 Sep 2014 09:01:32 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=date:from:to:cc:subject:message-id:in-reply-to:references :mime-version:content-type:content-transfer-encoding; bh=vHpIUYFm/auSvxJHQwlrYkgIoDs5rpNefkDqIzxkD98=; b=a6yxV+eg1qEGv4fDWrl1QBlaQKX9qCySoVVQaUAhd1MJIbPQ1D2vcp4C8xueKpqGbv HCgPkTCUNom83oYjHWlNrl00HBrK2V18QUUiK5Rtzu1ahhAlikBW5LywuYLBQBrCnniO oW8Vo8zD1rHY8+lOjLJ/s+p6HpFIdNjEmklqbQfHa3N6QsE8v1h5R7ITXcSgmZsoqrgj qYldInUU9lepZF+e4ZlveUSSLSd7tjY3uuAr/uXlALvCeoWf22G62lhnnL0DG9bW6eiq yNYJen9CZDysLRJS76DlmV4bGBYUmS9mfULkpazswhmN9HOqQJWCQsdaJXt+/zvvtL3O ks/Q== X-Received: by 10.152.116.80 with SMTP id ju16mr16696786lab.73.1410624092375; Sat, 13 Sep 2014 09:01:32 -0700 (PDT) Received: from opensuse.site ([37.190.69.201]) by mx.google.com with ESMTPSA id r1sm2316071lae.33.2014.09.13.09.01.30 for (version=SSLv3 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Sat, 13 Sep 2014 09:01:31 -0700 (PDT) Date: Sat, 13 Sep 2014 20:01:28 +0400 From: Andrei Borzenkov To: The development of GNU GRUB Subject: Re: [PATCH] Add config option to prefer Linux kernel versions by substring match Message-ID: <20140913200128.1f0f384a@opensuse.site> In-Reply-To: <540CB400.2060004@doug-brunner.com> References: <540CB400.2060004@doug-brunner.com> X-Mailer: Claws Mail 3.9.2 (GTK+ 2.24.22; x86_64-suse-linux-gnu) Mime-Version: 1.0 Content-Type: text/plain; charset=KOI8-R Content-Transfer-Encoding: 8bit X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2a00:1450:4010:c04::231 Cc: doug@doug-brunner.com X-BeenThere: grub-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list Reply-To: The development of GNU GRUB List-Id: The development of GNU GRUB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 13 Sep 2014 16:01:47 -0000 В Sun, 07 Sep 2014 12:37:36 -0700 Doug Brunner пишет: > Hi all, > > First time submitting - please let me know if I'm doing anything wrong. > > This patch adds an option, GRUB_LINUX_PREF_VERSION_SUBSTR, that can be set to prioritize Linux kernels containing a > given substring. This takes precedence over version ordering, so if you have 3.14.1-generic, 3.14.2-generic, > 3.8.13-fnord1, and 3.8.13-fnord2 and the substring is 'fnord', the order is: > 3.8.13-fnord2 > 3.8.13-fnord1 > 3.14.2-generic > 3.14.1-generic > You can simply disable default 10_linux script and use your own that does whatever ordering you prefer. This is too specific for upstream distribution. But it really seems like we need some additional layer on top of raw grub script that allows manual reordering of entries among others. > + if [[ "$entry" == *$GRUB_LINUX_PREF_VERSION_SUBSTR* ]]; then No, grub scripts do not require bash, so this is not going to work.