Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/reg499/node-mutex-checker
https://github.com/reg499/node-mutex-checker
mutex mutex-control
Last synced: 3 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/reg499/node-mutex-checker
- Owner: reg499
- License: mit
- Created: 2024-09-12T11:16:52.000Z (5 months ago)
- Default Branch: main
- Last Pushed: 2024-09-22T13:00:37.000Z (4 months ago)
- Last Synced: 2024-10-30T16:20:15.002Z (3 months ago)
- Topics: mutex, mutex-control
- Language: C++
- Homepage:
- Size: 10.7 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# [Node Mutex Checker](https://www.npmjs.com/package/node-mutex-checker)
A Node.js addon to check and create mutexes on Windows systems using C++ bindings. This project provides the functionality to check for the existence of a mutex on the system and create a new mutex if needed.
```bash
npm i node-mutex-checker
```## Usage
```javascript
const { createMutex, checkMutex } = require("node-mutex-checker");const mutexName = "mutex123";
const created = createMutex(mutexName);
console.log(`Mutex created: ${created}`);const exists = checkMutex(mutexName);
console.log(`Mutex exists: ${exists}`);
```