docs: document offline export workflow (#79)

This commit is contained in:
Ben Younes
2026-07-16 18:25:07 +01:00
committed by GitHub
parent b22c037bed
commit f83a1900a0
2 changed files with 48 additions and 0 deletions
+16
View File
@@ -66,6 +66,22 @@ normally — pxpipe compresses the *request* only, never the model's output.
Recent turns stay text; the system prompt, tool docs, and older bulk history
are imaged.
## Offline export (no proxy)
You can render text, files, or diffs to PNG pages without running the proxy or
connecting Claude Code:
```bash
pxpipe export src/
cat prompt.txt | pxpipe export --stdin
pxpipe export --git
```
The command writes an output folder containing `page-*.png`, `factsheet.txt`,
`manifest.json`, and `prompt.txt`. Upload the PNG pages and paste the prompt
into image-upload clients such as Cursor when you want dense visual context
without running the proxy.
## The honest part
- **It is lossy.** Exact 12-char hex strings in dense imaged content:
+32
View File
@@ -0,0 +1,32 @@
import { describe, expect, it } from 'vitest';
import * as fs from 'node:fs';
const README_PATH = 'README.md';
const OFFLINE_EXPORT_HEADING = '## Offline export (no proxy)';
const REQUIRED_OFFLINE_EXPORT_TEXT = [
'pxpipe export',
'--stdin',
'--git',
'page-*.png',
'factsheet.txt',
'prompt.txt',
'Cursor',
'without running the proxy',
] as const;
describe('README offline export documentation', () => {
it('documents the proxy-free image export workflow', () => {
const readme = fs.readFileSync(README_PATH, 'utf8');
const sectionStart = readme.indexOf(OFFLINE_EXPORT_HEADING);
expect(sectionStart).toBeGreaterThanOrEqual(0);
const nextSectionStart = readme.indexOf('\n## ', sectionStart + OFFLINE_EXPORT_HEADING.length);
const section =
nextSectionStart === -1 ? readme.slice(sectionStart) : readme.slice(sectionStart, nextSectionStart);
for (const requiredText of REQUIRED_OFFLINE_EXPORT_TEXT) {
expect(section).toContain(requiredText);
}
});
});