aboutsummaryrefslogtreecommitdiff
blob: 773b8eba8c7e7768fc5f4ff5b0121a8b07dd1a5e (plain)
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
// Contains the model of a package version

package models

type UserPreferences struct {
	Maintainers MaintainersPreferences
}

type MaintainersPreferences struct {
	IncludeProjectPackages bool
	ExcludedProjects       []string
}

var ArchesToShow = [...]string{"amd64", "x86", "alpha", "arm", "arm64", "hppa", "ia64", "ppc", "ppc64", "riscv", "sparc"}
var AllArches = [...]string{"alpha", "amd64", "arm", "arm64", "hppa", "ia64", "mips", "ppc", "ppc64", "riscv", "s390", "sparc", "x86"}
var OldCookieNames = [...]string{"search_history", "userpref_general", "userpref_packages", "userpref_useflags", "userpref_arches"}

func GetDefaultUserPreferences() UserPreferences {
	userPreferences := UserPreferences{}
	userPreferences.Maintainers = MaintainersPreferences{}

	userPreferences.Maintainers.IncludeProjectPackages = false
	userPreferences.Maintainers.ExcludedProjects = []string{}

	return userPreferences
}