Skip to content

Commit b9becf9

Browse files
committed
Use kIndent everywhere to ensure same spacing in checks
1 parent 3273cb1 commit b9becf9

File tree

1 file changed

+15
-15
lines changed

1 file changed

+15
-15
lines changed

src/command/check/check.ts

Lines changed: 15 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -141,7 +141,7 @@ async function checkVersions(_services: RenderServices) {
141141

142142
async function checkInstall(services: RenderServices) {
143143
completeMessage("Checking Quarto installation......OK");
144-
info(` Version: ${quartoConfig.version()}`);
144+
info(`${kIndent}Version: ${quartoConfig.version()}`);
145145
if (quartoConfig.version() === "99.9.9") {
146146
// if they're running a dev version, we assume git is installed
147147
// and QUARTO_ROOT is set to the root of the quarto-cli repo
@@ -154,34 +154,34 @@ async function checkInstall(services: RenderServices) {
154154
stderr: "piped", // to not show error if not in a git repo
155155
});
156156
if (gitHead.success && gitHead.stdout) {
157-
info(` commit: ${gitHead.stdout.trim()}`);
157+
info(`${kIndent}commit: ${gitHead.stdout.trim()}`);
158158
}
159159
}
160160
}
161-
info(` Path: ${quartoConfig.binPath()}`);
161+
info(`${kIndent}Path: ${quartoConfig.binPath()}`);
162162
if (Deno.build.os === "windows") {
163163
try {
164164
const codePage = readCodePage();
165165
clearCodePageCache();
166166
await cacheCodePage();
167167
const codePage2 = readCodePage();
168168

169-
info(` CodePage: ${codePage2 || "unknown"}`);
169+
info(`${kIndent}CodePage: ${codePage2 || "unknown"}`);
170170
if (codePage && codePage !== codePage2) {
171171
info(
172-
` NOTE: Code page updated from ${codePage} to ${codePage2}. Previous rendering may have been affected.`,
172+
`${kIndent}NOTE: Code page updated from ${codePage} to ${codePage2}. Previous rendering may have been affected.`,
173173
);
174174
}
175175
// if non-standard code page, check for non-ascii characters in path
176176
// deno-lint-ignore no-control-regex
177177
const nonAscii = /[^\x00-\x7F]+/;
178178
if (nonAscii.test(quartoConfig.binPath())) {
179179
info(
180-
` ERROR: Non-ASCII characters in Quarto path causes rendering problems.`,
180+
`${kIndent}ERROR: Non-ASCII characters in Quarto path causes rendering problems.`,
181181
);
182182
}
183183
} catch {
184-
info(` CodePage: Unable to read code page`);
184+
info(`${kIndent}CodePage: Unable to read code page`);
185185
}
186186
}
187187

@@ -196,10 +196,10 @@ async function checkInstall(services: RenderServices) {
196196

197197
for (const tool of tools.installed) {
198198
const version = await tool.installedVersion() || "(external install)";
199-
toolsOutput.push(` ${tool.name}: ${version}`);
199+
toolsOutput.push(`${kIndent}${tool.name}: ${version}`);
200200
}
201201
for (const tool of tools.notInstalled) {
202-
toolsOutput.push(` ${tool.name}: (not installed)`);
202+
toolsOutput.push(`${kIndent}${tool.name}: (not installed)`);
203203
}
204204
});
205205
toolsOutput.forEach((out) => info(out));
@@ -218,19 +218,19 @@ async function checkInstall(services: RenderServices) {
218218
if (tlContext.usingGlobal) {
219219
const tlMgrPath = await which("tlmgr");
220220

221-
latexOutput.push(` Using: Installation From Path`);
221+
latexOutput.push(`${kIndent}Using: Installation From Path`);
222222
if (tlMgrPath) {
223-
latexOutput.push(` Path: ${dirname(tlMgrPath)}`);
223+
latexOutput.push(`${kIndent}Path: ${dirname(tlMgrPath)}`);
224224
}
225225
} else {
226-
latexOutput.push(` Using: TinyTex`);
226+
latexOutput.push(`${kIndent}Using: TinyTex`);
227227
if (tlContext.binDir) {
228-
latexOutput.push(` Path: ${tlContext.binDir}`);
228+
latexOutput.push(`${kIndent}Path: ${tlContext.binDir}`);
229229
}
230230
}
231-
latexOutput.push(` Version: ${version}`);
231+
latexOutput.push(`${kIndent}Version: ${version}`);
232232
} else {
233-
latexOutput.push(` Tex: (not detected)`);
233+
latexOutput.push(`${kIndent}Tex: (not detected)`);
234234
}
235235
});
236236
latexOutput.forEach((out) => info(out));

0 commit comments

Comments
 (0)