Skip to content

Commit

Permalink
v2.0; added compatibility package minted1; moved all \changes to chan…
Browse files Browse the repository at this point in the history
…gelog
  • Loading branch information
gpoore committed Jan 31, 2015
1 parent 6a82a97 commit 8353b80
Show file tree
Hide file tree
Showing 9 changed files with 667 additions and 53 deletions.
11 changes: 11 additions & 0 deletions CHANGES.md
@@ -1,5 +1,16 @@
# Changes


## v2.0 (2015/01/31)

* Added the compatibility package `minted1`, which provides the `minted` 1.7 code.
This may be loaded when 1.7 compatibility is required. This package works with
other packages that `\RequirePackage{minted}`, so long as it is loaded first.

* Moved all old `\changes` into `changelog`.



## Development releases for 2.0 (2014-January 2015)

* Caching is now on by default.
Expand Down
60 changes: 44 additions & 16 deletions README.md
Expand Up @@ -3,22 +3,6 @@
# minted — highlighted source code for LaTeX


## Current status

`minted` was created in [2009](http://stackoverflow.com/questions/1966425/source-code-highlighting-in-latex/1985330#1985330)
by Konrad Rudolph. [Geoffrey Poore](https://github.com/gpoore) agreed to
take over `minted` maintenance in March of 2013, since his
[PythonTeX](https://github.com/gpoore/pythontex) package also provides an
interface to Pygments.

`minted` is currently in final development for v2.0. If no bugs are found in
the current alpha release, it will become v2.0 with only very minor changes.
All planned features are present in the current alpha release. The alpha
release should be quite stable, but users who need maximum stability are
encouraged to use `minted` 1.7 or PythonTeX. The release on CTAN will only
be updated once v2.0 is finalized.


## Overview

`minted` is a LaTeX package that facilitates expressive syntax highlighting
Expand Down Expand Up @@ -52,6 +36,50 @@ See the [documentation](https://github.com/gpoore/minted/blob/master/source/mint
for examples and installation instructions.


## Current status

The 2.0 release is finally finished! Here is a brief overview for transitioning
from 1.7 to 2.0.

Transitioning from `minted` 1.7 to 2.0+ should require no changes in almost all
cases. Version 2 provides the same interface and all of the same features.

In cases when custom code was used to hook into the `minted` internals, it may
still be desirable to use the old `minted` 1.7. For those cases, the new package
`minted1` is provided. Simply load this before any other package attempts to load
`minted`, and you will have the code from 1.7.

A brief summary of new features in version 2.0 is provided below. More detail is available in `CHANGES.md`, or the Version History in `minted.pdf`.

* New inline command `\mintinline`.

* Support for caching highlighted code with new package option `cache`. This
drastically reduces package overhead. Caching is on by default. A cache
directory called `_minted-<document name>` will be created in the document root
directory. This may be modified with the `cachedir` package option.

* Automatic line breaking for all commands and environments with new option
`breaklines`. Many additional options for customizing line breaking.

* Support for Unicode under the pdfTeX engine.

* Set document-wide options using `\setminted{<opts>}`. Set language-specific
options using `\setminted[<lang>}{<opts>}`. Similarly, set inline-specific
options using `\setmintedinline`.

* Package option `langlinenos`: do line numbering by language.

* Many new options, including `encoding`, `autogobble`, and `escapeinside`
(requires Pygments 2.0+).

* New package option `outputdir` provides compatibility with command-line
options `-output-directory` and `-aux-directory`.

* New package option `draft` disables Python use to give maximum performance.

* `\mint` can now take code delimited by matched curly braces `{}`.


## Availability

`minted` is distributed with both TeX Live and MiKTeX. It is also available
Expand Down
38 changes: 38 additions & 0 deletions source/Makefile
@@ -0,0 +1,38 @@
TEXFLAGS = -e '$$pdflatex=q/pdflatex %O -shell-escape %S/' -pdf
LATEXMK = latexmk

PACKAGE = minted.dtx \
minted.ins \
minted.pdf \
README \
Makefile

.PHONY: minted all doc dist clean cleanall

minted: minted.sty

doc: minted.pdf

all: minted doc

minted.sty: minted.ins minted.dtx
tex minted.ins

minted.pdf: minted.sty minted.gls minted.dtx
$(LATEXMK) $(TEXFLAGS) minted.dtx

minted.gls: minted.glo
makeindex -s gglo.ist -o minted.gls minted.glo

minted.glo: minted.dtx minted.sty
$(LATEXMK) $(TEXFLAGS) minted.dtx

dist: $(PACKAGE)
@$(RM) minted.zip
@zip minted-$(shell grep '^\\ProvidesPackage' < minted.sty | grep -o '\<v[[:digit:]]*\.[[:digit:]]*\>').zip $(PACKAGE)

clean:
@$(RM) *.aux *.log *.out *.toc *.fdb_latexmk *.ilg *.glo *.gls *.lol

cleanall: clean
@$(RM) minted.sty minted.zip
2 changes: 1 addition & 1 deletion source/README
Expand Up @@ -4,7 +4,7 @@ minted is a package that facilitates expressive syntax highlighting in LaTeX
using the Pygments library. The package also provides options to customize
the highlighted source code output using fancyvrb.

See the documentation (minted.pdf) for examples and instructions of
See the documentation (minted.pdf) for examples and instructions for
installation and usage.

This work may be distributed and/or modified under the conditions of the
Expand Down

2 comments on commit 8353b80

@klmr
Copy link
Contributor

@klmr klmr commented on 8353b80 Jan 31, 2015

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

My sincerest congratulations for getting version 2.0 done. You’ve taken a mediocre package in an absolutely messy state from me, and created an almost complete rewrite, with tons of improvements and bug fixes. I have been following the progress of this repository over the years and the sheer amount of work you’ve put in, both in programming and in dealing with user feedback, amazes me. This is Open Source at its best.

Well done! 👍

@gpoore
Copy link
Owner Author

@gpoore gpoore commented on 8353b80 Feb 1, 2015

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@klmr Thanks! It's good to get feedback from someone who understands the work that goes into these things.

Please sign in to comment.