public inbox for cygwin-apps@cygwin.com
 help / color / mirror / Atom feed
* [PATCH setup] Allow setup to parse more than 3 versions from the setup.ini file
@ 2015-06-03 16:30 Jon TURNEY
  2015-06-08 13:43 ` Corinna Vinschen
  0 siblings, 1 reply; 11+ messages in thread
From: Jon TURNEY @ 2015-06-03 16:30 UTC (permalink / raw)
  To: cygwin-apps; +Cc: Jon TURNEY

Reminded by a recent request as to how to install xorg-server-1.17.1-2, which
has disappeared beyond setup's ken (in order to determine if there was a
regression in the curent version), this is a re-send of a patch I originally
submitted back in 2011 [1], which received an ambiguous response then.

[1] https://cygwin.com/ml/cygwin-apps/2011-04/msg00053.html

This recognizes any "[foo]" line as introducing the information for another
version, which doesn't have one of the trust levels [curr], [prev] or [test],
and so isn't automatically selected when setup is told to install all packages
at that trust level (by default, [curr]).

Setup already does all the neccessary sorting in version order etc. to use these
additional versions.

Since the value of <foo> carries no meaning, it might make sense to update the
setup.ini specification to mandate the use of specific strings like "[also]" or
"[other]", or perhaps "[prev-1]", "[prev-2]", etc.

I have written a corresponding patch to genini.

I'm not sure what expiry policy is currently used by upset for old packages, but
presumably that would need to be made more sophisticated, along with the changes
needed to generate setup.ini entries for other versions.

Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
---
 ChangeLog      | 7 +++++++
 PackageTrust.h | 2 +-
 inilex.ll      | 1 +
 iniparse.yy    | 3 ++-
 4 files changed, 11 insertions(+), 2 deletions(-)

diff --git a/ChangeLog b/ChangeLog
index 854ba05..a4f9240 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2015-05-15  Jon TURNEY  <jon.turney@dronecode.org.uk>
+
+	* PackageTrust.h (trusts): Add TRUST_OTHER.
+	* inilex.ll: tokenize any other [version] as the T_OTHER token.
+	* iniparse.yy: Add T_OTHER token and set package trust
+	to TRUST_OTHER when it is used.
+
 2015-03-25  Corinna Vinschen  <corinna@vinschen.de>
 
 	* install.cc (sha512_one): Raise buffer size to 64K for performance
diff --git a/PackageTrust.h b/PackageTrust.h
index 3e6801d..4904705 100644
--- a/PackageTrust.h
+++ b/PackageTrust.h
@@ -20,10 +20,10 @@
 typedef enum
 {
   TRUST_UNKNOWN,
+  TRUST_OTHER,
   TRUST_PREV,
   TRUST_CURR,
   TRUST_TEST,
-  NTRUST
 }
 trusts;
 
diff --git a/inilex.ll b/inilex.ll
index 81a7f24..cb6c6b4 100644
--- a/inilex.ll
+++ b/inilex.ll
@@ -134,6 +134,7 @@ STR	[!a-zA-Z0-9_./:\+~-]+
 "[test]"		return T_TEST;
 "[exp]"			return T_TEST;
 "[prev]"		return T_PREV;
+"["{STR}"]"		return T_OTHER;
 
 "("			return OPENBRACE;
 ")"			return CLOSEBRACE;
diff --git a/iniparse.yy b/iniparse.yy
index cab84f2..8dbb792 100644
--- a/iniparse.yy
+++ b/iniparse.yy
@@ -41,7 +41,7 @@ void add_correct_version();
 %token SETUP_TIMESTAMP SETUP_VERSION PACKAGEVERSION INSTALL SOURCE SDESC LDESC
 %token CATEGORY DEPENDS REQUIRES
 %token APATH PPATH INCLUDE_SETUP EXCLUDE_PACKAGE DOWNLOAD_URL
-%token T_PREV T_CURR T_TEST
+%token T_PREV T_CURR T_TEST T_OTHER
 %token SHA512 MD5 INSTALLEDSIZE MAINTAINER PRIORITY
 %token DESCTAG DESCRIPTION FILESIZE ARCHITECTURE SOURCEPACKAGE MD5LINE 
 %token RECOMMENDS PREDEPENDS
@@ -98,6 +98,7 @@ singleitem /* non-empty */
  | T_PREV NL 			{ iniBuilder->buildPackageTrust (TRUST_PREV); }
  | T_CURR NL			{ iniBuilder->buildPackageTrust (TRUST_CURR); }
  | T_TEST NL			{ iniBuilder->buildPackageTrust (TRUST_TEST); }
+ | T_OTHER NL			{ iniBuilder->buildPackageTrust (TRUST_OTHER); }
  | PRIORITY STRING NL		{ iniBuilder->buildPriority ($2); }
  | INSTALLEDSIZE STRING NL	{ iniBuilder->buildInstalledSize ($2); }
  | MAINTAINER STRING NL		{ iniBuilder->buildMaintainer ($2); }
-- 
2.1.4

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PATCH setup] Allow setup to parse more than 3 versions from the setup.ini file
  2015-06-03 16:30 [PATCH setup] Allow setup to parse more than 3 versions from the setup.ini file Jon TURNEY
@ 2015-06-08 13:43 ` Corinna Vinschen
  2015-06-08 19:24   ` Achim Gratz
  2016-08-31 10:48   ` Jon Turney
  0 siblings, 2 replies; 11+ messages in thread
