Skip to content

Commit

Permalink
consistently "truncate" blogs and resolve Docusaurus warnings (#254)
Browse files Browse the repository at this point in the history
Since the update to 3.5, Docusaurus has spit out this new WARNING

```
[WARNING] Docusaurus found blog posts without truncation markers:
- "blog/2024-07-01-building-linux-on-osx-silicon/index.mdx"
- "blog/2024-06-13-announcing-klaviyo-sponsorship/index.mdx"
- "blog/2024-04-27-simple-versioning-with-git-tags/index.mdx"

We recommend using truncation markers (`<!-- truncate -->` or `{/* truncate */}`) in blog posts to create shorter previews on blog paginated lists.
Tip: turn this security off with the `onUntruncatedBlogPosts: 'ignore'` blog plugin option.
```

To resolve this I've:
 * Added `truncate` to those blog posts that were missing it
* Moved the `truncate` for 2024 blog posts to always capture at least a
little text (and not just the splash image).
  • Loading branch information
cburroughs authored Aug 26, 2024
1 parent 9a00f62 commit 542bd02
Show file tree
Hide file tree
Showing 8 changed files with 16 additions and 10 deletions.
4 changes: 2 additions & 2 deletions blog/2024-01-24-pants-2-19/index.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,6 @@
[Unsplash](https://unsplash.com/photos/mountains-covered-with-snow-d3pTF3r_hwY?utm_content=creditCopyText&utm_medium=referral&utm_source=unsplash)
</CaptionedImg>

{/* truncate */}

We're pleased to announce Pants 2.19.0, the latest release of [Pantsbuild, the scalable and ergonomic build system](https://www.pantsbuild.org/). To update, set `pants_version = "2.19.0"` in your `pants.toml`. If you're not using Pants yet, [get started now](https://www.pantsbuild.org/docs/getting-started).

_Highlights in 2.19 include_:
Expand All @@ -24,6 +22,8 @@ _Highlights in 2.19 include_:
- Using `parametrize` to set multiple fields in tandem
- And lots of smaller features, bugfixes, and general improvements

{/* truncate */}

Keep reading to see more, or check the [full release notes](https://github.com/pantsbuild/pants/tree/2.19.x/src/python/pants/notes/2.19.x.md). Pants is an open-source project, and the below changes are all contributed by our community. If you want to see something more in the next changelog, join us on [GitHub](https://github.com/pantsbuild/pants) and become a contributor.

We also offer [formal sponsorship tiers for companies](https://www.pantsbuild.org/sponsorship), as well as individual sponsorships via [GitHub](https://github.com/sponsors/pantsbuild). These help pay for the ongoing development and hosting costs, and are managed by the Pants Build non-profit organization.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,10 @@
[Unsplash](https://unsplash.com/photos/magnifying-glass-near-gray-laptop-computer-d9ILr-dbEdg)
</CaptionedImg>

{/* truncate */}

An important distinguishing feature of Pants v2 is its ability to automatically [infer your code's internal and external dependencies](https://www.pantsbuild.org/blog/2022/10/27/why-dependency-inference). The information about those inferences is available via the `dependencies` and `peek` goals, so that metadata about what modules import from other modules is always readily accessible to you.

{/* truncate */}

While managing a codebase in a [Pants-supported language](https://www.pantsbuild.org/2.18/docs/introduction/welcome-to-pants#which-languages-and-frameworks-does-pants-support) (e.g. Python, Java, Scala, etc...), it can sometimes be useful dig deeper and explore the inferred dependencies in order to compare them to your source code's import statements. This can be particularly useful for large modules with many imports, where it's very easy to miss an omitted dependency or an inferred dependency that should have been ignored.

You can start your exploration with one of the lesser known goals, [`python-dump-source-analysis`](https://www.pantsbuild.org/2.18/reference/goals/python-dump-source-analysis). This goal will dump the dependency analysis for the Python source code build targets.
Expand Down
4 changes: 2 additions & 2 deletions blog/2024-03-27-pants-2-20/index.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,6 @@
[Unsplash](https://unsplash.com/photos/moon-eclipse-F-pSZO_jeE8)
</CaptionedImg>

{/* truncate */}

We are pleased to announce Pants 2.20.0, the latest release of [Pantsbuild, the scalable and ergonomic build system](https://www.pantsbuild.org/). To update, set `pants_version = "2.20.0"` in your `pants.toml`. If you're not using Pants yet, [get started now](https://www.pantsbuild.org/docs/getting-started).

_Highlights in 2.20 include_:
Expand All @@ -29,6 +27,8 @@ _Highlights in 2.20 include_:
- 🐋 Experimental support for [Podman](https://podman.io/) with `pants.backend.experimental.docker.podman`.
- 📈 And lots of smaller features, bugfixes, and general improvements

{/* truncate */}

Check out the [full release notes](https://github.com/pantsbuild/pants/tree/2.20.x/src/python/pants/notes/2.20.x.md). Pants is an open-source project, and the changes are all contributed by our community. If you want to see something more in the next changelog, join us on [GitHub](https://github.com/pantsbuild/pants) and become a contributor.

We also offer [formal sponsorship tiers for companies](https://www.pantsbuild.org/sponsorship), as well as individual sponsorships via [GitHub](https://github.com/sponsors/pantsbuild). These help pay for the ongoing development and hosting costs, and are managed by the Pants Build non-profit organization.
Expand Down
2 changes: 2 additions & 0 deletions blog/2024-04-27-simple-versioning-with-git-tags/index.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@ A frequently asked question on [Pants Slack](/community/getting-help) is how to
set a version - such as for a docker image, helm chart or Python distribution -
based on git state.

{/* truncate */}

Pants does have various solutions for this, but they tend to be too
complicated, or too limited:

Expand Down
4 changes: 2 additions & 2 deletions blog/2024-05-29-pants-2-21/index.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,6 @@
[Unsplash](https://unsplash.com/photos/a-purple-and-purple-sky-with-trees-in-the-foreground-tr1nv_cLVP0)
</CaptionedImg>

{/* truncate */}

We are pleased to announce Pants [2.21.0](<(https://github.com/pantsbuild/pants/tree/2.21.x/src/python/pants/notes/2.21.x.md)>), the latest release of [Pantsbuild, the scalable and ergonomic build system](https://www.pantsbuild.org/). To update, set `pants_version = "2.21.0"` in your `pants.toml`. If you're not using Pants yet, [get started now](https://www.pantsbuild.org/docs/getting-started).

_Highlights in [2.21](<(https://github.com/pantsbuild/pants/tree/2.21.x/src/python/pants/notes/2.21.x.md)>) include_:
Expand All @@ -29,6 +27,8 @@ _Highlights in [2.21](<(https://github.com/pantsbuild/pants/tree/2.21.x/src/pyth
- 🪜 Scalafix can now be run by Pants using the [new `pants.backend.experimental.scala.lint.scalafix` backend](https://www.pantsbuild.org/2.21/docs/jvm/java-and-scala#fix-scala-code).
- 📈 And lots of smaller features, update, bugfixes, and general improvements

{/* truncate */}

Check out the [full release notes](https://github.com/pantsbuild/pants/tree/2.21.x/src/python/pants/notes/2.21.x.md). Pants is an open-source project, and the changes are all contributed by our community. If you want to see something more in the next changelog, join us on [GitHub](https://github.com/pantsbuild/pants) and become a contributor.

We also offer [formal sponsorship tiers for companies](https://www.pantsbuild.org/sponsorship), as well as individual sponsorships via [GitHub](https://github.com/sponsors/pantsbuild). These help pay for the ongoing development and hosting costs, and are managed by the Pants Build non-profit organization.
Expand Down
2 changes: 2 additions & 0 deletions blog/2024-06-13-announcing-klaviyo-sponsorship/index.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@

Today we are excited to announce that [Klaviyo](https://www.klaviyo.com/) has become the first Platinum sponsor of the Pants project via the [corporate sponsorship program](https://www.pantsbuild.org/sponsorship#corporate-sponsorship)! This is one of the first such sponsorships through our new [Open Source Sponsorship program](https://klaviyo.tech/inaugurating-our-open-source-sponsorship-program-df0572cc9c18), through which we are trying to support the open source projects we depend on. While the core development and maintenance of Pants is volunteer driven, there are costs involved with maintaining and distributing such a large piece of software, costs which far too often are covered by individual volunteers. We benefit enormously from this project and want to help contribute to its ongoing success.

{/* truncate */}

Klaviyo chose Pants as the build system for our backend monorepo 18 months ago (read about how we chose Pants [here](https://klaviyo.tech/why-we-chose-pants-906891a98a6e)). Since then, we have been impressed not only by the power, flexibility and ease of use relative to other systems that Pants offers, but also by the amazing community that surrounds it. It is truly the Pants community that sets it apart, from active development efforts to the vibrant and welcoming Slack. This community is a prime reason we chose Pants, and is what we hope to foster with our sponsorship.

Like all software of this size, we recognize there are costs associated with the development of Pants - from compute costs for CI, to hosting for the incredible documentation site. We are happy to help fund these costs so that the project and community can continue to grow. We hope that our initial sponsorship will prompt other commercial businesses using Pants to do the same, at any level of support, helping to support a growing Pants community for years to come.
2 changes: 2 additions & 0 deletions blog/2024-07-01-building-linux-on-osx-silicon/index.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,8 @@

Pants has supported running portions of the build in docker containers for [a while](https://www.pantsbuild.org/blog/2023/02/24/pants-2-15), but the exact configuration is a little tricky, particularly if you want to build x86_64 containers on Apple ARM processors.

{/* truncate */}

The recipe itself is very straight forward, adding these two sections to your root BUILD and pants.toml files will build your python binaries and docker containers for Linux/x64 on both Linux & OSX:

```bash title="BUILD"
Expand Down
4 changes: 2 additions & 2 deletions blog/2024-08-24-venerable-pythons/index.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,10 @@
[Unsplash](https://unsplash.com/photos/python-resting-its-head-on-body-yrcaXCWe0VY)
</CaptionedImg>

{/* truncate */}

The Python development community concurrently supports multiple version of the Python programming language. These are in various states such as "prerelease", "bugfix", "security", or "end-of-life". For example version 3.12 is currently in "bugfix" while 3.8 is the oldest still receiving security updates. The cadence of future release is currently governed by [PEP 602 – Annual Release Cycle for Python](https://peps.python.org/pep-0602/)

{/* truncate */}

Circa 2024 the state of [all Python versions](https://devguide.python.org/versions/) look something like:

![CPython Release Status](./cpython-release-status.png)
Expand Down

0 comments on commit 542bd02

Please sign in to comment.