Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
66 changes: 66 additions & 0 deletions _download.html
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,32 @@
.visible {
transition-duration: 1s;
}
.checksum {
cursor: pointer;
color: rgba(var(--bs-link-color-rgb), var(--bs-link-opacity, 1));
text-decoration: underline;
position: relative;
display: inline-block;
/* Added to ensure proper tooltip positioning */
}
.copy-feedback {
position: absolute;
background: rgba(0, 0, 0, 0.8);
color: white;
padding: 4px 8px;
border-radius: 4px;
font-size: 12px;
bottom: 100%;
left: 50%;
transform: translateX(-50%);
white-space: nowrap;
z-index: 1000;
opacity: 0;
transition: opacity 0.2s ease-in-out;
}
.copy-feedback.visible {
opacity: 1;
}
</style>

<script type="application/javascript">
Expand Down Expand Up @@ -51,4 +77,44 @@
function updatePrivacy(checkbox) {
setLinkEnablement(checkbox.checked);
}

function copyChecksum(text, element) {
// Remove any existing feedback elements
const existingFeedback = element.querySelector('.copy-feedback');
if (existingFeedback) {
existingFeedback.remove();
}

// Create feedback element
const feedback = document.createElement('div');
feedback.className = 'copy-feedback';
feedback.textContent = 'Copied!';
element.appendChild(feedback);

// Copy to clipboard
navigator.clipboard.writeText(text).then(() => {
// Show feedback
requestAnimationFrame(() => {
feedback.classList.add('visible');

// Hide and remove feedback after delay
setTimeout(() => {
feedback.classList.remove('visible');
setTimeout(() => {
feedback.remove();
}, 200); // Remove after fade out
}, 1000);
});
}).catch((err) => {
console.error('Failed to copy text: ', err);
feedback.textContent = 'Failed to copy';
feedback.classList.add('visible');
setTimeout(() => {
feedback.classList.remove('visible');
setTimeout(() => {
feedback.remove();
}, 200);
}, 1000);
});
}
</script>
4 changes: 2 additions & 2 deletions _freeze/download/execute-results/html.json
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
{
"hash": "4c298204fb3b3de18c489809e2a2942b",
"hash": "ed6aa54fd60aa2e0e89a5768052bfc03",
"result": {
"engine": "knitr",
"markdown": "---\ntitle: \"Download Positron\"\nparams:\n version: \"2025.06.0-167\"\nformat:\n html:\n include-in-header:\n - '_download.html'\n\n---\n\n### Positron on desktop\n\nFind out what you need to know to [get started](start.qmd) using Positron, then download the desktop installer for your platform.\n\n::: callout-important\n## Accept license agreement\n\nPlease review [Positron's license agreement](licensing.qmd) and [privacy policy](https://posit.co/about/privacy-policy/). Your acceptance of this license agreement and privacy policy is required as a condition to proceeding with your download or use of the software.\n\n<div id=\"privacy-policy-agreement\">\n <input type=\"checkbox\" id=\"privacy-checkbox\" onclick=\"updatePrivacy(this)\">\n <label>I agree to the [Positron license agreement](licensing.qmd) and [Posit Privacy Policy](https://posit.co/about/privacy-policy/).</label>\n</div>\n:::\n\n\n\n::: {.cell .plain id='download-table'}\n::: {.cell-output-display}\n\n\n|Platform |Download |Size |\n|:-----------------------------------------|:------------------------------------|:----|\n|Windows 10, 11 x64 (system level install) |[Positron-2025.06.0-167-Setup.exe](https://cdn.posit.co/positron/prereleases/win/x86_64/Positron-2025.06.0-167-Setup.exe)|312M |\n|Windows 10, 11 x64 (user level install) |[Positron-2025.06.0-167-UserSetup.exe](https://cdn.posit.co/positron/prereleases/win/x86_64/Positron-2025.06.0-167-UserSetup.exe)|312M |\n|MacOS 10.15+ (universal) |[Positron-2025.06.0-167.dmg](https://cdn.posit.co/positron/prereleases/mac/universal/Positron-2025.06.0-167.dmg)|773M |\n|Debian-based Linux x64 (Ubuntu 20+) |[Positron-2025.06.0-167-x64.deb](https://cdn.posit.co/positron/prereleases/deb/x86_64/Positron-2025.06.0-167-x64.deb)|310M |\n|Debian-based Linux arm64 (Ubuntu 20+) |[Positron-2025.06.0-167-arm64.deb](https://cdn.posit.co/positron/prereleases/deb/arm64/Positron-2025.06.0-167-arm64.deb)|304M |\n|Red Hat-based Linux x64 (RHEL9) |[Positron-2025.06.0-167-x64.rpm](https://cdn.posit.co/positron/prereleases/rpm/x86_64/Positron-2025.06.0-167-x64.rpm)|349M |\n|Red Hat-based Linux arm64 (RHEL9) |[Positron-2025.06.0-167-arm64.rpm](https://cdn.posit.co/positron/prereleases/rpm/arm64/Positron-2025.06.0-167-arm64.rpm)|344M |\n\n\n:::\n:::\n\n<br>\nOlder releases [are available on GitHub](https://github.com/posit-dev/positron/releases).\n\n### Positron Pro on Posit Workbench\n\n[Posit Workbench](https://posit.co/products/enterprise/workbench/) 2024.12.1 and later includes preview support for Positron Pro. To configure and use Positron Pro on Posit Workbench, please see the [Posit Workbench Administration Guide](https://docs.posit.co/ide/server-pro/positron_sessions/) and the [Positron Pro user guide](https://docs.posit.co/ide/server-pro/user/positron/getting-started/).\n",
"markdown": "---\ntitle: \"Download Positron\"\nparams:\n version: \"2025.06.0-167\"\nformat:\n html:\n include-in-header:\n - '_download.html'\n\n---\n\n\n\n\n### Positron on desktop\n\nFind out what you need to know to [get started](start.qmd) using Positron, then download the desktop installer for your platform.\n\n::: callout-important\n## Accept license agreement\n\nPlease review [Positron's license agreement](licensing.qmd) and [privacy policy](https://posit.co/about/privacy-policy/). Your acceptance of this license agreement and privacy policy is required as a condition to proceeding with your download or use of the software.\n\n<div id=\"privacy-policy-agreement\">\n <input type=\"checkbox\" id=\"privacy-checkbox\" onclick=\"updatePrivacy(this)\">\n <label>I agree to the [Positron license agreement](licensing.qmd) and [Posit Privacy Policy](https://posit.co/about/privacy-policy/).</label>\n</div>\n:::\n\n\n\n\n\n::: {.cell .plain id='download-table'}\n::: {.cell-output-display}\n`````{=html}\n<table>\n <thead>\n <tr>\n <th style=\"text-align:left;\"> Platform </th>\n <th style=\"text-align:left;\"> Download </th>\n <th style=\"text-align:left;\"> Size </th>\n <th style=\"text-align:left;\"> SHA-256 </th>\n </tr>\n </thead>\n<tbody>\n <tr>\n <td style=\"text-align:left;\"> Windows 10, 11 x64 (system level install) </td>\n <td style=\"text-align:left;\"> <a href=\"https://cdn.posit.co/positron/prereleases/win/x86_64/Positron-2025.06.0-167-Setup.exe\">Positron-2025.06.0-167-Setup.exe</a> </td>\n <td style=\"text-align:left;\"> 312M </td>\n <td style=\"text-align:left;\"> <span class=\"checksum\" onclick=\"copyChecksum('c42fe045ea859d5d58f36c5961da1c993683f36966c276558a0540e04609df80', this)\" title=\"Click to copy full checksum\">c42fe04</span> </td>\n </tr>\n <tr>\n <td style=\"text-align:left;\"> Windows 10, 11 x64 (user level install) </td>\n <td style=\"text-align:left;\"> <a href=\"https://cdn.posit.co/positron/prereleases/win/x86_64/Positron-2025.06.0-167-UserSetup.exe\">Positron-2025.06.0-167-UserSetup.exe</a> </td>\n <td style=\"text-align:left;\"> 312M </td>\n <td style=\"text-align:left;\"> <span class=\"checksum\" onclick=\"copyChecksum('251c751e03db66e50bc6a1e7a359317256861fbdaca8a89996c117b8cc4492fc', this)\" title=\"Click to copy full checksum\">251c751</span> </td>\n </tr>\n <tr>\n <td style=\"text-align:left;\"> MacOS 10.15+ (universal) </td>\n <td style=\"text-align:left;\"> <a href=\"https://cdn.posit.co/positron/prereleases/mac/universal/Positron-2025.06.0-167.dmg\">Positron-2025.06.0-167.dmg</a> </td>\n <td style=\"text-align:left;\"> 773M </td>\n <td style=\"text-align:left;\"> <span class=\"checksum\" onclick=\"copyChecksum('813178aba2feec6581a78d11b52cb2830d031c3729e3735cf67a567122a1f1a5', this)\" title=\"Click to copy full checksum\">813178a</span> </td>\n </tr>\n <tr>\n <td style=\"text-align:left;\"> Debian-based Linux x64 (Ubuntu 20+) </td>\n <td style=\"text-align:left;\"> <a href=\"https://cdn.posit.co/positron/prereleases/deb/x86_64/Positron-2025.06.0-167-x64.deb\">Positron-2025.06.0-167-x64.deb</a> </td>\n <td style=\"text-align:left;\"> 310M </td>\n <td style=\"text-align:left;\"> <span class=\"checksum\" onclick=\"copyChecksum('dae301bcd545f74108f9f4db614863d6b3e4c8dc5fe658d2d2d47b48261eba2f', this)\" title=\"Click to copy full checksum\">dae301b</span> </td>\n </tr>\n <tr>\n <td style=\"text-align:left;\"> Debian-based Linux arm64 (Ubuntu 20+) </td>\n <td style=\"text-align:left;\"> <a href=\"https://cdn.posit.co/positron/prereleases/deb/arm64/Positron-2025.06.0-167-arm64.deb\">Positron-2025.06.0-167-arm64.deb</a> </td>\n <td style=\"text-align:left;\"> 304M </td>\n <td style=\"text-align:left;\"> <span class=\"checksum\" onclick=\"copyChecksum('ab105ce82e31c21d799d021e9a443d3cd2526e18b3f3ab18f4adcf219b0f2b12', this)\" title=\"Click to copy full checksum\">ab105ce</span> </td>\n </tr>\n <tr>\n <td style=\"text-align:left;\"> Red Hat-based Linux x64 (RHEL9) </td>\n <td style=\"text-align:left;\"> <a href=\"https://cdn.posit.co/positron/prereleases/rpm/x86_64/Positron-2025.06.0-167-x64.rpm\">Positron-2025.06.0-167-x64.rpm</a> </td>\n <td style=\"text-align:left;\"> 349M </td>\n <td style=\"text-align:left;\"> <span class=\"checksum\" onclick=\"copyChecksum('74828bc6fd762f3e9d55bf21abfc1a0a9c99cbdfc743e61d1e0ade640fc25550', this)\" title=\"Click to copy full checksum\">74828bc</span> </td>\n </tr>\n <tr>\n <td style=\"text-align:left;\"> Red Hat-based Linux arm64 (RHEL9) </td>\n <td style=\"text-align:left;\"> <a href=\"https://cdn.posit.co/positron/prereleases/rpm/arm64/Positron-2025.06.0-167-arm64.rpm\">Positron-2025.06.0-167-arm64.rpm</a> </td>\n <td style=\"text-align:left;\"> 344M </td>\n <td style=\"text-align:left;\"> <span class=\"checksum\" onclick=\"copyChecksum('c6395724849994e0ad670fec7ef706a621884c875359656d48856ec5203eaf6e', this)\" title=\"Click to copy full checksum\">c639572</span> </td>\n </tr>\n</tbody>\n</table>\n\n`````\n:::\n:::\n\n\n\n<br>\nOlder releases [are available on GitHub](https://github.com/posit-dev/positron/releases).\n\n### Positron Pro on Posit Workbench\n\n[Posit Workbench](https://posit.co/products/enterprise/workbench/) 2024.12.1 and later includes preview support for Positron Pro. To configure and use Positron Pro on Posit Workbench, please see the [Posit Workbench Administration Guide](https://docs.posit.co/ide/server-pro/positron_sessions/) and the [Positron Pro user guide](https://docs.posit.co/ide/server-pro/user/positron/getting-started/).\n",
"supporting": [],
"filters": [
"rmarkdown/pagebreak.lua"
Expand Down
57 changes: 47 additions & 10 deletions download.qmd
Original file line number Diff line number Diff line change
Expand Up @@ -27,31 +27,61 @@ Please review [Positron's license agreement](licensing.qmd) and [privacy policy]

```{r, id='download-table'}
#| echo: false
#| warning: false
#| classes: plain
library(purrr)
library(glue)
library(httr)
library(jsonlite)
# Create URLs
cdn_url <- "https://cdn.posit.co/positron/prereleases/"
windows_system <- glue("Positron-{params$version}-Setup.exe")
windows_user <- glue("Positron-{params$version}-UserSetup.exe")
macos_universal <- glue("Positron-{params$version}.dmg")
debian_x64 <- glue("Positron-{params$version}-x64.deb")
debian_arm <- glue("Positron-{params$version}-arm64.deb")
redhat_x64 <- glue("Positron-{params$version}-x64.rpm")
redhat_arm <- glue("Positron-{params$version}-arm64.rpm")
urls <- list(
glue("{cdn_url}win/x86_64/Positron-{params$version}-Setup.exe"),
glue("{cdn_url}win/x86_64/Positron-{params$version}-UserSetup.exe"),
glue("{cdn_url}mac/universal/Positron-{params$version}.dmg"),
glue("{cdn_url}deb/x86_64/Positron-{params$version}-x64.deb"),
glue("{cdn_url}deb/arm64/Positron-{params$version}-arm64.deb"),
glue("{cdn_url}rpm/x86_64/Positron-{params$version}-x64.rpm"),
glue("{cdn_url}rpm/arm64/Positron-{params$version}-arm64.rpm")
glue("{cdn_url}win/x86_64/{windows_system}"),
glue("{cdn_url}win/x86_64/{windows_user}"),
glue("{cdn_url}mac/universal/{macos_universal}"),
glue("{cdn_url}deb/x86_64/{debian_x64}"),
glue("{cdn_url}deb/arm64/{debian_arm}"),
glue("{cdn_url}rpm/x86_64/{redhat_x64}"),
glue("{cdn_url}rpm/arm64/{redhat_arm}")
)
# Get checksums
checksum_data <- rlang::try_fetch(
fromJSON(glue("{cdn_url}checksums/positron-{params$version}-checksums.json")),
error = function(cnd) list(),
warning = function(cnd) list()
)
all_installers <- list(
windows_system,
windows_user,
macos_universal,
debian_x64,
debian_arm,
redhat_x64,
redhat_arm
)
checksums <- map_chr(all_installers, ~ pluck(checksum_data, .))
checksums_short <- substr(checksums, 1, 7)
# Get file sizes
cloudfront_headers <- map(urls, HEAD) |> map(headers)
file_sizes <- map(cloudfront_headers, "content-length") |>
map(fs::fs_bytes) |>
map_chr(as.character)
file_names_only <- stringr::str_extract(urls, "[^\\/]+$")
markdown_links <- glue("[{file_names_only}]({urls})")
markdown_links <- glue('<a href="{urls}">{file_names_only}</a>')
# Create base table without checksums
download_table <- data.frame(
Platform = c(
"Windows 10, 11 x64 (system level install)",
Expand All @@ -66,7 +96,14 @@ download_table <- data.frame(
Size = file_sizes
)
knitr::kable(download_table)
# Add checksums column if data is available
if (length(checksums) > 0) {
download_table$`SHA-256` <- glue(
'<span class="checksum" onclick="copyChecksum(\'{checksums}\', this)" title="Click to copy full checksum">{checksums_short}</span>'
)
}
knitr::kable(download_table, format = "html", escape = FALSE)
```
<br>
Older releases [are available on GitHub](https://github.com/posit-dev/positron/releases).
Expand Down