Skip to content

Commit b336829

Browse files
committed
Add detection of Debian distribution
Signed-off-by: Arnaud Meukam <[email protected]>
1 parent ddc21c7 commit b336829

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

util/pkg/distributions/distributions.go

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -68,6 +68,11 @@ func (d *Distribution) IsDebianFamily() bool {
6868
return d.packageFormat == "deb"
6969
}
7070

71+
// IsDebian returns true if this distribution is Debian
72+
func (d *Distribution) IsDebian() bool {
73+
return d.project == "debian"
74+
}
75+
7176
// IsUbuntu returns true if this distribution is Ubuntu (but not debian)
7277
func (d *Distribution) IsUbuntu() bool {
7378
return d.project == "ubuntu"

0 commit comments

Comments
 (0)