editors.vim.generate-syntax: Match new generation

Also update the vim/syntax README.
master
Dusk 2020-06-06 20:24:56 -07:00 committed by John Benediktsson
parent 35b8621306
commit f70ce01b51
2 changed files with 15 additions and 12 deletions

View File

@ -1,10 +1,10 @@
! Generate a new factor.vim file for syntax highlighting
USING: html.templates html.templates.fhtml io.files io.pathnames ;
USING: io.encodings.utf8 io.files parser ;
IN: editors.vim.generate-syntax
: generate-vim-syntax ( -- )
"resource:misc/factor.vim.fgen" <fhtml>
"resource:misc/vim/syntax/factor.vim"
template-convert ;
"resource:misc/vim/syntax/factor/generated.vim"
utf8 "resource:misc/factor.vim.fgen" parse-file
with-file-writer ;
MAIN: generate-vim-syntax

View File

@ -6,10 +6,10 @@ more pleasant in Vim.
## Installation
The file-layout exactly matches the Vim runtime
structure, so you can install them by copying the contents of this directory
into `~/.vim/` or the equivalent path on other platforms (Open Vim and type
`:help 'runtimepath'` for details).
The file-layout exactly matches the Vim runtime structure,
so you can install them by copying the contents of this directory
into `~/.vim/` or the equivalent path on other platforms
(open Vim and type `:help 'runtimepath'` for details).
## File organization
@ -17,8 +17,10 @@ The current set of files is as follows:
* ftdetect/factor.vim - Teach Vim when to load Factor support files.
* ftplugin/factor.vim - Teach Vim to follow the Factor Coding Style guidelines.
* ftplugin/factor-docs.vim - Teach Vim about documentation style differences.
* plugin/factor.vim - Teach Vim some commands for navigating Factor source code. See below.
* syntax/factor.vim - Syntax highlighting for Factor code.
* syntax/factor.vim - Teach Vim about highlighting Factor source code syntax.
* syntax/factor/generated.vim - Syntax highlighting lessons generated from a Factor VM.
## Commands
@ -70,9 +72,10 @@ The default value is `work`.
## Note
The syntax-highlighting file is automatically generated to include the
names of all the vocabularies Factor knows about. To regenerate it manually,
run the following code in the listener:
The `syntax/factor/generated.vim` syntax highlighting file
is automatically generated
to include the names of all the vocabularies Factor knows about.
To regenerate it manually, run the following code in the listener:
"editors.vim.generate-syntax" run