node-modules / Detect Port
Licence: mit
Node.js implementation of port detector
Stars: ✭ 286
Programming Languages
javascript
184084 projects - #8 most used programming language
Projects that are alternatives of or similar to Detect Port
Free Courses
A collection of free courses about programming 📖
Stars: ✭ 281 (-1.75%)
Mutual labels: free
Taiyakianime
Stream anime and synchronize with your MyAnimeList(MAL) + SIMKL + Anilist on iOS and Android devices
Stars: ✭ 259 (-9.44%)
Mutual labels: free
Starrtc Android Demo
🚀starRTC,即时通讯(IM)系统,免费IM系统(含单聊,群聊,聊天室,文件传输),免费一对一视频聊天,VOIP,语音对讲(回音消除),直播连麦,视频直播,RTSP拉流,RTMP推流,webRTC服务端,在线教育,白板,小班课,在线会议,视频会议,视频监控,局域网直连(无需服务器),兼容webRTC, 支持webRTC加速,P2P高清传输,安卓、iOS、web互通,支持门禁对讲,可视对讲,电视盒子,树莓派,海思,全志,任天堂switch,云游戏,OTT设备,物联网平台,C语言自研方案,支持二次开发成类微信,类映客等APP,✨万水千山总是情,来个star行不行✨,更多示例请访问:
Stars: ✭ 3,038 (+962.24%)
Mutual labels: free
Triplea
TripleA is a turn based strategy game and board game engine, similar to Axis & Allies or Risk.
Stars: ✭ 268 (-6.29%)
Mutual labels: free
android-SpringAnimator
A framer.js DHO and RK4 spring animation port for Android.
Stars: ✭ 39 (-86.36%)
Mutual labels: port
Imagedetect
✂️ Detect and crop faces, barcodes and texts in image with iOS 11 Vision api.
Stars: ✭ 286 (+0%)
Mutual labels: detector
Startbootstrap Business Casual
A Bootstrap HTML theme for business websites - created by Start Bootstrap
Stars: ✭ 266 (-6.99%)
Mutual labels: free
Mega Doodles Pack
🔥 Big vector pack with hand-drawn doodles for presentations, social media, blog posts and so on
Stars: ✭ 258 (-9.79%)
Mutual labels: free
Awesome Free Services
Awesome free online services for startups and freelancers!
Stars: ✭ 269 (-5.94%)
Mutual labels: free
Free Vpn
We Provide Newset Free VPN Service. PC, mobile phones and network appliances, no software installation. With the VPN Service,you can get through your government's firewall to browse restricted websites.提供最新的免费的 VPN 服务,通过使用 VPN 自由访问互联网(翻墙)!无论是PC端,移动端都无需安装客户端。
Stars: ✭ 284 (-0.7%)
Mutual labels: free
awake-action
Keep your free servers, clusters, dynos awaken (ex: heroku, mongodb, etc.)
Stars: ✭ 152 (-46.85%)
Mutual labels: free
Startbootstrap Shop Homepage
A shop homepage Bootstrap HTML template created by Start Bootstrap
Stars: ✭ 261 (-8.74%)
Mutual labels: free
Readme Template
📜 Modelos readme para qualquer pessoa copiar e usar em seu GitHub.
Stars: ✭ 287 (+0.35%)
Mutual labels: free
Awesome Bulma Templates
🚀 Free real-world templates built with Bulma
Stars: ✭ 283 (-1.05%)
Mutual labels: free
Node.js implementation of port detector
Who are using
- ⭐⭐⭐eggjs/egg
- ⭐⭐⭐alibaba/ice
- ⭐⭐⭐alibaba/uirecorder
- ⭐⭐⭐facebook/create-react-app
- ⭐⭐⭐facebook/flipper
- ⭐⭐⭐umijs/umi
- ⭐⭐⭐gatsbyjs/gatsby
- ⭐⭐⭐electron-react-boilerplate/electron-react-boilerplate
- ⭐⭐⭐zeit/micro
- ⭐⭐⭐rails/webpacker
- ⭐⭐⭐storybookjs/storybook
Usage
$ npm i detect-port --save
const detect = require('detect-port');
/**
* callback usage
*/
detect(port, (err, _port) => {
if (err) {
console.log(err);
}
if (port == _port) {
console.log(`port: ${port} was not occupied`);
} else {
console.log(`port: ${port} was occupied, try port: ${_port}`);
}
});
/**
* for a yield syntax instead of callback function implement
*/
const co = require('co');
co(function *() {
const _port = yield detect(port);
if (port == _port) {
console.log(`port: ${port} was not occupied`);
} else {
console.log(`port: ${port} was occupied, try port: ${_port}`);
}
});
/**
* use as a promise
*/
detect(port)
.then(_port => {
if (port == _port) {
console.log(`port: ${port} was not occupied`);
} else {
console.log(`port: ${port} was occupied, try port: ${_port}`);
}
})
.catch(err => {
console.log(err);
});
Command Line Tool
$ npm i detect-port -g
Quick Start
# get an available port randomly
$ detect
# detect pointed port
$ detect 80
# output verbose log
$ detect --verbose
# more help
$ detect --help
FAQ
Most likely network error, check that your /etc/hosts
and make sure the content below:
127.0.0.1 localhost
255.255.255.255 broadcasthost
::1 localhost
Contributors
xudafeng |
fengmk2 |
ziczhu |
gaearon |
chnliquan |
popomore |
---|---|---|---|---|---|
iamyinyue |
This project follows the git-contributor spec, auto updated at Tue Jul 30 2019 22:07:39 GMT+0800
.
License
Note that the project description data, including the texts, logos, images, and/or trademarks,
for each open source project belongs to its rightful owner.
If you wish to add or remove any projects, please contact us at [email protected].