Claude Skill

compile-latex

Compile a Beamer LaTeX slide deck with XeLaTeX (3 passes + bibtex). Use when user says "compile", "build the slides", "rebuild the PDF", "run latex", "render the tex", or asks why a `.tex` file isn't producing a PDF. Operates on `Slides/*.tex`.

LLM Mart · 0 points · 1 views 0 listing impressions 0 install-command copies
Download pedrohcgs-claude-code-my-workflow-.claude_skills_compile-latex-fe70774.zip · 0 KB

Install

skills CLI npx skills add https://github.com/pedrohcgs/claude-code-my-workflow/tree/main/.claude/skills/compile-latex
Claude Code claude plugin marketplace add https://llmmart.ai/marketplace.json && claude plugin install pedrohcgs-claude-code-my-workflow@llmmart
Git git clone https://github.com/pedrohcgs/claude-code-my-workflow.git

The skills CLI installs just this skill, for any of its supported agents. Claude Code installs the whole pedrohcgs/claude-code-my-workflow collection as a plugin from our marketplace. Git is the plain clone.

Skill manifest

Compile Beamer LaTeX Slides

Compile a Beamer slide deck using XeLaTeX with full citation resolution.

Steps

  1. Navigate to Slides/ directory and compile with 3-pass sequence:
cd Slides
TEXINPUTS=../Preambles:$TEXINPUTS xelatex -interaction=nonstopmode $ARGUMENTS.tex
BIBINPUTS=..:$BIBINPUTS bibtex $ARGUMENTS
TEXINPUTS=../Preambles:$TEXINPUTS xelatex -interaction=nonstopmode $ARGUMENTS.tex
TEXINPUTS=../Preambles:$TEXINPUTS xelatex -interaction=nonstopmode $ARGUMENTS.tex

Alternative (latexmk):

cd Slides
TEXINPUTS=../Preambles:$TEXINPUTS BIBINPUTS=..:$BIBINPUTS latexmk -xelatex -interaction=nonstopmode $ARGUMENTS.tex
  1. Check for warnings:

    • Grep output for Overfull \\hbox warnings
    • Grep for undefined citations or Label(s) may have changed
    • Report any issues found
  2. Open the PDF for visual verification:

    open Slides/$ARGUMENTS.pdf          # macOS
    # xdg-open Slides/$ARGUMENTS.pdf    # Linux
    
  3. Report results:

    • Compilation success/failure
    • Number of overfull hbox warnings
    • Any undefined citations
    • PDF page count

Why 3 passes?

  1. First xelatex: Creates .aux file with citation keys
  2. bibtex: Reads .aux, generates .bbl with formatted references
  3. Second xelatex: Incorporates bibliography
  4. Third xelatex: Resolves all cross-references with final page numbers

Important

  • Always use XeLaTeX, never pdflatex
  • TEXINPUTS is required: your Beamer theme lives in Preambles/
  • BIBINPUTS is required: your .bib file lives in the repo root
Files (claude-code-my-workflow)
  • SKILL.md 1.9 KB
    ---
    name: compile-latex
    description: Compile a Beamer LaTeX slide deck with XeLaTeX (3 passes + bibtex). Use when user says "compile", "build the slides", "rebuild the PDF", "run latex", "render the tex", or asks why a `.tex` file isn't producing a PDF. Operates on `Slides/*.tex`.
    argument-hint: "[filename without .tex extension]"
    allowed-tools: ["Read", "Bash", "Glob"]
    ---
    
    # Compile Beamer LaTeX Slides
    
    Compile a Beamer slide deck using XeLaTeX with full citation resolution.
    
    ## Steps
    
    1. **Navigate to Slides/ directory** and compile with 3-pass sequence:
    
    ```bash
    cd Slides
    TEXINPUTS=../Preambles:$TEXINPUTS xelatex -interaction=nonstopmode $ARGUMENTS.tex
    BIBINPUTS=..:$BIBINPUTS bibtex $ARGUMENTS
    TEXINPUTS=../Preambles:$TEXINPUTS xelatex -interaction=nonstopmode $ARGUMENTS.tex
    TEXINPUTS=../Preambles:$TEXINPUTS xelatex -interaction=nonstopmode $ARGUMENTS.tex
    ```
    
    **Alternative (latexmk):**
    ```bash
    cd Slides
    TEXINPUTS=../Preambles:$TEXINPUTS BIBINPUTS=..:$BIBINPUTS latexmk -xelatex -interaction=nonstopmode $ARGUMENTS.tex
    ```
    
    2. **Check for warnings:**
       - Grep output for `Overfull \\hbox` warnings
       - Grep for `undefined citations` or `Label(s) may have changed`
       - Report any issues found
    
    3. **Open the PDF** for visual verification:
       ```bash
       open Slides/$ARGUMENTS.pdf          # macOS
       # xdg-open Slides/$ARGUMENTS.pdf    # Linux
       ```
    
    4. **Report results:**
       - Compilation success/failure
       - Number of overfull hbox warnings
       - Any undefined citations
       - PDF page count
    
    ## Why 3 passes?
    1. First xelatex: Creates `.aux` file with citation keys
    2. bibtex: Reads `.aux`, generates `.bbl` with formatted references
    3. Second xelatex: Incorporates bibliography
    4. Third xelatex: Resolves all cross-references with final page numbers
    
    ## Important
    - **Always use XeLaTeX**, never pdflatex
    - **TEXINPUTS** is required: your Beamer theme lives in `Preambles/`
    - **BIBINPUTS** is required: your `.bib` file lives in the repo root
    

Comments (0)

Sign in to join the conversation.

No comments yet.

Reviews (0)

No reviews yet.