Add Artix to distro list (#18629)
This commit is contained in:
parent
2bc07554cc
commit
499d4690fb
1 changed files with 5 additions and 2 deletions
|
|
@ -52,6 +52,7 @@ type
|
||||||
CentOS
|
CentOS
|
||||||
Deepin
|
Deepin
|
||||||
ArchLinux
|
ArchLinux
|
||||||
|
Artix
|
||||||
Antergos
|
Antergos
|
||||||
PCLinuxOS
|
PCLinuxOS
|
||||||
Mageia
|
Mageia
|
||||||
|
|
@ -133,7 +134,7 @@ type
|
||||||
|
|
||||||
|
|
||||||
const
|
const
|
||||||
LacksDevPackages* = {Distribution.Gentoo, Distribution.Slackware, Distribution.ArchLinux}
|
LacksDevPackages* = {Distribution.Gentoo, Distribution.Slackware, Distribution.ArchLinux, Distribution.Artix}
|
||||||
|
|
||||||
# we cache the result of the 'cmdRelease'
|
# we cache the result of the 'cmdRelease'
|
||||||
# execution for faster platform detections.
|
# execution for faster platform detections.
|
||||||
|
|
@ -180,6 +181,8 @@ proc detectOsImpl(d: Distribution): bool =
|
||||||
result = "rhel" in osReleaseID()
|
result = "rhel" in osReleaseID()
|
||||||
of Distribution.ArchLinux:
|
of Distribution.ArchLinux:
|
||||||
result = "arch" in osReleaseID()
|
result = "arch" in osReleaseID()
|
||||||
|
of Distribution.Artix:
|
||||||
|
result = "artix" in osReleaseID()
|
||||||
of Distribution.NixOS:
|
of Distribution.NixOS:
|
||||||
# Check if this is a Nix build or NixOS environment
|
# Check if this is a Nix build or NixOS environment
|
||||||
result = existsEnv("NIX_BUILD_TOP") or existsEnv("__NIXOS_SET_ENVIRONMENT_DONE")
|
result = existsEnv("NIX_BUILD_TOP") or existsEnv("__NIXOS_SET_ENVIRONMENT_DONE")
|
||||||
|
|
@ -249,7 +252,7 @@ proc foreignDepInstallCmd*(foreignPackageName: string): (string, bool) =
|
||||||
result = ("pkg_add " & p, true)
|
result = ("pkg_add " & p, true)
|
||||||
elif detectOs(PCLinuxOS):
|
elif detectOs(PCLinuxOS):
|
||||||
result = ("rpm -ivh " & p, true)
|
result = ("rpm -ivh " & p, true)
|
||||||
elif detectOs(ArchLinux) or detectOs(Manjaro):
|
elif detectOs(ArchLinux) or detectOs(Manjaro) or detectOs(Artix):
|
||||||
result = ("pacman -S " & p, true)
|
result = ("pacman -S " & p, true)
|
||||||
else:
|
else:
|
||||||
result = ("<your package manager here> install " & p, true)
|
result = ("<your package manager here> install " & p, true)
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue