Instantly share code, notes, and snippets.

ButlerFuqua

View GitHub Profile
View regExCharacterReference
let re;
// Literal Characters
re = /hello/;
re = /hello/i;
// Metacharacter Symbols
re = /^h/i; // Must start with
re = /world$/i; // Must end with
re = /^hello$/i; // Must begin and end with
View regExMethodReference.js
let re;
re = /hello/;
re = /hello/i; // i = case insensitive
// re = /hello/g; // Global search
// console.log(re);
// console.log(re.source);
// exec() - Return result in an array or null
// const result = re.exec(`hello world`);
View killNodeCommands.txt
https://tips.tutorialhorizon.com/2015/10/19/list-running-processes-in-terminal-filter-and-kill-them-if-required/
To find all instances of node running:
ps -a | grep node
-a means all, 'node' means all node instances.
The PID is the first number. The below kills it: