github.com/cozy/cozy-stack@v0.0.0-20240327093429-939e4a21320e/model/instance/windows.go (about)

     1  //go:build windows
     2  // +build windows
     3  
     4  package instance
     5  
     6  import "strings"
     7  
     8  // DirName returns the name of the subdirectory where instance data are stored.
     9  // On Windows, it's a modified version of the domain name, since some
    10  // characters are forbidden in directory names.
    11  func (i *Instance) DirName() string {
    12  	return strings.Replace(i.Domain, ":", "_", -1)
    13  }