From: Corinna Vinschen @ 2015-06-08 13:43 UTC (permalink / raw)
  To: cygwin-apps

[-- Attachment #1: Type: text/plain, Size: 2424 bytes --]

On Jun  3 17:30, Jon TURNEY wrote:
> Reminded by a recent request as to how to install xorg-server-1.17.1-2, which
> has disappeared beyond setup's ken (in order to determine if there was a
> regression in the curent version), this is a re-send of a patch I originally
> submitted back in 2011 [1], which received an ambiguous response then.
> 
> [1] https://cygwin.com/ml/cygwin-apps/2011-04/msg00053.html
> 
> This recognizes any "[foo]" line as introducing the information for another
> version, which doesn't have one of the trust levels [curr], [prev] or [test],
> and so isn't automatically selected when setup is told to install all packages
> at that trust level (by default, [curr]).
> 
> Setup already does all the neccessary sorting in version order etc. to use these
> additional versions.
> 
> Since the value of <foo> carries no meaning, it might make sense to update the
> setup.ini specification to mandate the use of specific strings like "[also]" or
> "[other]", or perhaps "[prev-1]", "[prev-2]", etc.
> 
> I have written a corresponding patch to genini.
> 
> I'm not sure what expiry policy is currently used by upset for old packages, but
> presumably that would need to be made more sophisticated, along with the changes
> needed to generate setup.ini entries for other versions.

Upset does not handle expiry of packages at all.  Versions are mentioned
in setup.hint as test, curr, prev, or exp (yes, really) and those are
handled, everything else throws an error message.  Package versions not
mentioned in setup.hint are simply ignored.

I'm not against adding some functionality along these lines (provided
you also fix upset), but I'm not so sure about the broad definition of
the version state pattern.  It feels as generating problems down the
road.  Think setup.hint.  Your patch would requite to recognize more or
less any string as version state:

  category: [...]
  requires: [...]
  sdesc: [...]
  ldesc: [...]
  prev: 1.2.3-1
  curr: 1.2.4-1
  test: 1.2.5-1
  blub: 1.2.6-1
  fwexf3efx24x: 1.2.7-1

Wouldn't it be better to extend the state space by defining stricter
patterns based on the existing ones like

  prev3
  prev2
  prev
  curr
  test
  test2
  test3

?


Corinna

-- 
Corinna Vinschen                  Please, send mails regarding Cygwin to
Cygwin Maintainer                 cygwin AT cygwin DOT com
Red Hat

