Last change
on this file since 1ad8e64 was 6a3a178, checked in by Ema <ema_spirova@…>, 3 years ago |
initial commit
|
-
Property mode
set to
100644
|
File size:
995 bytes
|
Line | |
---|
1 | # is-wsl [![Build Status](https://travis-ci.org/sindresorhus/is-wsl.svg?branch=master)](https://travis-ci.org/sindresorhus/is-wsl)
|
---|
2 |
|
---|
3 | > Check if the process is running inside [Windows Subsystem for Linux](https://msdn.microsoft.com/commandline/wsl/about) (Bash on Windows)
|
---|
4 |
|
---|
5 | Can be useful if you need to work around unimplemented or buggy features in WSL. Supports both WSL 1 and WSL 2.
|
---|
6 |
|
---|
7 |
|
---|
8 | ## Install
|
---|
9 |
|
---|
10 | ```
|
---|
11 | $ npm install is-wsl
|
---|
12 | ```
|
---|
13 |
|
---|
14 |
|
---|
15 | ## Usage
|
---|
16 |
|
---|
17 | ```js
|
---|
18 | const isWsl = require('is-wsl');
|
---|
19 |
|
---|
20 | // When running inside Windows Subsystem for Linux
|
---|
21 | console.log(isWsl);
|
---|
22 | //=> true
|
---|
23 | ```
|
---|
24 |
|
---|
25 |
|
---|
26 | ---
|
---|
27 |
|
---|
28 | <div align="center">
|
---|
29 | <b>
|
---|
30 | <a href="https://tidelift.com/subscription/pkg/npm-is-wsl?utm_source=npm-is-wsl&utm_medium=referral&utm_campaign=readme">Get professional support for this package with a Tidelift subscription</a>
|
---|
31 | </b>
|
---|
32 | <br>
|
---|
33 | <sub>
|
---|
34 | Tidelift helps make open source sustainable for maintainers while giving companies<br>assurances about security, maintenance, and licensing for their dependencies.
|
---|
35 | </sub>
|
---|
36 | </div>
|
---|
Note:
See
TracBrowser
for help on using the repository browser.