var arr = ['create', 'edit', 'enable', 'disable', 'check', 'fire'];
function inArray(needle, arrhaystack) {
return (arrhaystack.indexOf(needle) > -1);
}
console.log(inArray('edit', arr));
console.log(inArray('restart', arr));
function isJson(str) {
try {
JSON.parse(str);
} catch (e) {
return false;
}
return true;
}
One of the best things about being a MATE user is the fact that everything is super stable and reliable. This desktop environment hasn’t changed its looks in quite a long time. Everything is nearly like the way it looked in 2002.
This can be a good thing when it comes to usability. It’s tried and true. On the other hand, the MATE desktop doesn’t look very modern. The default themes it ships with aren’t very attractive, and overall it seems like it needs a face-lift.
Check out these nine themes that look great in the MATE desktop environment!
Two very nice, tested and working themes + icon set.
Ambiance & Radiance Flat
Vibrancy Colors Icon
To find the tool to reconfigure the audio ports is this easy under Ubuntu 14.04.1 LTS.
sudo apt-get install alsa-tools-gui
hdajackretask
Usage:
ps_mem [-h|--help] [-p PID,...] [-s|--split-args] [-t|--total] [-w N]
Example output:
Private + Shared = RAM used Program
34.6 MiB + 1.0 MiB = 35.7 MiB gnome-terminal
139.8 MiB + 2.3 MiB = 142.1 MiB firefox
291.8 MiB + 2.5 MiB = 294.3 MiB gnome-shell
272.2 MiB + 43.9 MiB = 316.1 MiB chrome (12)
913.9 MiB + 3.2 MiB = 917.1 MiB thunderbird
---------------------------------
1.9 GiB
=================================