Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

What is the most minimal code to work with ConTeXt?

share|improve this question
    
"work with"? What kind of work do you have in mind? –  Charles Stewart Jan 13 '11 at 9:51
    
@Charles: To make it compilable. –  xport Jan 13 '11 at 10:03
    
To test that your set up is working? –  Charles Stewart Jan 13 '11 at 10:09
    
@Charles: Yes. I want to make a test. –  xport Jan 13 '11 at 10:13

2 Answers 2

up vote 9 down vote accepted

This is the most minimal. It just instructs TeX to stop.

\end

While I'm at it. It's also the most minimal code for plain TeX. For LaTeX, the best I could do is this.

\csname@@end\endcsname

I guess

\catcode`@11 \@@end

is shorter, but it's less minimal since TeX has to execute two commands instead of just one.

share|improve this answer
    
@TH \stop for LaTeX should be the shorter? –  Yiannis Lazarides Jan 13 '11 at 7:11
    
@Yiannis: Ah yes. Probably the shortest, but not the most minimal. It invokes the output routine. –  TH. Jan 13 '11 at 9:22
    
What about \enddocument in LaTeX? Probably also not minimal, since that requires an aux file present. –  Konrad Rudolph Jan 13 '11 at 11:19
    
@Konrad: That doesn't work. As you mentioned, it looks for \jobname.aux. –  TH. Jan 13 '11 at 12:17
\starttext
Hello world.
\stoptext

or even simpler

Hello world.
\bye
share|improve this answer
    
Well, actually I'm not a ConTeXt user. wiki.contextgarden.net/First_Document –  Leo Liu Jan 13 '11 at 6:25
    
how about just \bye? –  Yiannis Lazarides Jan 13 '11 at 6:30
    
@Yiannis: In fact, there's no difference, right? I think the key is "work" but not "most minimal". The first example works as most ConTeXt ducuments, and the second one works as Plain TeX. –  Leo Liu Jan 13 '11 at 10:29

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.