Class AppDirectories
Inheritance
AppDirectories
Namespace: Uniform.Matrix.Hosting
Assembly: Uniform.Matrix.Hosting.dll
public static class AppDirectories
string data = AppDirectories.Data("Uniform.Chat.Terminal"); // ~/.local/share/uniform-chat-terminal
Methods
|
Edit this page
View Source
Configuration directory: $XDG_CONFIG_HOME/<name> or ~/.config/<name>.
Declaration
public static string Config(string applicationName)
Parameters
| Type |
Name |
Description |
| string |
applicationName |
|
Returns
|
Edit this page
View Source
Data directory: $XDG_DATA_HOME/<name> or ~/.local/share/<name>.
Declaration
public static string Data(string applicationName)
Parameters
| Type |
Name |
Description |
| string |
applicationName |
|
Returns
|
Edit this page
View Source
Return path with a leading ~ or ~/ replaced by the home directory, as shells do only at the start of a word, e.g. not in --Tls:KeyPath=~/key.pem.
Declaration
public static string ExpandHome(string path)
Parameters
| Type |
Name |
Description |
| string |
path |
|
Returns
|
Edit this page
View Source
Return the directory name of an application: its name in lowercase with dashes, e.g. uniform-chat-terminal.
Declaration
public static string Name(string applicationName)
Parameters
| Type |
Name |
Description |
| string |
applicationName |
|
Returns