ghcup-hs/3rdparty/os-release
2020-07-04 23:28:30 +02:00
..
library/System Use os-release package 2020-07-04 23:28:30 +02:00
tests Use os-release package 2020-07-04 23:28:30 +02:00
.gitattributes Use os-release package 2020-07-04 23:28:30 +02:00
.gitignore Use os-release package 2020-07-04 23:28:30 +02:00
ChangeLog.rst Use os-release package 2020-07-04 23:28:30 +02:00
LICENSE Use os-release package 2020-07-04 23:28:30 +02:00
os-release.cabal Use os-release package 2020-07-04 23:28:30 +02:00
README.rst Use os-release package 2020-07-04 23:28:30 +02:00
Setup.hs Use os-release package 2020-07-04 23:28:30 +02:00

##########
os-release
##########

http://www.freedesktop.org/software/systemd/man/os-release.html

Usage
#####

.. code-block:: haskell

  import System.OsRelease
  main = readOs >>= print

.. code-block::

  Right (fromList [(OsReleaseKey "ANSI_COLOR",OsReleaseValue "1;32"),(OsReleaseKey "BUG_REPORT_URL",OsReleaseValue "https://bugs.gentoo.org/"),(OsReleaseKey "HOME_URL",OsReleaseValue "http://www.gentoo.org/"),(OsReleaseKey "ID",OsReleaseValue "gentoo"),(OsReleaseKey "NAME",OsReleaseValue "Gentoo"),(OsReleaseKey "PRETTY_NAME",OsReleaseValue "Gentoo/Linux"),(OsReleaseKey "SUPPORT_URL",OsReleaseValue "http://www.gentoo.org/main/en/support.xml")])