[-- Attachment #2: Type: application/pgp-signature, Size: 819 bytes --]

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PATCH setup] Allow setup to parse more than 3 versions from the setup.ini file
  2015-06-08 13:43 ` Corinna Vinschen
@ 2015-06-08 19:24   ` Achim Gratz
  2016-08-31 10:48     ` Jon Turney
  2016-08-31 10:48   ` Jon Turney
  1 sibling, 1 reply; 11+ messages in thread
From: Achim Gratz @ 2015-06-08 19:24 UTC (permalink / raw)
  To: cygwin-apps

Corinna Vinschen writes:
> I'm not against adding some functionality along these lines (provided
> you also fix upset), but I'm not so sure about the broad definition of
> the version state pattern.  It feels as generating problems down the
> road.  Think setup.hint.  Your patch would requite to recognize more or
> less any string as version state:

Thats easily fixable by requiring a constant prefix ("ver-" or even just
"v" looks like something that should work).

But besides that issue I don't think that setup.exe makes this easily
useable.  If I understand the motivation of John correctly, he'd want to
keep an older version of the X server installable, or maybe as another
example let's say I'd want to make it possible to keep perl-5.14 around
for a while.  I don't think people would want to click on hundreds of
chooser boxes until they have some set of old versions that are (or
maybe not) working together.  This is only useful if that set of old
packages can somehow be ganged together and switched all at once, IMHO.
This probably means a meta-package that pulls in versioned dependencies.

The dirty little secret of setup is that it already has those versioned
dependencies and can probably also deal with different dependencies for
each trust level and replace packages (in other words, the obsoletiohn
dance we're normally doing may be unnecessary).  It also has recommends,
suggests, depends and conflicts.  These features have quite likely
bit-rotted and documentation is almost non-existing, but they're already
built in.


Regards,
Achim.
-- 
+<[Q+ Matrix-12 WAVE#46+305 Neuron microQkb Andromeda XTk Blofeld]>+

SD adaptations for KORG EX-800 and Poly-800MkII V0.9:
http://Synth.Stromeko.net/Downloads.html#KorgSDada

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PATCH setup] Allow setup to parse more than 3 versions from the setup.ini file
  2015-06-08 19:24   ` Achim Gratz
@ 2016-08-31 10:48     ` Jon Turney
  0 siblings, 0 replies; 11+ messages in thread
From: Jon Turney @ 2016-08-31 10:48 UTC (permalink / raw)
  To: cygwin-apps

On 08/06/2015 20:24, Achim Gratz wrote:
> Corinna Vinschen writes:
>> I'm not against adding some functionality along these lines (provided
>> you also fix upset), but I'm not so sure about the broad definition of
>> the version state pattern.  It feels as generating problems down the
>> road.  Think setup.hint.  Your patch would requite to recognize more or
>> less any string as version state:
>
> Thats easily fixable by requiring a constant prefix ("ver-" or even just
> "v" looks like something that should work).

Agreed.

> But besides that issue I don't think that setup.exe makes this easily
> useable.  If I understand the motivation of John correctly, he'd want to
> keep an older version of the X server installable, or maybe as another
> example let's say I'd want to make it possible to keep perl-5.14 around
> for a while.  I don't think people would want to click on hundreds of
> chooser boxes until they have some set of old versions that are (or
> maybe not) working together.  This is only useful if that set of old
> packages can somehow be ganged together and switched all at once, IMHO.
> This probably means a meta-package that pulls in versioned dependencies.

That is indeed another piece of the puzzle, and something I intend on 
working on.

> The dirty little secret of setup is that it already has those versioned
> dependencies and can probably also deal with different dependencies for
> each trust level and replace packages (in other words, the obsoletiohn
> dance we're normally doing may be unnecessary).  It also has recommends,
> suggests, depends and conflicts.  These features have quite likely
> bit-rotted and documentation is almost non-existing, but they're already
> built in.

'never finished' rather than 'bit-rotted'

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PATCH setup] Allow setup to parse more than 3 versions from the setup.ini file
  2015-06-08 13:43 ` Corinna Vinschen
  2015-06-08 19:24   ` Achim Gratz
