From 89c3233c00689415506aa2a062f7525561013d24 Mon Sep 17 00:00:00 2001 From: sayanarijit Date: Wed, 23 Jun 2021 18:06:13 +0000 Subject: [PATCH] Automated deployment: Wed Jun 23 18:06:13 UTC 2021 1f3d6f215276a5824518b400162b7bb414712796 --- en/404.html | 2 +- en/alternatives.html | 2 +- en/community.html | 2 +- en/configuration.html | 2 +- en/contribute.html | 2 +- en/default-key-bindings.html | 2 +- en/general-config.html | 2 +- en/index.html | 2 +- en/install.html | 2 +- en/introduction.html | 2 +- en/layouts.html | 6 +- en/message.html | 2 +- en/modes.html | 2 +- en/node_types.html | 291 +++++++++++++++++++++++++++++++++++ en/post-install.html | 2 +- en/print.html | 91 ++++++++++- en/quickstart.html | 2 +- en/searchindex.js | 2 +- en/searchindex.json | 2 +- en/style.html | 6 +- en/todo.html | 2 +- en/upgrade-guide.html | 2 +- 22 files changed, 405 insertions(+), 25 deletions(-) create mode 100644 en/node_types.html diff --git a/en/404.html b/en/404.html index f5bc2c6..4889910 100644 --- a/en/404.html +++ b/en/404.html @@ -83,7 +83,7 @@ diff --git a/en/alternatives.html b/en/alternatives.html index eb84790..dd459be 100644 --- a/en/alternatives.html +++ b/en/alternatives.html @@ -82,7 +82,7 @@ diff --git a/en/community.html b/en/community.html index 3d959b3..0429b9e 100644 --- a/en/community.html +++ b/en/community.html @@ -82,7 +82,7 @@ diff --git a/en/configuration.html b/en/configuration.html index 503c02c..8e700eb 100644 --- a/en/configuration.html +++ b/en/configuration.html @@ -82,7 +82,7 @@ diff --git a/en/contribute.html b/en/contribute.html index 4fba8aa..e6b14a6 100644 --- a/en/contribute.html +++ b/en/contribute.html @@ -82,7 +82,7 @@ diff --git a/en/default-key-bindings.html b/en/default-key-bindings.html index eaa72ba..771bfe6 100644 --- a/en/default-key-bindings.html +++ b/en/default-key-bindings.html @@ -82,7 +82,7 @@ diff --git a/en/general-config.html b/en/general-config.html index 6b64049..9e5bc42 100644 --- a/en/general-config.html +++ b/en/general-config.html @@ -82,7 +82,7 @@ diff --git a/en/index.html b/en/index.html index 7dacd01..21c143a 100644 --- a/en/index.html +++ b/en/index.html @@ -82,7 +82,7 @@ diff --git a/en/install.html b/en/install.html index fa099bc..f2ea371 100644 --- a/en/install.html +++ b/en/install.html @@ -82,7 +82,7 @@ diff --git a/en/introduction.html b/en/introduction.html index 108de9f..9094de2 100644 --- a/en/introduction.html +++ b/en/introduction.html @@ -82,7 +82,7 @@ diff --git a/en/layouts.html b/en/layouts.html index 2846c03..0d24b27 100644 --- a/en/layouts.html +++ b/en/layouts.html @@ -82,7 +82,7 @@ @@ -306,7 +306,7 @@ applied of the list of paths being displayed.

- @@ -320,7 +320,7 @@ applied of the list of paths being displayed.

- diff --git a/en/message.html b/en/message.html index 03cb2f5..9b4a808 100644 --- a/en/message.html +++ b/en/message.html @@ -82,7 +82,7 @@ diff --git a/en/modes.html b/en/modes.html index 00eb4a9..3bcf2c6 100644 --- a/en/modes.html +++ b/en/modes.html @@ -82,7 +82,7 @@ diff --git a/en/node_types.html b/en/node_types.html new file mode 100644 index 0000000..28ca8ed --- /dev/null +++ b/en/node_types.html @@ -0,0 +1,291 @@ + + + + + + Node Types - xplr book + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + + + + + + + +
+
+

Node Types

+

This configuration defines how to deal with different kinds of nodes (files, +directories, symlinks etc.) in a directory.

+

This can be configured using the xplr.config.node_types Lua API.

+

It contains the following fields:

+ +

One node can fall into multiple categories. For example, a node can have the +extension md, and be a file. In that case, the properties from the more +specific category i.e. extension will be used.

+

The priority is:

+

special > extension > mime_essence > symlink > file > directory

+

directory

+

Type: NodeType Config

+

Properties related to directories are defined here.

+

Contains the following fields:

+

Example:

+
xplr.config.node_types.directory.meta.icon = ""
+xplr.config.node_types.directory.style.add_modifiers = { "Bold" }
+
+

file

+

Type: NodeType Config

+

Properties related to regular files are defined here.

