diff options
author | gbrandl <devnull@localhost> | 2007-02-15 19:59:26 +0100 |
---|---|---|
committer | gbrandl <devnull@localhost> | 2007-02-15 19:59:26 +0100 |
commit | bfec1a3da5a0f230babecfe4cb343a9bb8f1ae71 (patch) | |
tree | bcd78e698da2e3b2cfe1ab63fae2392c2419cdf1 | |
parent | 797e128e7a42832e715b9bdb467c09166f3b6fd9 (diff) | |
download | pygments-bfec1a3da5a0f230babecfe4cb343a9bb8f1ae71.tar.gz |
[svn] Remove unnecessary script and fix Makefile.
-rw-r--r-- | Makefile | 2 | ||||
-rw-r--r-- | scripts/find_abandoned_lexers.py | 45 |
2 files changed, 1 insertions, 46 deletions
@@ -10,7 +10,7 @@ PYTHON ?= python -export PYTHONPATH = $(shell echo "$$PYTHONPATH"):$(shell python -c 'print ":".join(line.strip() for line in file("PYTHONPATH"))' 2>/dev/null) +export PYTHONPATH = $(shell echo "$$PYTHONPATH"):$(shell python -c 'import os; print ":".join(os.path.abspath(line.strip()) for line in file("PYTHONPATH"))' 2>/dev/null) .PHONY: all apidocs check clean clean-pyc codetags docs epydoc mapfiles \ pylint reindent test diff --git a/scripts/find_abandoned_lexers.py b/scripts/find_abandoned_lexers.py deleted file mode 100644 index 8db08b5b..00000000 --- a/scripts/find_abandoned_lexers.py +++ /dev/null @@ -1,45 +0,0 @@ -#!/usr/bin/env python -# -*- coding: utf-8 -*- -""" - Find Not Documented Lexers - ~~~~~~~~~~~~~~~~~~~~~~~~~~ - - Call it from the command line to find out which lexers arn't - in the documentation right now. Maybe it would be a good idea - to check the mimetypes, filename patterns and aliases too. - - :copyright: 2006-2007 by Armin Ronacher. - :license: BSD, see LICENSE for more details. -""" -import re -import sys -import os - - -base_path = os.path.abspath(os.path.join(os.path.dirname(__file__), '..')) -lexer_doc = os.path.join(base_path, 'docs', 'src', 'lexers.txt') -sys.path.insert(0, base_path) - -from pygments.lexers import LEXERS - -existing_lexers = set(LEXERS) -documented_lexers = set() -f = open(lexer_doc) -for line in f: - m = re.search('^`([a-zA-Z0-9]+Lexer)`\s*$(?m)', line) - if m: - documented_lexers.add(m.group(1)) -f.close() - -just_documented = sorted(documented_lexers.difference(existing_lexers)) -not_documented = sorted(existing_lexers.difference(documented_lexers)) - -if just_documented: - print 'Lexers that just exist in the documentation:' - for lexer in just_documented: - print ' ', lexer - -if not_documented: - print 'Lexers that are not documented by now:' - for lexer in not_documented: - print ' ', lexer |