Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add publish date on CI #456

Merged
merged 3 commits into from
Aug 31, 2023
Merged

Conversation

andys8
Copy link

@andys8 andys8 commented Aug 26, 2023

Description

This PR is supposed to add the information about when the book was published to the hosted version on https://book.purescript.org.

Motivation

Because of the history of the book, I personally always had the feeling that I'm looking at an outdated version. Having some indicator might be helpful that one is indeed looking at an up-to-date copy of the (awesome!) book.

Technical Considerations

The current PR is super simple. It will add a single line. It is mostly untested on CI, btw. I have no right to execute the github action, so testing wasn't really possible.

Alternatives

There is also https://github.com/badboy/mdbook-last-changed. It will add a footer to every page and, by default, refer to commits. This might be helpful, but is not actually what I'd intend with this PR. Therefore, I went with the simpler command-line approach, where the result was more to my liking.

@andys8 andys8 marked this pull request as ready for review August 26, 2023 17:12
@andys8 andys8 changed the title [WIP] Add publish date on CI Add publish date on CI Aug 26, 2023
@Zelenya
Copy link

Zelenya commented Aug 26, 2023

Awesome. Let's try it. Approving the run

@andys8
Copy link
Author

andys8 commented Aug 26, 2023

CI Test

image

@andys8
Copy link
Author

andys8 commented Aug 26, 2023

Update

Changed CI to append more information. I'm open to any text or structural changes. Currently it would look like this.

## Release

PureScript v0.15.4

Published on 2023-08-26

![image](https://github.com/purescript-contrib/purescript-book/assets/13085980/7e044e02-77d2-4181-aed9-

image

We could also go with a more textual description like "This book was last updated on x and the examples were tested with PureScript version y".

@Zelenya
Copy link

Zelenya commented Aug 26, 2023

If there's no simple way of getting the PureScript version, maybe we can be vague about it? The goal is to tell people that the book isn't stale. Something like The book is kept up to date; see package.yaml (link) for the ...?

@andys8
Copy link
Author

andys8 commented Aug 26, 2023

If there's no simple way of getting the PureScript version, maybe we can be vague about it?

Either vague or referring to the one the tests and CI are executed with.
953e017

@Zelenya
Copy link

Zelenya commented Aug 26, 2023

Oh, ok, it's just added a 3s

@Zelenya
Copy link

Zelenya commented Aug 26, 2023

Looks good to me, @milesfrain what do you think?

@andys8
Copy link
Author

andys8 commented Aug 30, 2023

So, who's going to merge? 😉

@Zelenya Zelenya merged commit 4edad29 into purescript-contrib:master Aug 31, 2023
2 checks passed
@Zelenya
Copy link

Zelenya commented Aug 31, 2023

Thank you, Andy! Works as expected.

@andys8 andys8 deleted the publish-date branch August 31, 2023 16:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

3 participants