From bb7fae72c9f1a23ced3581edb447d4099d28f155 Mon Sep 17 00:00:00 2001 From: henil Date: Sun, 4 Oct 2020 00:16:39 +0530 Subject: [PATCH] add a new syntax section --- README.md | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index 9f2f86ee..37678011 100644 --- a/README.md +++ b/README.md @@ -526,12 +526,19 @@ Example configuration file: # Use C++ syntax for .ino files --map-syntax "*.ino:C++" +``` + +### Syntax of a file + +`bat` can be configured to change the default syntax of the file using `--map-syntax`. For example not all `.conf` file's have `INI` syntax(some do) so it cannot be default. But you can configure it if you want. + +For example: +```bash +# Use INI syntax for .conf files +--map-syntax "*.conf:INI" # Use ".gitignore"-style highlighting for ".ignore" files --map-syntax ".ignore:Git Ignore" - -# Use INI syntax for .conf files ---map-syntax "*.conf:INI" ``` ## Using `bat` on Windows