@ 2016-08-31 10:48   ` Jon Turney
  2016-12-06 14:41     ` Jon Turney
  1 sibling, 1 reply; 11+ messages in thread
From: Jon Turney @ 2016-08-31 10:48 UTC (permalink / raw)
  To: cygwin-apps

On 08/06/2015 14:43, Corinna Vinschen wrote:
> On Jun  3 17:30, Jon TURNEY wrote:
>> Reminded by a recent request as to how to install xorg-server-1.17.1-2, which
>> has disappeared beyond setup's ken (in order to determine if there was a
>> regression in the curent version), this is a re-send of a patch I originally
>> submitted back in 2011 [1], which received an ambiguous response then.
>>
>> [1] https://cygwin.com/ml/cygwin-apps/2011-04/msg00053.html
>>
>> This recognizes any "[foo]" line as introducing the information for another
>> version, which doesn't have one of the trust levels [curr], [prev] or [test],
>> and so isn't automatically selected when setup is told to install all packages
>> at that trust level (by default, [curr]).
>>
>> Setup already does all the neccessary sorting in version order etc. to use these
>> additional versions.
>>
>> Since the value of <foo> carries no meaning, it might make sense to update the
>> setup.ini specification to mandate the use of specific strings like "[also]" or
>> "[other]", or perhaps "[prev-1]", "[prev-2]", etc.
>>
>> I have written a corresponding patch to genini.
>>
>> I'm not sure what expiry policy is currently used by upset for old packages, but
>> presumably that would need to be made more sophisticated, along with the changes
>> needed to generate setup.ini entries for other versions.
>
> Upset does not handle expiry of packages at all.  Versions are mentioned
> in setup.hint as test, curr, prev, or exp (yes, really) and those are
> handled, everything else throws an error message.  Package versions not
> mentioned in setup.hint are simply ignored.

Yes, upset doesn't (didn't) explicitly handle expiry, but the fact that 
a package version is not mentioned in setup.ini causes it to be removed 
by stalepkgs, when that is next run.

After the corresponding change to setup.ini generation, it will list all 
versions, so none would ever be eligible for expiry under that policy.

Anyhow, improving that is close to the top of my hit-list for calm.

> I'm not against adding some functionality along these lines (provided
> you also fix upset), but I'm not so sure about the broad definition of
> the version state pattern.  It feels as generating problems down the
> road.  Think setup.hint.  Your patch would requite to recognize more or
> less any string as version state:
>
>   category: [...]
>   requires: [...]
>   sdesc: [...]
>   ldesc: [...]
>   prev: 1.2.3-1
>   curr: 1.2.4-1
>   test: 1.2.5-1
>   blub: 1.2.6-1
>   fwexf3efx24x: 1.2.7-1

I wasn't envisioning these labels appearing in setup.hint at all, since 
that only gives the information 'this version exists', which is already 
apparent from the existence of the package file.

