Skip to content

seo-see/cursor_latex

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 

History

5 Commits
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

๐Ÿ“˜ LaTeX in Cursor / Cursor์—์„œ LaTeX ์‚ฌ์šฉํ•˜๊ธฐ

This guide explains how to set up and use LaTeX in Cursor.
์ด ๊ฐ€์ด๋“œ๋Š” Cursor ์—๋””ํ„ฐ์—์„œ LaTeX ํ™˜๊ฒฝ์„ ์„ค์ •ํ•˜๊ณ  ์‚ฌ์šฉํ•˜๋Š” ๋ฐฉ๋ฒ•์„ ์„ค๋ช…ํ•ฉ๋‹ˆ๋‹ค.


๐ŸŒ Language | ์–ธ์–ด


๐Ÿ‡บ๐Ÿ‡ธ English Guide

1. Setup

1.1 Install Extension

  • Install the LaTeX Workshop extension
    โ†’ Provides useful LaTeX editing features

1.2 Install LaTeX Distribution

Choose one:

1.3 Configure Cursor

  1. Open Preferences: Open Settings (JSON) (Shift+Command+P)
  2. Add the following:
{
  "latex.linter.enabled": false,
  "[latex]": {
    "editor.formatOnPaste": false,
    "editor.suggestSelection": "recentlyUsedByPrefix"
  },
  "latex-workshop.latex.tools": [
    {
      "name": "xelatex",
      "command": "xelatex",
      "args": [
        "-synctex=1",
        "-interaction=nonstopmode",
        "-file-line-error",
        "%DOC%"
      ]
    }
  ],
  "latex-workshop.latex.recipes": [
    {
      "name": "xelatex",
      "tools": [
        "xelatex"
      ]
    }
  ]
}

2. Writing LaTeX

2.1 Create File

  • Create a new .tex file

2.2 Example Structure

\documentclass{article}
\usepackage{xeCJK} % For Korean or CJK fonts
\begin{document}
Hello, LaTeX!
\end{document}

3. Compile & BibTeX

3.1 Compilation Steps

Use a Makefile to automate:

3.2 BibTeX

Instead of configuring BibTeX inside Cursor, use a Makefile to manage everything.


4. Using Makefile

4.1 Sample Makefile

.PHONY: all clean

all: manuscript.pdf

manuscript.pdf: manuscript.tex references.bib
	xelatex manuscript.tex
	bibtex manuscript
	xelatex manuscript.tex
	xelatex manuscript.tex

clean:
	rm -f *.aux *.bbl *.blg *.log *.out *.toc *.synctex.gz *.pdf

4.2 Run in Terminal

  • Build PDF: make
  • Clean files: make clean

4.3 Use in Cursor

  1. Install Task Explorer extension
  2. Open the Task Explorer from the sidebar
  3. Run make or make clean with one click

๐Ÿ‡ฐ๐Ÿ‡ท ํ•œ๊ตญ์–ด ๊ฐ€์ด๋“œ

1. ์ค€๋น„ ๋‹จ๊ณ„

1.1 ํ™•์žฅ ํ”„๋กœ๊ทธ๋žจ ์„ค์น˜

  • LaTeX Workshop ํ™•์žฅ ํ”„๋กœ๊ทธ๋žจ ์„ค์น˜
    โ†’ LaTeX ๋ฌธ์„œ ์ž‘์„ฑ์„ ์œ„ํ•œ ๊ธฐ๋Šฅ ์ œ๊ณต

1.2 LaTeX ๋ฐฐํฌํŒ ์„ค์น˜

์•„๋ž˜ ์ค‘ ํ•˜๋‚˜ ์„ค์น˜:

1.3 ๊ธฐ๋ณธ ์„ค์ •

  1. Shift+Command+P โ†’ Preferences: Open Settings (JSON) ์„ ํƒ
  2. ์•„๋ž˜ ๋‚ด์šฉ ์‚ฝ์ž…:
{
  "latex.linter.enabled": false,
  "[latex]": {
    "editor.formatOnPaste": false,
    "editor.suggestSelection": "recentlyUsedByPrefix"
  },
  "latex-workshop.latex.tools": [
    {
      "name": "xelatex",
      "command": "xelatex",
      "args": [
        "-synctex=1",
        "-interaction=nonstopmode",
        "-file-line-error",
        "%DOC%"
      ]
    }
  ],
  "latex-workshop.latex.recipes": [
    {
      "name": "xelatex",
      "tools": [
        "xelatex"
      ]
    }
  ]
}

