mirror of
https://github.com/turbot/steampipe.git
synced 2026-02-24 02:00:29 -05:00
General code spring cleaning: * move file paths from `consts` package to `filepaths` * move InitData and ExportData to query and control packages
35 lines
852 B
Go
35 lines
852 B
Go
package filepaths
|
|
|
|
import (
|
|
"path"
|
|
"path/filepath"
|
|
)
|
|
|
|
// mod related constants
|
|
const (
|
|
WorkspaceDataDir = ".steampipe"
|
|
WorkspaceModDir = "mods"
|
|
WorkspaceConfigFileName = "workspace.spc"
|
|
WorkspaceIgnoreFile = ".steampipeignore"
|
|
ModFileName = "mod.sp"
|
|
DefaultVarsFileName = "steampipe.spvars"
|
|
WorkspaceLockFileName = ".mod.cache.json"
|
|
)
|
|
|
|
func WorkspaceModPath(workspacePath string) string {
|
|
return path.Join(workspacePath, WorkspaceDataDir, WorkspaceModDir)
|
|
}
|
|
|
|
func WorkspaceLockPath(workspacePath string) string {
|
|
return path.Join(workspacePath, WorkspaceLockFileName)
|
|
}
|
|
|
|
func DefaultVarsFilePath(workspacePath string) string {
|
|
return path.Join(workspacePath, DefaultVarsFileName)
|
|
}
|
|
|
|
func ModFilePath(modFolder string) string {
|
|
modFilePath := filepath.Join(modFolder, ModFileName)
|
|
return modFilePath
|
|
}
|