Changes

Jump to navigation Jump to search
625 bytes added ,  12:16, 5 March 2017
m
no edit summary
== Step 1: Install / Update '''ConTeXt''' ==
Installation and update of ConTeXt work nearly works the same. If you only want to update ConTeXt you can start directly from point 3.
1. [http://standalone.contextgarden.net/setup/ Download] ConTeXt.
* use Windows Explorer to navigate to your ConTeXt directory. In there should be a file called <code>first-setup.bat</code>.
* Use Windows Notepad or <code>Right-click</code> -> '''New''' -> '''Textfile''' to create such.
* Write or paste If you only want ConTeXt mkiv (highly '''recommended'''), add the following line into to the new and empty batch filetextfile:
first-setup -engine=luatex -modules=all
* Save the file as a '''batch '''-file and name it something like <code>update.bat</code>.** '''Note''' that the document ending has to be <code>.bat</code> not <code>.txt</code> or anything else. You might have to rename the file ending by hand.
* Execute the batch file you just created by double-clicking on it. A command prompt window should pop up.
** If it appears for only a few seconds, chances are high that the download server is down. In that case you might want to re-try the procedure at some other time.
** Now Windows command prompt should pop up with the correct location.
* Otherwise you can start your Windows command prompt like this:
** by using the key shortcut <code>Windows-Key key + R</code>, entering <code>cmd</code> and pressing <code>Enter</code>-key.
** Alternatively you can use <code>Start</code> -> <code>Programs</code> -> <code>Accessories</code> -> <code>Command Pompt</code>.
* Some DOS commands you might need:
** <code>X:</code> change to drive X:
** <code>dir</code> list the content of the current directory
** <code>cd DIRECTORY</code> change to directory with name DIRECTORY
** <code>cd..</code> change to superior directory
** <code>cd\</code> change to root drive
* Now * <code>X:</code> change to drive X:* In the end your command prompt should look like this:
X:\ConTeXt>_
* Enter the following line and press <code>Enter</code>-key:** If you only want ConTeXt mkiv (highly '''recommended'''), enter the following line and press <code>Enter</code>-key:
first-setup -engine=luatex -modules=all
* Wait until the download / update is complete. Afterwards you can close the command prompt by entering <code>exit</code> and pressing <code>Enter</code>-key or by simply closing the window.
== Step 2: Add ConTeXt's executables folder to Windows search PATH ==
'''Note''': you will need admin rights for this. On public machines you most probably won't be able to add ConTeXt to that machine's path. In that case skip this step and go to Step 3 respectively Step 4.1 directly. -- work in progress--
== Step 3: Install '''Textadept''' ==
== Step 4: Tweak '''Textadept''''s settings ==
=== Step 4.1: Bind a PDF build command into Textadept ===
1. Use your freshly installed Textadept to open Textadept's main configuration file called <code>init.lua</code>.
6. When you have a popular PDF reader installed already, it should pop up at the end of the process and show the created PDF output. [https://www.sumatrapdfreader.org/free-pdf-reader.html '''Sumatra PDF'''] is highly recommended for this.
=== Step 4.2: Lexing (command highlighting & code folding) ===
A lexer is a file that defines command highlightingand code folding keywords. Since Textadept comes with an own ConTeXt lexer, it is a good idea to bind <code>*.tex</code> files to Textadept's ConTeXt lexer, as otherwise you won't benefit from the mentioned features when writing ConTeXt documents. To do so:So
1. Add add the following lines line to your <code>USER/.textadept/init.lua</code>and save it afterwards:
textadept.file_types.extensions.tex = 'context'
* If you plan to use LaTeX and ConTeXt, you should use different file extensions. For example <code>*.tex</code> for LaTeX and <code>*.cxd</code> for ConTeXt documents. In that case you only have to bind your new ConTeXt extension to Textadept's ConTeXt lexer, since <code>.tex</code> files are automatically recognized as LaTeX documents:
194

edits

Navigation menu