2. LaTeX ๋ฌธ์„œ ์ž‘์„ฑ

2.1 ์ƒˆ ๋ฌธ์„œ ๋งŒ๋“ค๊ธฐ

  • .tex ํ™•์žฅ์ž๋กœ ํŒŒ์ผ ์ƒ์„ฑ

2.2 ๋ฌธ์„œ ์˜ˆ์‹œ

\documentclass{article}
\usepackage{xeCJK} % ํ•œ๊ธ€ ๋˜๋Š” CJK ํฐํŠธ ์‚ฌ์šฉ
\begin{document}
์•ˆ๋…•ํ•˜์„ธ์š”, LaTeX!
\end{document}

3. ์ปดํŒŒ์ผ ๋ฐ BibTeX

3.1 ์ปดํŒŒ์ผ ์ˆœ์„œ

  • Makefile์„ ์‚ฌ์šฉํ•˜๋ฉด ์ž๋™ํ™” ๊ฐ€๋Šฅ

3.2 BibTeX ์„ค์ •

  • Cursor์—์„œ ์ง์ ‘ ์‹คํ–‰ํ•˜๊ธฐ๋ณด๋‹ค Makefile๋กœ ๊ด€๋ฆฌํ•˜๋Š” ๊ฒƒ์„ ์ถ”์ฒœ

4. Makefile ์‚ฌ์šฉํ•˜๊ธฐ

4.1 Makefile ์˜ˆ์‹œ

.PHONY: all clean

all: manuscript.pdf

manuscript.pdf: manuscript.tex references.bib
	xelatex manuscript.tex
	bibtex manuscript
	xelatex manuscript.tex
	xelatex manuscript.tex

clean:
	rm -f *.aux *.bbl *.blg *.log *.out *.toc *.synctex.gz *.pdf

4.2 ํ„ฐ๋ฏธ๋„์—์„œ ์‹คํ–‰

  • PDF ์ƒ์„ฑ: make
  • ํŒŒ์ผ ์‚ญ์ œ: make clean

4.3 Cursor์—์„œ ์‹คํ–‰

  1. Task Explorer ํ™•์žฅ ํ”„๋กœ๊ทธ๋žจ ์„ค์น˜
  2. ์‚ฌ์ด๋“œ๋ฐ”์—์„œ Task Explorer ์•„์ด์ฝ˜ ํด๋ฆญ
  3. make, make clean ํƒœ์Šคํฌ๋ฅผ ํด๋ฆญํ•˜์—ฌ ์‹คํ–‰


โš–๏ธ Ethical Considerations / ์œค๋ฆฌ์  ๊ณ ๋ ค์‚ฌํ•ญ

This guide includes the use of AI tools such as Copilot and Cursor.
These tools are intended to assist in formatting, writing, and document preparation.
All scientific content, citations, and conclusions must be verified and validated by the human author.

์ด ๊ฐ€์ด๋“œ๋Š” Copilot, Cursor์™€ ๊ฐ™์€ AI ๋„๊ตฌ์˜ ์‚ฌ์šฉ์„ ํฌํ•จํ•ฉ๋‹ˆ๋‹ค.
์ด๋Ÿฌํ•œ ๋„๊ตฌ๋Š” ๋ฌธ์„œ ์ž‘์„ฑ ๋ฐ ํ˜•์‹์„ ์ง€์›ํ•˜๊ธฐ ์œ„ํ•œ ๋ณด์กฐ ์ˆ˜๋‹จ์ž…๋‹ˆ๋‹ค.
๋ชจ๋“  ํ•™์ˆ ์  ๋‚ด์šฉ, ์ธ์šฉ, ๊ฒฐ๋ก ์— ๋Œ€ํ•œ ์ตœ์ข… ๊ฒ€ํ† ์™€ ์ฑ…์ž„์€ ์ธ๊ฐ„ ์ €์ž์—๊ฒŒ ์žˆ์Šต๋‹ˆ๋‹ค.

๐Ÿ“ฌ Contact

If you have any questions, feel free to reach out!

๋ฌธ์˜์‚ฌํ•ญ์ด ์žˆ์œผ์‹œ๋ฉด ์–ธ์ œ๋“ ์ง€ ์—ฐ๋ฝ ์ฃผ์„ธ์š”!

cacaowhite@g.skku.edu

About

Sample LaTeX use setting in Cursor

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published