@@ -439,6 +439,33 @@ bat cache --build
439439
440440Finally, use `bat --list-themes` to check if the new themes are available.
441441
442+### Adding or changing file type associations
443+
444+You can add new (or change existing) file name patterns using the `--map-syntax`
445+command line option. The option takes an argument of the form `pattern:syntax` where
446+`pattern` is a glob pattern that is matched against the file name and
447+the absolute file path. The `syntax` part is the full name of a supported language
448+(use `bat --list-languages` for an overview)full .
449+
450+Note: You probably want to use this option as an entry in `bat`s configuration file instead
451+of passing it on the command line (see below).
452+
453+Example: To use "INI" syntax highlighting for all files with a `.conf` file extension, use
454+```bash
455+--map-syntax='*.conf:INI'
456+```
457+
458+Example: To open all files called `.ignore` (exact match) with the "Git Ignore" syntax, use:
459+```bash
460+--map-syntax='.ignore:Git Ignore'
461+```
462+
463+Example: To open all `.conf` files in subfolders of `/etc/apache2` with the "Apache Conf"
464+syntax, use (this mapping is already built in):
465+```bash
466+-map-syntax='/etc/apache2/**/*.conf:Apache Conf'
467+```
468+
442469### Using a different pager
443470
444471`bat` uses the pager that is specified in the `PAGER` environment variable. If this variable is not
@@ -490,32 +517,6 @@ and the `GitHub` theme when in the _light mode_.
490517alias cat="bat --theme=\$(defaults read -globalDomain AppleInterfaceStyle &> /dev/null && echo default || echo GitHub)"
491518```
492519
493−### Adapting file type associations
494−
495−You can add new (or change existing) file name patterns using the
496−`--map-syntax` option. The option takes an argument of the form `pattern:syntax`.
497−`pattern` is a glob pattern that is matched against the file name and
498−the absolute file path. `syntax` is the *name* of a supported language
499−(use `bat --list-languages` for an overview).
500−
501−This option is most useful in combination with the `bat` configuration file (see below).
502−
503−Example: To use "INI" syntax highlighting for all files with a `.conf` file extension, use
504−```bash
505−--map-syntax='*.conf:INI'
506−```
507−
508−Example: To open all files called `.ignore` (exact match) with the "Git Ignore" syntax, use:
509−```bash
510−--map-syntax='.ignore:Git Ignore'
511−```
512−
513−Example: To open all `.conf` files in subfolders of `/etc/apache2` with the "Apache Conf"
514−syntax, use (this mapping is already built in):
515−```bash
516−-map-syntax='/etc/apache2/**/*.conf:Apache Conf'
517−```
518−
519520
520521## Configuration file
521522