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
1 change: 1 addition & 0 deletions news/changelog-1.6.md
Original file line number Diff line number Diff line change
Expand Up @@ -117,3 +117,4 @@ All changes included in 1.6:
- ([#10890](https://github.com/quarto-dev/quarto-cli/issues/10890)): Don't use ports that Firefox considers unsafe.
- ([#10936](https://github.com/quarto-dev/quarto-cli/issues/10936)): Use `\\` in `meta` shortcode to escape the following character, allowing keys with `.` in them.
- ([#11068](https://github.com/quarto-dev/quarto-cli/issues/11068)): use standard location when writing to standard output to avoid breakage under `self-contained: true`.
- ([#11155](https://github.com/quarto-dev/quarto-cli/pull/11155)): Add cache location information to `quarto check`.
19 changes: 18 additions & 1 deletion src/command/check/check.ts
Original file line number Diff line number Diff line change
Expand Up @@ -45,15 +45,25 @@ import { which } from "../../core/path.ts";
import { dirname } from "../../deno_ral/path.ts";
import { notebookContext } from "../../render/notebook/notebook-context.ts";
import { typstBinaryPath } from "../../core/typst.ts";
import { quartoCacheDir } from "../../core/appdirs.ts";

const kIndent = " ";

export type Target = "install" | "jupyter" | "knitr" | "versions" | "all";
export type Target =
| "install"
| "jupyter"
| "knitr"
| "versions"
| "info"
| "all";

export async function check(target: Target): Promise<void> {
const services = renderServices(notebookContext());
try {
info(`Quarto ${quartoConfig.version()}`);
if (target === "info" || target === "all") {
await checkInfo(services);
}
if (target === "versions" || target === "all") {
await checkVersions(services);
}
Expand All @@ -71,6 +81,13 @@ export async function check(target: Target): Promise<void> {
}
}

// Currently this doesn't check anything, but
async function checkInfo(_services: RenderServices) {
const cacheDir = quartoCacheDir();
completeMessage("Checking environment information...");
info(kIndent + "Quarto cache location: " + cacheDir);
}

async function checkVersions(_services: RenderServices) {
const checkVersion = async (
version: string | undefined,
Expand Down
Loading