6.0.0 • Published 2 years ago

os-name v6.0.0

Weekly downloads
3,396,593
License
MIT
Repository
github
Last release
2 years ago

os-name

Get the name of the current operating system\ Example: macOS Sierra

Useful for analytics and debugging.

Install

npm install os-name

Usage

import os from 'node:os';
import osName from 'os-name';

// On a macOS Sierra system

osName();
//=> 'macOS Sierra'

osName(os.platform(), os.release());
//=> 'macOS Sierra'

osName('darwin', '14.0.0');
//=> 'OS X Yosemite'

osName('linux', '3.13.0-24-generic');
//=> 'Linux 3.13'

osName('win32', '6.3.9600');
//=> 'Windows 8.1'

API

osName(platform?, release?)

By default, the name of the current operating system is returned.

You can optionally supply a custom os.platform() and os.release().

Check out getos if you need the Linux distribution name.

Related

@navify/cliarchetype-librarycommit-cz-fixeasy-select-rnkanzhucai-nest-clireact-native-bluetooth2killi8n-react-native-fast-imagezfeddb-master-converterairscanairscan-examplereact-native-esc-pos-sahaab@borisovart/atol-kkt-module@frxf/frxfjrabbitnimble-boilerdeneme323112mdbtools-node@snyk/snyk-dev@ntt_app/react-native-custom-notificationrabbit-boilerreact-native-covid-sdk@zeroneorg/cliotto-cli@totvslabs/carolpri-clihzero-react-scriptshzero-webpack-scripts@kanzhucai/nest-clireact-native-printer-brothersleng-clireact-native-shekhar-bridge-testrepotest@fh0/cli@oiti/documentoscopy-react-nativequoc-test@infinitebrahmanuniverse/nolb-os-luminos-ui-core@everything-registry/sub-chunk-2389jawwy-sdkjawwy_gamification_releasesnbc-paas-webpacksnbc-paas-webpack-scriptsreact-native-sphereuisphereuicpaas-webpack-scriptsjawwy_libraryreact-native-credit-card-pkg@ken.zeng/app-scriptsreact-native-jawwy_samplegriffin-ui-librarytest-library-123test-haptik-libwa-automatewereleasewzt-plugin-release-itwifi_configuration_packagestraiforos-compodoctest-zeo-collectvision-camera-plugin-face-detectorvision-camera-plugin-scan-facesvision-camera-base64-resizedvantiq-reactjrennsoh88-react-native-scroll-indicatorjesh-calculationjnf-accesscontrol-rnttljordy-frijters-test-libipsamveljamuskalimionicionic-app-scripts-plusionic-app-libintcgenip2khaled-salem-custom-componentsgtbhatarakuhong1-utilsh-ionic-cliinsightmarmot-clil10nsl2forlernakonfig-release-it@watsonjs/cli@wecraftapps/react-native-use-keyboard@wiooh/cli@vendia/share-cli@tlgeo/react-native-gdal@thinxviewx/core-rn@types/os-name@tyku/xdocgen@unibtc/release-it@typeix/cli@totvs/cli-utils@tgairbot/cli@vizorous/nest-cli@vizorous/nest-cli-nocomments@yplabs-ltd/react-native-detector@zeronejs/cli
6.0.0

2 years ago

5.1.0

3 years ago

5.0.1

4 years ago

5.0.0

4 years ago

4.0.1

4 years ago

4.0.0

5 years ago

3.1.0

7 years ago

3.0.0

7 years ago

2.0.1

9 years ago

2.0.0

9 years ago

1.0.3

11 years ago

1.0.2

11 years ago

1.0.1

11 years ago

1.0.0

11 years ago

0.1.2

11 years ago

0.1.1

11 years ago

0.1.0

11 years ago