(In fact, even 'prev' has no real meaning any more since the removal of 
the 'prev' stability selector in setup [1], apart from 'don't expire me')

Nevertheless, you are correct, so (by specification) let's restrict the 
label to 'ver<digits>'.

I should also have mentioned that existing versions of setup cannot 
parse setup.ini with these extra labels (reporting an error and asking 
'do you have the latest setup?'), so it would be nice to get this into 
setup sooner rather than later, if possible.

[1] 
https://sourceware.org/git/?p=cygwin-setup.git;a=commit;h=ec9c1d708418e05c4ba02b58a9869f1e232ad381

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PATCH setup] Allow setup to parse more than 3 versions from the setup.ini file
  2016-08-31 10:48   ` Jon Turney
@ 2016-12-06 14:41     ` Jon Turney
  2016-12-06 17:22       ` Jon Turney
  0 siblings, 1 reply; 11+ messages in thread
From: Jon Turney @ 2016-12-06 14:41 UTC (permalink / raw)
  To: cygwin-apps

On 31/08/2016 11:48, Jon Turney wrote:
> On 08/06/2015 14:43, Corinna Vinschen wrote:
>> On Jun  3 17:30, Jon TURNEY wrote:
>>> Reminded by a recent request as to how to install
>>> xorg-server-1.17.1-2, which
>>> has disappeared beyond setup's ken (in order to determine if there was a
>>> regression in the curent version), this is a re-send of a patch I
>>> originally
>>> submitted back in 2011 [1], which received an ambiguous response then.
>>>
>>> [1] https://cygwin.com/ml/cygwin-apps/2011-04/msg00053.html
>>>
>>> This recognizes any "[foo]" line as introducing the information for
>>> another
>>> version, which doesn't have one of the trust levels [curr], [prev] or
>>> [test],
>>> and so isn't automatically selected when setup is told to install all
>>> packages
>>> at that trust level (by default, [curr]).
>>>
>>> Setup already does all the neccessary sorting in version order etc.
>>> to use these
>>> additional versions.
>>>
>>> Since the value of <foo> carries no meaning, it might make sense to
>>> update the
>>> setup.ini specification to mandate the use of specific strings like
>>> "[also]" or
>>> "[other]", or perhaps "[prev-1]", "[prev-2]", etc.
>>>
>>> I have written a corresponding patch to genini.
>>>
>>> I'm not sure what expiry policy is currently used by upset for old
>>> packages, but
>>> presumably that would need to be made more sophisticated, along with
>>> the changes
>>> needed to generate setup.ini entries for other versions.
>>
>> Upset does not handle expiry of packages at all.  Versions are mentioned
>> in setup.hint as test, curr, prev, or exp (yes, really) and those are
>> handled, everything else throws an error message.  Package versions not
>> mentioned in setup.hint are simply ignored.
>
> Yes, upset doesn't (didn't) explicitly handle expiry, but the fact that
> a package version is not mentioned in setup.ini causes it to be removed
> by stalepkgs, when that is next run.
>
> After the corresponding change to setup.ini generation, it will list all
> versions, so none would ever be eligible for expiry under that policy.
>
> Anyhow, improving that is close to the top of my hit-list for calm.

calm now handles package expiry as of [1], so, pinging this.

There also exists a corresponding calm patch [2], to generate setup.ini 
listing more than 3 versions (This should not be deployed until some 
time after a setup with the above patch has been released)

[1] https://cygwin.com/ml/cygwin-apps/2016-09/msg00021.html
[2] 
https://github.com/jon-turney/calm/commit/cf5497063b146cc7442437b5047e318d9a074769

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PATCH setup] Allow setup to parse more than 3 versions from the setup.ini file
  2016-12-06 14:41     ` Jon Turney
@ 2016-12-06 17:22       ` Jon Turney
  2016-12-06 18:43         ` Corinna Vinschen
  0 siblings, 1 reply; 11+ messages in thread
From: Jon Turney @ 2016-12-06 17:22 UTC (permalink / raw)
  To: cygwin-apps

[-- Attachment #1: Type: text/plain, Size: 1121 bytes --]

On 06/12/2016 14:41, Jon Turney wrote:
> On 31/08/2016 11:48, Jon Turney wrote:
>> On 08/06/2015 14:43, Corinna Vinschen wrote:
>>> On Jun  3 17:30, Jon TURNEY wrote:
>>>> Reminded by a recent request as to how to install
>>>> xorg-server-1.17.1-2, which
>>>> has disappeared beyond setup's ken (in order to determine if there
>>>> was a
>>>> regression in the curent version), this is a re-send of a patch I
>>>> originally
>>>> submitted back in 2011 [1], which received an ambiguous response then.
>>>>
>>>> [1] https://cygwin.com/ml/cygwin-apps/2011-04/msg00053.html
>>>>
>>>> This recognizes any "[foo]" line as introducing the information for
>>>> another
>>>> version, which doesn't have one of the trust levels [curr], [prev] or
>>>> [test],
>>>> and so isn't automatically selected when setup is told to install all
>>>> packages
>>>> at that trust level (by default, [curr]).
>>>>
>>>> Setup already does all the neccessary sorting in version order etc.
>>>> to use these
>>>> additional versions.
>>>>
[...]
>
> calm now handles package expiry as of [1], so, pinging this.

