Serve a `.md` file on localhost with rendered HTML preview.
Scanned 5/27/2026
Install via CLI
openskills install Voxos-ai-Inc/tas# /preview — Markdown Preview Server
Serve a `.md` file on localhost with rendered HTML preview.
## Usage
`/preview <path-to-md-file>`
If no file path is given, ask the user which `.md` file to preview.
## Behavior
1. Resolve the absolute path to the target `.md` file.
2. Create a minimal Node.js server script (in a temp location) that:
- Reads the `.md` file from disk on each request (so edits are reflected on refresh).
- Converts Markdown to HTML using a `<script>` tag loading **marked** from CDN.
- Wraps the output in a clean HTML page with GitHub-style CSS from CDN.
- Serves on `localhost:3333` (if taken, try 3334, 3335, etc.).
3. Start the server in the background.
4. Print the URL to the user: `Preview: http://localhost:<port>`
## Server Template
Use this inline HTML approach (no npm install needed):
```js
const http = require('http');
const fs = require('fs');
const path = require('path');
const FILE = process.argv[2];
const PORT = parseInt(process.argv[3] || '3333', 10);
const html = (md) => `<!DOCTYPE html>
<html><head>
<meta charset="utf-8">
<title>${path.basename(FILE)}</title>
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/github-markdown-css/github-markdown.css">
<style>
body { max-width: 800px; margin: 40px auto; padding: 0 20px; background: #fff; }
.markdown-body { font-size: 16px; }
</style>
<script src="https://cdn.jsdelivr.net/npm/marked/marked.min.js"></script>
</head><body>
<div class="markdown-body" id="content"></div>
<script>
document.getElementById('content').innerHTML = marked.parse(${JSON.stringify(md)});
</script>
</body></html>`;
const server = http.createServer((req, res) => {
const md = fs.readFileSync(FILE, 'utf-8');
res.writeHead(200, { 'Content-Type': 'text/html; charset=utf-8' });
res.end(html(md));
});
server.listen(PORT, () => console.log('Preview: http://localhost:' + PORT));
```
## Key Rules
- No `npm install` — use only Node.js built-ins + CDN scripts.
- Re-read the file on every HTTP request so the user sees live changes on browser refresh.
- Run the server in the background so the conversation continues.
No comments yet. Be the first to comment!
Playbook for creating and editing uCoz landing pages via MCP tools (`templates_tool`, `ftp_tool`, `modules_tool`). Use for tasks such as: "build a landing page", "update the homepage as a landing page", "create a promo page on the homepage", "add a lead form / menu / SEO to the homepage". Homepage: `page_list`, `page_get`; first publish — `page_update` with full `page_tmpl`; HTML edits after generation — `patch_template` (module_id=2, template_id=1), not `update_template`. Activate the mail f...
Interact with the Paperclip control plane API to manage tasks, coordinate with other agents, and follow company governance. Use when you need to check assignments, update task status, delegate work, post comments, set up or manage routines (recurring scheduled tasks), or call any Paperclip API endpoint. Do NOT use for the actual domain work itself (writing code, research, etc.) — only for Paperclip coordination.
Digital Audio Workstation usage, music composition, interactive music systems, and game audio implementation for immersive soundscapes.
Instantly.ai cold email outreach API - manage campaigns, leads, accounts, and analytics. Use for cold email automation, lead management, campaign creation/monitoring, and email account warmup.
Run a single Terminal-Bench problem through Paperclip in a bounded, human-in-the-loop improvement cycle until the smoke passes, the board rejects the next fix, the iteration budget is exhausted, or a real blocker is named. Each iteration runs a bounded smoke against an isolated Paperclip App worktree, captures artifacts, diagnoses the exact stop point with `/diagnose-why-work-stopped`, requests board confirmation before any product fix, then reruns against the same worktree. Use whenever an i...