/sysinfo

Primary LanguageEmacs Lisp

Introduction

sysinfo provides basic info about operating system running Emacs.

sysinfo sets two variables:

sysinfo-os-family - operating system family like: Linux, Windows, maxOS, etc. sysinfo-os-type - operating system type like: Android, cygwin, WSL, etc.

Currently detected systems

sysinfo-os-familysysinfo-os-type
LinuxLinux
LinuxWSL
LinuxAndroid
Windowsmingw
Windowscygwin
macOSmacOS
AIXAIX
BSDBSD
FreeBSDFreeBSD
GNUGNU
HP-UXHP-UX
MS-DOSMS-DOS
NaClNaCl
SystemVSystemV

Examples

(setq mswin (eq sysinfo-os-family 'Windows))
(setq wsl (eq sysinfo-os-type 'WSL))
(setq android (eq sysinfo-os-type 'Android))