As requested, resending the patch.


[-- Attachment #2: 0001-Allow-setup-to-parse-more-than-3-versions-from-the-s.patch --]
[-- Type: text/plain, Size: 2656 bytes --]

From 35ecf968425762c72076059464dfb6c8b21a9331 Mon Sep 17 00:00:00 2001
From: Jon Turney <jon.turney@dronecode.org.uk>
Date: Wed, 31 Aug 2016 11:31:22 +0100
Subject: [PATCH setup] Allow setup to parse more than 3 versions from the
 setup.ini file

This recognizes any "[foo]" line as introducing the information for another
version, which doesn't have one of the trust levels [curr], [prev] or
[test], and so isn't automatically selected when setup is told to install
all packages at that trust level (by default, [curr]).

Setup already does all the necessary sorting in version order etc. to use
these additional versions.

The value of <foo> carries no meaning, but the setup.ini specification
mandates the use of "[ver<digits>]".

	* PackageTrust.h (trusts): Add TRUST_OTHER.
	* inilex.ll: tokenize any other [version] as the T_OTHER token.
	* iniparse.yy: Add T_OTHER token and set package trust
	to TRUST_OTHER when it is used.
---
 PackageTrust.h | 2 +-
 inilex.ll      | 1 +
 iniparse.yy    | 3 ++-
 3 files changed, 4 insertions(+), 2 deletions(-)

diff --git a/PackageTrust.h b/PackageTrust.h
index 3e6801d..4904705 100644
--- a/PackageTrust.h
+++ b/PackageTrust.h
@@ -20,10 +20,10 @@
 typedef enum
 {
   TRUST_UNKNOWN,
+  TRUST_OTHER,
   TRUST_PREV,
   TRUST_CURR,
   TRUST_TEST,
-  NTRUST
 }
 trusts;
 
diff --git a/inilex.ll b/inilex.ll
index 49bbfa6..7daca34 100644
--- a/inilex.ll
+++ b/inilex.ll
@@ -159,6 +159,7 @@ B64	[a-zA-Z0-9_-]
 "[test]"		return T_TEST;
 "[exp]"			return T_TEST;
 "[prev]"		return T_PREV;
+"["{STR}"]"		return T_OTHER;
 
 "("			return OPENBRACE;
 ")"			return CLOSEBRACE;
diff --git a/iniparse.yy b/iniparse.yy
index 7645171..8ae1e2d 100644
--- a/iniparse.yy
+++ b/iniparse.yy
@@ -41,7 +41,7 @@ void add_correct_version();
 %token SETUP_TIMESTAMP SETUP_VERSION PACKAGEVERSION INSTALL SOURCE SDESC LDESC
 %token CATEGORY DEPENDS REQUIRES
 %token APATH PPATH INCLUDE_SETUP EXCLUDE_PACKAGE DOWNLOAD_URL
-%token T_PREV T_CURR T_TEST
+%token T_PREV T_CURR T_TEST T_OTHER
 %token INSTALLEDSIZE MAINTAINER PRIORITY
 %token MD5 MD5LINE SHA512 SHA512LINE
 %token DESCTAG DESCRIPTION FILESIZE ARCHITECTURE SOURCEPACKAGE
@@ -99,6 +99,7 @@ singleitem /* non-empty */
  | T_PREV NL 			{ iniBuilder->buildPackageTrust (TRUST_PREV); }
  | T_CURR NL			{ iniBuilder->buildPackageTrust (TRUST_CURR); }
  | T_TEST NL			{ iniBuilder->buildPackageTrust (TRUST_TEST); }
+ | T_OTHER NL			{ iniBuilder->buildPackageTrust (TRUST_OTHER); }
  | PRIORITY STRING NL		{ iniBuilder->buildPriority ($2); }
  | INSTALLEDSIZE STRING NL	{ iniBuilder->buildInstalledSize ($2); }
  | MAINTAINER STRING NL		{ iniBuilder->buildMaintainer ($2); }
-- 
2.8.3


^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PATCH setup] Allow setup to parse more than 3 versions from the setup.ini file
  2016-12-06 17:22       ` Jon Turney
@ 2016-12-06 18:43         ` Corinna Vinschen
  2017-10-09 19:32           ` Jon Turney
  0 siblings, 1 reply; 11+ messages in thread
From: Corinna Vinschen @ 2016-12-06 18:43 UTC (permalink / raw)
  To: cygwin-apps

[-- Attachment #1: Type: text/plain, Size: 1204 bytes --]

On Dec  6 17:21, Jon Turney wrote:
> From 35ecf968425762c72076059464dfb6c8b21a9331 Mon Sep 17 00:00:00 2001
> From: Jon Turney <jon.turney@dronecode.org.uk>
> Date: Wed, 31 Aug 2016 11:31:22 +0100
> Subject: [PATCH setup] Allow setup to parse more than 3 versions from the
>  setup.ini file
> 
> This recognizes any "[foo]" line as introducing the information for another
> version, which doesn't have one of the trust levels [curr], [prev] or
> [test], and so isn't automatically selected when setup is told to install
> all packages at that trust level (by default, [curr]).
> 
> Setup already does all the necessary sorting in version order etc. to use
> these additional versions.
> 
> The value of <foo> carries no meaning, but the setup.ini specification
> mandates the use of "[ver<digits>]".
> 
> 	* PackageTrust.h (trusts): Add TRUST_OTHER.
> 	* inilex.ll: tokenize any other [version] as the T_OTHER token.
> 	* iniparse.yy: Add T_OTHER token and set package trust
> 	to TRUST_OTHER when it is used.

ACK


Corinna


-- 
Corinna Vinschen                  Please, send mails regarding Cygwin to
Cygwin Maintainer                 cygwin AT cygwin DOT com
Red Hat

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 819 bytes --]

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PATCH setup] Allow setup to parse more than 3 versions from the setup.ini file
  2016-12-06 18:43         ` Corinna Vinschen
