Skip to content

Instantly share code, notes, and snippets.

View alikrc's full-sized avatar

Ali alikrc

View GitHub Profile
@alikrc
alikrc / README.md
Created August 11, 2020 12:36 — forked from jgoodall/README.md
This is a sample of how to send some information to logstash via the TCP input from node.js or python.

This is a sample of how to send some information to logstash via the TCP input in nodejs or python. It assumes the logstash host is on 10.10.10.100 and the TCP listening input is 9563.

The logstash.conf should look something like the sample file.

The log message should be a stringified JSON object with the log message in the @message field.

To use, run the node script node sendMessageToLogstash.js, or the python script python sendMessageToLogstash.js

@alikrc
alikrc / gist:8f7aacf828f3f827d5082a823a3911bc
Created January 3, 2019 13:39 — forked from jpoehls/gist:2030795
Using CTRL+W to close tabs in Visual Studio

In Tools | Options | Keyboard...

  1. Add CTRL+W as a Global shortcut for Window.CloseDocumentWindow
  2. Remove the CTRL+W shortcut for Edit.SelectCurrentWord

The caveat to this is if you are used to using CTRL+W to select the current word. If you do, find another shortcut that works for that.