Skip to content

Fastest way to scaffold your LLM powered personal knowledge base - Obsidian, Claude Code, qmd, Github

fix(cli): show ~/... instead of full home path for qmd index prompt

Claude1e3f5d3414b5
diff --git a/bin/create.js b/bin/create.js
index 37325b3..cf6935e 100644
--- a/bin/create.js
+++ b/bin/create.js
@@ -281,11 +281,14 @@ async function main() {
process.env.XDG_CACHE_HOME || join(homedir(), ".cache"),
"qmd", "index.sqlite"
)
+ const displayQmdPath = defaultQmdPath.startsWith(homedir())
+ ? "~" + defaultQmdPath.slice(homedir().length)
+ : defaultQmdPath
let qmdPath
if (isInteractive) {
const answer = await p.text({
message: "Where to store the qmd index?",
- placeholder: defaultQmdPath,
+ placeholder: displayQmdPath,
defaultValue: defaultQmdPath,
})
if (p.isCancel(answer)) { p.cancel("Setup cancelled."); process.exit(0) }
@@ -360,7 +363,8 @@ async function main() {
// Patch vault files with chosen qmd path
spin.start("Configuring qmd index path")
await patchVault(targetDir, qmdPath, targetName)
- spin.stop(`qmd index → ${pc.dim(qmdPath)}`)
+ const displayPath = qmdPath.startsWith(homedir()) ? "~" + qmdPath.slice(homedir().length) : qmdPath
+ spin.stop(`qmd index → ${pc.dim(displayPath)}`)
// Install mise if not present
if (!commandExists("mise")) {