Skip to content

Commit

Permalink
feat: add opt quarto installer
Browse files Browse the repository at this point in the history
  • Loading branch information
dpastoor committed Sep 26, 2022
1 parent e5a32b3 commit b47cadd
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions internal/config/fs.go
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,11 @@ func GetPathToActiveQuartoExe() string {
return filepath.Join(GetPathToActiveBinDir(), quartoExe)
}
func GetPathToVersionsDir() string {
// if running as root, install to /opt/quarto as an admin helper
if runtime.GOOS == "linux" && os.Getuid() == 0 {
return filepath.Join("opt", "quarto")
}

return filepath.Join(xdg.DataHome, "qvm", "versions")
}

Expand Down

0 comments on commit b47cadd

Please sign in to comment.