Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@q42philips/statsd-daemon

Package Overview
Dependencies
Maintainers
10
Versions
4
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@q42philips/statsd-daemon - npm Package Compare versions

Comparing version 1.0.0 to 1.1.0

6

package.json
{
"name": "@q42philips/statsd-daemon",
"version": "1.0.0",
"version": "1.1.0",
"description": "Simple statsd deamon to observe metrics being emitted on localhost",

@@ -30,3 +30,7 @@ "main": "src/index.js",

"eslint": "^3.19.0"
},
"dependencies": {
"chalk": "^1.1.3",
"update-notifier": "^2.1.0"
}
}

@@ -9,2 +9,4 @@ # Statsd Daemon

# Usage
## Install

@@ -26,1 +28,32 @@ You can install globally for convenience, which will add a `statsd-daemon` executable to your path:

```
# Contributing
## Local development
You can also create a symlink in your global node modules, making the `hue` binary globally accessible. Note that this only works if you first uninstall the NPM version
``` bash
$ npm uninstall -g @q42philips/statsd-daemon
$ npm link
$ hue <command>
```
And then after testing, just run
``` bash
$ npm unlink
$ npm install -g @q42philips/statsd-daemon
```
## Creating a new release
After PRs are merged to master, you can create a new version using npm. Please carefully check the changes made since the last release and [choose your update type accordingly](http://semver.org/), then create a new version using the command below. This will succeed only if the tests pass, to avoid versioning broken code. It will also push the newly created tag to this repository.
``` bash
$ npm version <major|minor|patch>
```
After creating a new version, you may publish it to the npm registry using the following command, which will automatically compile it using babel before publishing:
``` bash
$ npm publish
```
Finally, please take the time to add a changelog to the newly created release on Github, noting the new features, fixes or other notable stuff.
#! /usr/bin/env node
const updateNotifier = require('update-notifier');
/* Notify if an update is available */
const packageJson = require('../package.json');
updateNotifier({ packageJson }).notify();
const dgram = require('dgram');
const server = dgram.createSocket('udp4');
const chalk = require('chalk');
const PORT = 8125;

@@ -15,6 +23,7 @@ const HOST = '127.0.0.1';

server.on('message', (message, remote) => {
const [keyval, datatype, tags] = message.toString('utf8').split('|');
// eslint-disable-next-line no-console
console.log(`${remote.address}:${remote.port} - ${message}`);
console.log(chalk.cyan(new Date().toTimeString()) + '\t' + chalk.green(keyval) + '(' + chalk.italic.red(datatype) + ')\t' + chalk.italic.yellow(tags));
});
server.bind(PORT, HOST);
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc