Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
use separate Syntax::Highlight::Engine::Kate::Convert
... and also add hl-kate-convert script and do this minor changes: * add some documentation wrt. conversion of Kate's highlight defs * set MANIFEST.SKIP to ignore - .git dir and .gitignore - *.swp files used by vim * use freshly generated MANIFEST * unset eXecute flag for Changes file and update its content Signed-off-by: Jan Pokorný <jpokorny@redhat.com>
- Loading branch information
Showing
6 changed files
with
232 additions
and
96 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
#!/usr/bin/perl -w | ||
|
||
# Copyright 2012 Jan Pokorny <jpokorny at redhat dot com>. | ||
# This program is free software; you can redistribute it and/or modify it | ||
# under the terms of either: the GNU General Public License as published | ||
# by the Free Software Foundation; or the Artistic License. | ||
|
||
use strict; | ||
|
||
use Syntax::Highlight::Engine::Kate::Convert::ToolKit; | ||
|
||
my $toolkit = new Syntax::Highlight::Engine::Kate::Convert::ToolKit(); | ||
|
||
# TODO: optionally redefine bare output to respective files? | ||
# $toolkit->outcmd = sub { ... }; | ||
|
||
for (@ARGV) { | ||
my $hlfile = $_; | ||
my $outfile = $toolkit->register($hlfile); | ||
print "### ${outfile} ### "; # comment out the "loading" message | ||
$toolkit->pmGenerate($outfile); | ||
} | ||
|
||
__END__ | ||
=head1 NAME | ||
hl-kate-convert - generates highlight definitions from Kate's originals | ||
=head1 DESCRIPTION | ||
C<hl-kate-convert> is a script to convert native highlight definitions | ||
of Kate to the ones used by Syntax::Highlight::Engine::Kate. | ||
=head1 SYNOPSIS | ||
hl-kate-convert <kate-xml-hl-def> [...] | ||
Example: | ||
hl-kate-convert /some/path/some-lang.xml > SomeLang.pm |
Oops, something went wrong.