mirror of
https://github.com/foxcpp/maddy.git
synced 2026-02-04 06:44:50 +02:00
Move most code from the repo root into subdirectories
The intention is to keep to repo root clean while the list of packages is slowly growing. Additionally, a bunch of small (~30 LoC) files in the repo root is merged into a single maddy.go file, for the same reason. Most of the internal code is moved into the internal/ directory. Go toolchain will make it impossible to import these packages from external applications. Some packages are renamed and moved into the pkg/ directory in the root. According to https://github.com/golang-standards/project-layout this is the de-facto standard to place "library code that's ok to use by external applications" in. To clearly define the purpose of top-level directories, README.md files are added to each.
This commit is contained in:
@@ -1,43 +0,0 @@
|
||||
package maddy
|
||||
|
||||
var (
|
||||
// ConfigDirectory specifies platform-specific value
|
||||
// that should be used as a location of default configuration
|
||||
//
|
||||
// It should not be changed and is defined as a variable
|
||||
// only for purposes of modification using -X linker flag.
|
||||
ConfigDirectory = "/etc/maddy"
|
||||
|
||||
// DefaultStateDirectory specifies platform-specific
|
||||
// default for StateDirectory.
|
||||
//
|
||||
// Most code should use StateDirectory instead since
|
||||
// it will contain the effective location of the state
|
||||
// directory.
|
||||
//
|
||||
// It should not be changed and is defined as a variable
|
||||
// only for purposes of modification using -X linker flag.
|
||||
DefaultStateDirectory = "/var/lib/maddy"
|
||||
|
||||
// DefaultRuntimeDirectory specifies platform-specific
|
||||
// default for RuntimeDirectory.
|
||||
//
|
||||
// Most code should use RuntimeDirectory instead since
|
||||
// it will contain the effective location of the state
|
||||
// directory.
|
||||
//
|
||||
// It should not be changed and is defined as a variable
|
||||
// only for purposes of modification using -X linker flag.
|
||||
DefaultRuntimeDirectory = "/run/maddy"
|
||||
|
||||
// DefaultLibexecDirectory specifies platform-specific
|
||||
// default for LibexecDirectory.
|
||||
//
|
||||
// Most code should use LibexecDirectory since it will
|
||||
// contain the effective location of the libexec
|
||||
// directory.
|
||||
//
|
||||
// It should not be changed and is defined as a variable
|
||||
// only for purposes of modification using -X linker flag.
|
||||
DefaultLibexecDirectory = "/usr/lib/maddy"
|
||||
)
|
||||
Reference in New Issue
Block a user