config

package
v0.0.3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 2, 2021 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var BaseDir = func() string {
	b := os.Getenv("MRS_HOME")
	if b != "" {
		return b
	}

	dataDir := os.Getenv("XDG_DATA_HOME")
	if dataDir != "" {
		return path.Join(dataDir, "mrs")
	}

	homeDir, err := os.UserHomeDir()
	if err != nil {
		log.Fatal(err)
	}
	return path.Join(homeDir, ".local/share/mrs")
}()

BaseDir is the directory where mrs stores its files

View Source
var DefaultVaultName = os.Getenv("MRS_DEFAULT_VAULT_NAME")

DefaultVaultName is the name of the default vault

View Source
var Editor = func() string {
	e := os.Getenv("EDITOR")
	if e != "" {
		return e
	}
	return "nano"
}()

Editor is the command to run to launch a text editor

View Source
var HideEditorInstructions = os.Getenv("MRS_HIDE_EDITOR_INSTRUCTIONS") != ""

HideEditorInstructions indicates that instructions comments should be omitted from the top of editor sessions

View Source
var TempDir = createTempDir()

TempDir is the directory where mrs stores temporary files

View Source
var VaultDir = createVaultDir()

VaultDir is the directory where mrs stores vault files

Functions

This section is empty.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL