1- mountutils
2- ==========
1+ # mountutils
32
43[ ![ npm] ( https://img.shields.io/npm/v/mountutils.svg?style=flat-square )] ( https://npmjs.com/package/mountutils )
54[ ![ npm license] ( https://img.shields.io/npm/l/mountutils.svg?style=flat-square )] ( https://npmjs.com/package/mountutils )
65[ ![ npm downloads] ( https://img.shields.io/npm/dm/mountutils.svg?style=flat-square )] ( https://npmjs.com/package/mountutils )
7- [ ![ Travis CI status] ( https://img.shields.io/travis/resin-io-modules/mountutils/master.svg?style=flat-square&label=linux%20|%20mac )] ( https://travis-ci.org/resin-io-modules/mountutils/branches )
8- [ ![ AppVeyor status] ( https://img.shields.io/appveyor/ci/resin-io/mountutils/master.svg?style=flat-square&label=windows )] ( https://ci.appveyor.com/project/resin-io/mountutils/branch/master )
96
107> Cross platform mount related utilities
118
12- Installation
13- ------------
9+ ## Installation
1410
1511Install ` mountutils ` by running:
1612
1713``` sh
1814$ npm install --save mountutils
1915```
2016
21- Debug mode
22- ----------
17+ ## Debug mode
2318
2419You can enable debug mode by setting the ` MOUNTUTILS_DEBUG ` environment
2520variable.
2621
27- Documentation
28- -------------
22+ ## Documentation
2923
3024<a name =" module_mountutils.unmountDisk " ></a >
3125
3226### mountutils.unmountDisk(device, callback)
27+
3328** Kind** : static method of <code >[ mountutils] ( #module_mountutils ) </code >
3429** Summary** : Unmount a whole disk
35- ** Access** : public
30+ ** Access** : public
3631
37- | Param | Type | Description |
38- | --- | --- | --- |
39- | device | <code >String</code > | device |
32+ | Param | Type | Description |
33+ | -------- | --------------------- | ------------- --- |
34+ | device | <code >String</code > | device |
4035| callback | <code >function</code > | callback (error) |
4136
42- ** Example**
37+ ** Example**
38+
4339``` js
4440// macOS
45- const drive = ' /dev/disk2' ;
41+ const drive = " /dev/disk2" ;
4642
4743// GNU/Linux
48- const drive = ' /dev/sdb' ;
44+ const drive = " /dev/sdb" ;
4945
5046// Windows
51- const drive = ' \\\\ .\\ PHYSICALDRIVE2' ;
47+ const drive = " \\\\ .\\ PHYSICALDRIVE2" ;
5248
5349mountutils .unmountDisk (drive, (error ) => {
5450 if (error) {
5551 throw error;
5652 }
5753
58- console .log (' Done!' );
54+ console .log (" Done!" );
5955});
6056```
6157
62- Support
63- -------
58+ ## Support
6459
6560If you're having any problem, please [ raise an issue] [ newissue ] on GitHub and
6661the Resin.io team will be happy to help.
6762
68- Tests
69- -----
63+ ## Tests
7064
7165Run the test suite by doing:
7266
7367``` sh
7468$ npm test
7569```
7670
77- Troubleshooting
78- ---------------
71+ ## Troubleshooting
7972
8073### ` error C2373: '__pfnDliNotifyHook2': redefinition `
8174
@@ -88,8 +81,7 @@ npm install -g npm@latest
8881
8982See the [ following ` node-gyp ` issue] ( https://github.com/nodejs/node-gyp/issues/972 ) for more details.
9083
91- Contribute
92- ----------
84+ ## Contribute
9385
9486- Issue Tracker: [ github.com/resin-io-modules/mountutils/issues] [ issues ]
9587- Source Code: [ github.com/resin-io-modules/mountutils] [ source ]
@@ -105,8 +97,7 @@ linters run without any warning:
10597$ npm run lint
10698```
10799
108- License
109- -------
100+ ## License
110101
111102The project is licensed under the Apache 2.0 license.
112103
0 commit comments