@ 2017-10-09 19:32           ` Jon Turney
  2017-11-03 13:38             ` Jon Turney
  0 siblings, 1 reply; 11+ messages in thread
From: Jon Turney @ 2017-10-09 19:32 UTC (permalink / raw)
  To: cygwin-apps

On 06/12/2016 18:43, Corinna Vinschen wrote:
> On Dec  6 17:21, Jon Turney wrote:
>>  From 35ecf968425762c72076059464dfb6c8b21a9331 Mon Sep 17 00:00:00 2001
>> From: Jon Turney <jon.turney-GrJqePx9RPPAJUdA+FbntA@public.gmane.org>
>> Date: Wed, 31 Aug 2016 11:31:22 +0100
>> Subject: [PATCH setup] Allow setup to parse more than 3 versions from the
>>   setup.ini file
>>
>> This recognizes any "[foo]" line as introducing the information for another
>> version, which doesn't have one of the trust levels [curr], [prev] or
>> [test], and so isn't automatically selected when setup is told to install
>> all packages at that trust level (by default, [curr]).
>>
>> Setup already does all the necessary sorting in version order etc. to use
>> these additional versions.
>>
>> The value of <foo> carries no meaning, but the setup.ini specification
>> mandates the use of "[ver<digits>]".
>>
>> 	* PackageTrust.h (trusts): Add TRUST_OTHER.
>> 	* inilex.ll: tokenize any other [version] as the T_OTHER token.
>> 	* iniparse.yy: Add T_OTHER token and set package trust
>> 	to TRUST_OTHER when it is used.

So, thinking about this change some more, I realize that there is a 
another way to do this, which doesn't break backwards compatibility with 
setup, by having multiple [prev] and [test] sections.

[1] doesn't say that these section names are unique, and setup doesn't 
require that, I'm going to claim that it's valid :)

