Hugoifier

hugoifier / docs / getting-started / quickstart.md
Source Blame History 58 lines
04b8794… lmata 1 # Quick Start
04b8794… lmata 2
04b8794… lmata 3 ## Convert a Hugo Theme
04b8794… lmata 4
04b8794… lmata 5 Most Hugo themes include an `exampleSite/` directory. Hugoifier assembles a complete, working site from it:
04b8794… lmata 6
04b8794… lmata 7 ```bash
04b8794… lmata 8 export ANTHROPIC_API_KEY=your_key
04b8794… lmata 9
04b8794… lmata 10 python src/cli.py complete themes/my-hugo-theme
04b8794… lmata 11 # → output/my-hugo-theme/
04b8794… lmata 12 ```
04b8794… lmata 13
04b8794… lmata 14 Then test it:
04b8794… lmata 15
04b8794… lmata 16 ```bash
04b8794… lmata 17 cd output/my-hugo-theme
04b8794… lmata 18 hugo serve
04b8794… lmata 19 # Open http://localhost:1313
04b8794… lmata 20 ```
04b8794… lmata 21
04b8794… lmata 22 The Decap CMS admin panel is automatically available at `http://localhost:1313/admin/`.
04b8794… lmata 23
04b8794… lmata 24 ## Convert Raw HTML
04b8794… lmata 25
04b8794… lmata 26 For a plain HTML/CSS theme:
04b8794… lmata 27
04b8794… lmata 28 ```bash
04b8794… lmata 29 python src/cli.py complete path/to/html-theme/
04b8794… lmata 30 # → output/html-theme/
04b8794… lmata 31 ```
04b8794… lmata 32
04b8794… lmata 33 Hugoifier sends the main HTML file to the AI backend and converts it to Hugo layout files (`_default/baseof.html`, `partials/header.html`, etc.).
04b8794… lmata 34
04b8794… lmata 35 ## Custom Output Directory
04b8794… lmata 36
04b8794… lmata 37 ```bash
04b8794… lmata 38 python src/cli.py complete themes/my-theme --output /tmp/my-site
04b8794… lmata 39 ```
04b8794… lmata 40
04b8794… lmata 41 ## Whitelabel Decap CMS
04b8794… lmata 42
04b8794… lmata 43 ```bash
04b8794… lmata 44 python src/cli.py complete themes/my-theme \
04b8794… lmata 45 --cms-name "My CMS" \
04b8794… lmata 46 --cms-color "#1a1a2e" \
04b8794… lmata 47 --cms-logo "https://example.com/logo.png"
04b8794… lmata 48 ```
04b8794… lmata 49
04b8794… lmata 50 ## Switch AI Backend
04b8794… lmata 51
04b8794… lmata 52 ```bash
04b8794… lmata 53 # Use OpenAI instead of Anthropic
04b8794… lmata 54 HUGOIFIER_BACKEND=openai OPENAI_API_KEY=your_key python src/cli.py complete themes/my-theme
04b8794… lmata 55
04b8794… lmata 56 # Or via CLI flag
04b8794… lmata 57 python src/cli.py --backend openai complete themes/my-theme
04b8794… lmata 58 ```

Keyboard Shortcuts

Open search /
Next entry (timeline) j
Previous entry (timeline) k
Open focused entry Enter
Show this help ?
Toggle theme Top nav button