Change documentation link to minor version (#2040)

We updated our website to use minor versions instead of full versions,
this updates our CLI to match.

See https://github.com/apple/pkl-lang.org/pull/195
This commit is contained in:
Daniel Chao authored and GitHub committed 2026-12-04 17:32:09 +00:00
1 parent a9022b64d9
commit 305a20874c
3 files changed
+3 -9

No files matched your search

@@ -95,7 +95,7 @@ internal object ReplMessages {
For more examples, see the Language Reference${if (isMacOs()) " (Command+Double-click the link below)" else ""}:
https://pkl-lang.org/main/current/language-reference/index.html
${Release.current().documentation().homepage()}language-reference/
"""
.trimIndent()
@@ -73,10 +73,4 @@ class ReplMessagesTest {
assertThat(responses.size).isEqualTo(1)
assertThat(responses).hasOnlyElementsOfType(ReplResponse.EvalError::class.java)
}
@Test
fun `examples link to the current language reference`() {
assertThat(ReplMessages.examples.trimEnd().lines().last())
.isEqualTo("https://pkl-lang.org/main/current/language-reference/index.html")
}
}
@@ -1,5 +1,5 @@
/*
* Copyright © 2024 Apple Inc. and the Pkl project authors. All rights reserved.
* Copyright © 2024-2026 Apple Inc. and the Pkl project authors. All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -71,7 +71,7 @@ public record Release(
var flavor = TruffleOptions.AOT ? "native" : "Java " + System.getProperty("java.version");
var versionInfo = "Pkl " + version + " (" + os + ", " + flavor + ")";
var commitish = version.isNormal() ? version.toString() : commitId;
var docsVersion = version.isNormal() ? version.toString() : "latest";
var docsVersion = version.isNormal() ? version.getMajor() + "." + version.getMinor() : "latest";
var docsHomepage = DOCUMENTATION_HOMEPAGE + docsVersion + "/";
var stdlibModules =
new LinkedHashSet<>(List.of(properties.getProperty("stdlibModules").split(",")));