File: macosbase.go

package info (click to toggle)
golang-github-apparentlymart-go-userdirs 0.0~git20200915.b0c018a-4
  • links: PTS, VCS
  • area: main
  • in suites: bookworm, forky, sid, trixie
  • size: 184 kB
  • sloc: makefile: 2
file content (26 lines) | stat: -rw-r--r-- 776 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
package macosbase

import (
	"path/filepath"
)

// ApplicationSupportDir returns the path to the current user's
// "Application Support" library directory.
func ApplicationSupportDir() string {
	return filepath.Join(home(), "Library", "Application Support")
}

// CachesDir returns the path to the current user's "Caches" library directory.
func CachesDir() string {
	return filepath.Join(home(), "Library", "Caches")
}

// FrameworksDir returns the path to the current user's "Frameworks" library directory.
func FrameworksDir() string {
	return filepath.Join(home(), "Library", "Frameworks")
}

// PreferencesDir returns the path to the current user's "Preferences" library directory.
func PreferencesDir() string {
	return filepath.Join(home(), "Library", "Preferences")
}