Because of the way setup works, the last [test] section is the version 
which is selected when 'test' is selected, so a specific ordering of the 
sections would be required.  The calm change to implement this is at [1].

So, for example we could have:

@foo
...
version: 250-0
...
[prev]
version: 241-0
...
[prev]
version: 243-0
...
[test]
version: 251-0
...
[test]
version: 252-0
...

250-0 would be current, 252-0 would be test, and the other versions 
would also be available to install.

[1] https://sourceware.org/cygwin-apps/setup.ini.html
[2] 
https://github.com/jon-turney/calm/commit/c21cfdc8f8c94f615ff97000428c6e542d335dca

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PATCH setup] Allow setup to parse more than 3 versions from the setup.ini file
  2017-10-09 19:32           ` Jon Turney
@ 2017-11-03 13:38             ` Jon Turney
  2017-11-03 20:20               ` Achim Gratz
  0 siblings, 1 reply; 11+ messages in thread
From: Jon Turney @ 2017-11-03 13:38 UTC (permalink / raw)
  To: cygwin-apps

On 09/10/2017 20:32, Jon Turney wrote:
> So, thinking about this change some more, I realize that there is a 
> another way to do this, which doesn't break backwards compatibility with 
> setup, by having multiple [prev] and [test] sections.
> 
> [1] doesn't say that these section names are unique, and setup doesn't 
> require that, I'm going to claim that it's valid :)
> 
> Because of the way setup works, the last [test] section is the version 
> which is selected when 'test' is selected, so a specific ordering of the 
> sections would be required.  The calm change to implement this is at [2].
[...]
> [1] https://sourceware.org/cygwin-apps/setup.ini.html
> [2] https://github.com/jon-turney/calm/commit/c21cfdc8f8c94f615ff97000428c6e542d335dca 

I deployed this calm change today.

I think that no-one should notice anything, apart from setup now 
offering another choice of older versions for some packages.

The current default package retention policy is: the curr and test 
versions are always kept, also keep the 3 highest versions (this is 
slightly more generous than upset's historical behaviour, as it keeps 3 
versions even if test isn't being used)

Maintainers can customize this policy using keep*: lines in 
override.hint [3].

[3] https://cygwin.com/packaging-hint-files.html#override.hint

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PATCH setup] Allow setup to parse more than 3 versions from the setup.ini file
  2017-11-03 13:38             ` Jon Turney
@ 2017-11-03 20:20               ` Achim Gratz
  0 siblings, 0 replies; 11+ messages in thread
From: Achim Gratz @ 2017-11-03 20:20 UTC (permalink / raw)
  To: cygwin-apps

Jon Turney writes:
> The current default package retention policy is: the curr and test
> versions are always kept, also keep the 3 highest versions (this is
> slightly more generous than upset's historical behaviour, as it keeps
> 3 versions even if test isn't being used)

Is there any pressing need to do this?  I'm quite certain it will push
my local mirror over the current 100GB limit in just a few weeks.  I'm
only keeping that limit for now because I exclude large swathes from KDE
and GNOME from getting mirrored.


Regards,
Achim.
-- 
+<[Q+ Matrix-12 WAVE#46+305 Neuron microQkb Andromeda XTk Blofeld]>+

SD adaptations for KORG EX-800 and Poly-800MkII V0.9:
http://Synth.Stromeko.net/Downloads.html#KorgSDada

^ permalink raw reply	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2017-11-03 20:20 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-06-03 16:30 [PATCH setup] Allow setup to parse more than 3 versions from the setup.ini file Jon TURNEY
2015-06-08 13:43 ` Corinna Vinschen
2015-06-08 19:24   ` Achim Gratz
2016-08-31 10:48     ` Jon Turney
2016-08-31 10:48   ` Jon Turney
2016-12-06 14:41     ` Jon Turney
2016-12-06 17:22       ` Jon Turney
2016-12-06 18:43         ` Corinna Vinschen
2017-10-09 19:32           ` Jon Turney
2017-11-03 13:38             ` Jon Turney
2017-11-03 20:20               ` Achim Gratz

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).