+

Contains the following fields:

+

Example:

+
xplr.config.node_types.file.meta.icon = ""
+xplr.config.node_types.file.style.fg = "White"
+
+ +

Type: NodeType Config

+

Properties related to symlink are defined here.

+

Example:

+
xplr.config.node_types.symlink.meta.icon = ""
+xplr.config.node_types.symlink.style.add_modifiers = { "Italic" }
+
+

mime_essence

+

Type: mapping of mime-type and mapping of mime-subtype and NodeType Config

+

Properties related to files with specific mime types are defined here.

+

Example:

+
xplr.config.node_types.mime_essence = {
+  application = {
+    -- application/pdf
+    pdf = { meta = { icon = "" } },
+
+    -- application/zip
+    zip = { meta = { icon = ""} },
+  },
+}
+
+

extension

+

Type: mapping of extension and NodeType Config

+

Properties related to files with specific extension are defined here.

+

Example:

+
xplr.config.node_types.extension.md = { meta = { icon = "" } }
+xplr.config.node_types.extension.rs = { meta = { icon = "🦀" } }
+
+

special

+

Type: mapping of name and NodeType Config

+

Properties related to files and directories with special names are defined +here.

+

Example:

+
xplr.config.node_types.special["Cargo.toml"] = { meta = { icon = "" } }
+xplr.config.node_types.special["Downloads"] = { meta = { icon = "" } }
+
+

NodeType Config

+

A node-type config contains the following fields:

+ +

meta

+

Type: mapping of string and string

+

A meta field can contain custom metadata about a node. By default, the "icon" +metadata is set for the directory, file, and +symlink nodes.

+

Example:

+
xplr.config.node_types.file = {
+  meta = {
+    icon = "f",
+    foo = "bar",
+  }
+}
+
+ +
+ + +
+
+ + + +
+ + + + + + + + + + + + + + + + + + + + diff --git a/en/post-install.html b/en/post-install.html index b445e75..deb6e1d 100644 --- a/en/post-install.html +++ b/en/post-install.html @@ -82,7 +82,7 @@ diff --git a/en/print.html b/en/print.html index 2665f65..fa692fc 100644 --- a/en/print.html +++ b/en/print.html @@ -83,7 +83,7 @@ @@ -876,6 +876,95 @@ applied of the list of paths being displayed.

} } +

Node Types

+

This configuration defines how to deal with different kinds of nodes (files, +directories, symlinks etc.) in a directory.

+

This can be configured using the xplr.config.node_types Lua API.

+

It contains the following fields:

+ +

One node can fall into multiple categories. For example, a node can have the +extension md, and be a file. In that case, the properties from the more +specific category i.e. extension will be used.

+

The priority is:

+

special > extension > mime_essence > symlink > file > directory

+

directory

+

Type: NodeType Config

+

Properties related to directories are defined here.

+

Contains the following fields:

+

Example:

+
xplr.config.node_types.directory.meta.icon = ""
+xplr.config.node_types.directory.style.add_modifiers = { "Bold" }
+
+

file

+

Type: NodeType Config

+

Properties related to regular files are defined here.

+

Contains the following fields:

+

Example:

+
xplr.config.node_types.file.meta.icon = ""
+xplr.config.node_types.file.style.fg = "White"
+
+ +

Type: NodeType Config

+

Properties related to symlink are defined here.

+

Example:

+
xplr.config.node_types.symlink.meta.icon = ""
+xplr.config.node_types.symlink.style.add_modifiers = { "Italic" }
+
+

mime_essence

+

Type: mapping of mime-type and mapping of mime-subtype and NodeType Config

+

Properties related to files with specific mime types are defined here.

+

Example:

+
xplr.config.node_types.mime_essence = {
+  application = {
+    -- application/pdf
+    pdf = { meta = { icon = "" } },
+
+    -- application/zip
+    zip = { meta = { icon = ""} },
+  },
+}
+
+

extension

+

Type: mapping of extension and NodeType Config

+

Properties related to files with specific extension are defined here.

+

Example:

+
xplr.config.node_types.extension.md = { meta = { icon = "" } }
+xplr.config.node_types.extension.rs = { meta = { icon = "🦀" } }
+
+

special

+

Type: mapping of name and NodeType Config

+

Properties related to files and directories with special names are defined +here.

+

Example:

+
xplr.config.node_types.special["Cargo.toml"] = { meta = { icon = "" } }
+xplr.config.node_types.special["Downloads"] = { meta = { icon = "" } }
+
+

NodeType Config

+

A node-type config contains the following fields:

+ +

meta

+

Type: mapping of string and string

+

A meta field can contain custom metadata about a node. By default, the "icon" +metadata is set for the directory, file, and +symlink nodes.

+

Example:

+
xplr.config.node_types.file = {
+  meta = {
+    icon = "f",
+    foo = "bar",
+  }
+}
+

Style

A style object contains the following information: