Skip to content

Add GHC release dates to `ghcup list` table

I felt like adding release dates of the GHC to the ghcup list table could be useful (e.g. when creating a new library to assess which older versions of GHC to still target, etc.)

I open this issue to see how the maintainers and other users feel about this.

Benefit

Added useful information content.

Drawbacks

  • Broader table. The current table is 61 terminal characters long (60 Unicode characters, but the inital x / tick are displayed with a double width character) This addition would push it over 80 characters. 80 characters, stemming from old VT100 terminals is sometimes still considered a desideratum.
  • Some might perceive it as information overload, making reading or parsing the table harder. I think this can be helped by judicious choice of colours, e.g. toning it down with grey.

Options

The date can be displayed either as an ISO8601 YYYY-MM-DD format, or it could be decided here to use human readable relative dates "two years ago". I would suggest deciding for one or the other and not introducing a flag to ghcup list to provide the functionality.

If going for relative human readable dates, a choice between one of the packages e.g. dates, friendly-time, fmt, relevant-time, chronos would be made on considerations as dependency size, maintainance status and whether it's already used in ghcup.

Implementation

I could give it a try.

Example

   Tool  Version        Tags                      Notes        Released
[ ... snip ... ]             
✗  ghc   8.6.4          base-4.12.0.0             hls-powered  2019-03-05
✓  ghc   8.6.5          base-4.12.0.0             hls-powered  2019-04-24
✗  ghc   8.8.1          base-4.13.0.0                          2019-08-25
✗  ghc   8.8.2          base-4.13.0.0             hls-powered  2020-01-16
✓  ghc   8.8.3          base-4.13.0.0             hls-powered  2020-02-24
✓  ghc   8.8.4          recommended,base-4.13.0.0 hls-powered  2020-07-15
✗  ghc   8.10.1         base-4.14.0.0             hls-powered  2020-03-24
✔✔ ghc   8.10.2         latest,base-4.14.1.0      hls-powered  2020-08-08
[ ... snip ... ]

or

   Tool  Version        Tags                      Notes        Released
[ ... snip ... ]             
✗  ghc   8.6.4          base-4.12.0.0             hls-powered  1¾ years  ago
✓  ghc   8.6.5          base-4.12.0.0             hls-powered  1½ years  ago
✗  ghc   8.8.1          base-4.13.0.0                          1¼ years  ago
✗  ghc   8.8.2          base-4.13.0.0             hls-powered  10 months ago
✓  ghc   8.8.3          base-4.13.0.0             hls-powered   9 months ago
✓  ghc   8.8.4          recommended,base-4.13.0.0 hls-powered   4 months ago
✗  ghc   8.10.1         base-4.14.0.0             hls-powered   8 months ago
✔✔ ghc   8.10.2         latest,base-4.14.1.0      hls-powered   2 months ago
[ ... snip ... ]

Further considerations

It could be considered to add release dates not only to GHC, but to the other install options as well (cabal, hls). On the other hand it might be less relevant with those, and its an equally valid stance to just provide it for GHC exactly for keeping the information tight.

To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information