[distri] Questions about packages and versioning

  • From: "Wiktor Kwapisiewicz" <dmarc-noreply@xxxxxxxxxxxxx> (Redacted sender "wiktor" for DMARC)
  • To: distri@xxxxxxxxxxxxx
  • Date: Wed, 16 Oct 2019 21:26:13 +0200

Hello,

I just found Distri and it looks like the project is very interesting (both from the current design principles and the general idea of trying out something new).

I've got some questions about packages and versioning if you don't mind.

I see Distri already supports custom repositories with "distri install --repo" option (e.g. "distri install --repo=https://example.com curl") where the target textproto URL is constructed from several concatenated parts.

Maybe a simpler alternative would be using system similar to what Go uses for imports (and other projects borrow, such as Docker): embedding the repo name in the package name (so having packages such as "example.com/curl") and then directly fetching that URL (Go always uses "https://"; scheme). Details here: https://golang.org/cmd/go/#hdr-Remote_import_paths

How is versioning handled in Distri?

I've seen some code comparing versions: https://github.com/distr1/distri/blob/master/cmd/distri/install.go#L428 but it looks like it's comparing strings and this could produce non-intuitive behavior (e.g.: https://play.golang.org/p/kZFL_UOI9kz ).

Android separates the visible, marketing important version (versionName) from version used for comparisons if the package should be upgraded (versionCode). VersionCode is an integer increased on each new version where the value is not significant. Details here: https://developer.android.com/studio/publish/versioning#appversioning

Thank you for your time!

Kind regards,
Wiktor

--
https://metacode.biz/@wiktor

Other related posts: