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

Custom template for integrating book links #3040

Merged
merged 3 commits into from
Aug 10, 2023
Merged

Custom template for integrating book links #3040

merged 3 commits into from
Aug 10, 2023

Conversation

nelliemckesson
Copy link
Contributor

@nelliemckesson nelliemckesson commented Aug 3, 2023

This creates some special handling for sections that are intended to link to a book. You should be able to use this same format for sections of any level. You can include any type of content inside your section, as usual, and a final paragraph will automatically be appended to the section, linking to the book with text that corresponds to the type of book. The following attributes are required:

  • .booklink
  • booktype (options are: free, buy, or donate)
  • link to the book, buy page, or donate page
  • image of the book cover (can be either included in the repo or a url). Note that in order for it to be picked up by the toolchain, the image attribute must be formatted the same way you'd format a regular asciidoc image, including both the image:: and trailing []; see below for an example.
[.booklink, booktype="free", link=https://pip.raspberrypi.com/categories/685-whitepapers-app-notes/documents/RP-003471-WP/Using-a-DPI-display.pdf, image=image::images/simple-electronics-with-gpio-zero.jpg[]]
==== Going further

You can find more information on how to program electronics connected to your Raspberry Pi with the GPIO Zero Python library in the Raspberry Pi Press book https://github.com/raspberrypipress/released-pdfs/raw/main/simple-electronics-with-gpio-zero.pdf[Simple Electronics with GPIO Zero]. Written by Phil King, it is part of the MagPi Essentials series published by Raspberry Pi Press. The book gets you started with the GPIO Zero library, and walks you through how to use it by building a series of projects. 

See #3035

@aallan aallan added enhancement toolchain This is an infrastructure/toolchain issue labels Aug 4, 2023
@aallan aallan linked an issue Aug 4, 2023 that may be closed by this pull request
@aallan
Copy link
Contributor

aallan commented Aug 10, 2023

Thanks @nelliemckesson. Ready to merge do you think? If so I'll sit down with this later today when I get some time to flip through the docs and figure out how many times I've already done this without a template, and replace all of them with this!

Copy link
Contributor

@aallan aallan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

YOLO!

@aallan
Copy link
Contributor

aallan commented Aug 10, 2023

@bjepson Free, buy, or donate covers all cases I'm presuming?

@nelliemckesson
Copy link
Contributor Author

@aallan I'm feeling good about it, so you can merge when you're ready!

@aallan
Copy link
Contributor

aallan commented Aug 10, 2023

Cool! I'll merge now then and page through the docs later. I'll get back to you if I run into any problems!

As always, thank you!

@aallan aallan merged commit 4e0a787 into develop Aug 10, 2023
1 check passed
@aallan aallan deleted the iss-3035 branch August 10, 2023 16:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement toolchain This is an infrastructure/toolchain issue
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Integration of Raspberry Pi Press book titles
2 participants