mirror of
https://github.com/garethgeorge/backrest.git
synced 2025-12-17 02:55:39 +00:00
16 lines
335 B
Go
16 lines
335 B
Go
package migrations
|
|
|
|
import (
|
|
v1 "github.com/garethgeorge/backrest/gen/go/v1"
|
|
"github.com/garethgeorge/backrest/internal/cryptoutil"
|
|
)
|
|
|
|
var migration004RepoGuid = func(config *v1.Config) {
|
|
for _, repo := range config.Repos {
|
|
if repo.Guid != "" {
|
|
continue
|
|
}
|
|
repo.Guid = cryptoutil.MustRandomID(cryptoutil.DefaultIDBits)
|
|
}
|
|
}
|