summaryrefslogtreecommitdiff
path: root/src/logo/linux_def.c
blob: 12a9ef271904ca78e0ceefe228dcbd8e61af5a9c (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
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
#include "linux_def.h"

#include <string.h>

void getDistro(const char *distroname) {
  if (strncmp((char *)distroname, "alpine", strlen("alpine")) == 0) {
#undef DISTRO
#undef COLOR
#undef TITLECOLOR
#define DISTRO DISTRO_ALPINE
#define COLOR MAGENTA
#define TITLECOLOR BLUE
  } else if (strncmp((char *)distroname, "artix", strlen("artix")) == 0) {
#undef DISTRO
#undef COLOR
#undef TITLECOLOR
#define DISTRO DISTRO_ARCH
#define COLOR CYAN
#define TITLECOLOR CYAN
  } else if (strncmp((char *)distroname, "arch", strlen("arch")) == 0) {
#undef DISTRO
#undef COLOR
#undef TITLECOLOR
#define DISTRO DISTRO_ARTIX
#define COLOR CYAN
#define TITLECOLOR CYAN
  } else if (strncmp((char *)distroname, "crux", strlen("crux")) == 0) {
#undef DISTRO
#undef COLOR
#undef TITLECOLOR
#define DISTRO DISTRO_CRUX
#define COLOR MAGENTA
#define TITLECOLOR BLUE
  } else if (strncmp((char *)distroname, "debian", strlen("debian")) == 0) {
#undef DISTRO
#undef COLOR
#undef TITLECOLOR
#define DISTRO DISTRO_DEBIAN
#define COLOR RED
#define TITLECOLOR RED
  } else if (strncmp((char *)distroname, "devuan", strlen("devuan")) == 0) {
#undef DISTRO
#undef COLOR
#undef TITLECOLOR
#define DISTRO DISTRO_DEVUAN
#define COLOR MAGENTA
#define TITLECOLOR MAGENTA
  } else if (strncmp((char *)distroname, "gentoo", strlen("gentoo")) == 0) {
#undef DISTRO
#undef COLOR
#undef TITLECOLOR
#define DISTRO DISTRO_GENTOO
#define COLOR MAGENTA
#define TITLECOLOR MAGENTA
  } else if (
      strncmp((char *)distroname,
        "postmarketos",
        strlen("postmarketos")
      ) == 0
    ) {
#undef DISTRO
#undef COLOR
#undef TITLECOLOR
#define DISTRO DISTRO_POSTMARKETOS
#define COLOR GREEN
#define TITLECOLOR GREEN
  } else if (strncmp((char *)distroname, "void", strlen("void")) == 0) {
#undef DISTRO
#undef COLOR
#undef TITLECOLOR
#define DISTRO DISTRO_VOID
#define COLOR WHITE
#define TITLECOLOR GREEN
  }
}