Skip to content

Instantly share code, notes, and snippets.

View pilotpirxie's full-sized avatar
🔥
Hardcore Hacking Mode

pilotpirxie

🔥
Hardcore Hacking Mode
  • localhost
View GitHub Profile
@pilotpirxie
pilotpirxie / nginx.conf
Last active April 2, 2019 21:15
My nginx.conf used for reverse proxies for internal Node & React apps
#user root;
worker_processes 1;
error_log logs/error.log warn;
pid /var/run/nginx.pid;
events {
worker_connections 1024;
}
@pilotpirxie
pilotpirxie / DigitalOcean.md
Created May 10, 2019 20:09
Node.js + Nginx + Redis + MySQL + PM2 configuration on DigitalOcean

Node.js + Nginx + Redis + MySQL + PM2 configuration on DigitalOcean

Installation

  1. Install LEMP stack
  2. Overwrite /etc/nginx/nginx.conf
# /etc/nginx/nginx.conf

user www-data;
@pilotpirxie
pilotpirxie / prolog_db.pl
Created October 21, 2019 14:45
Prolog sample written for learning
% loves - predicate
% romeo - atoms
% juliet - atoms
% romeo and juliet are constants and arguments passed to predicate function
loves(romeo, juliet).
loves(juliet, romeo) :-
loves(romeo, juliet).
male(albert).
@pilotpirxie
pilotpirxie / symbol-iterator-roman-numerals.js
Created May 18, 2020 23:06
Well-known Symbol.iterator example with roman numerals
const tab = [1, 7, 14, 4];
tab[Symbol.iterator] = function () {
let index = 0;
const total = this.length;
const values = this;
return {
next() {
const romanize = num => {
const dec = [1000, 900, 500, 400, 100, 90, 50, 40, 10, 9, 5, 4, 1];
@pilotpirxie
pilotpirxie / disallowed.js
Created September 17, 2021 21:02
Disallowed & restricted nicknames / usernames / profile names
const disallowed = ['.json', '.rss', '.well-known', '.xml', '400', '401', '402', '403', '404', '500', '501', '502', '503', '504', '505', 'God', 'Goddamn', 'Username', 'about', 'abuse', 'access', 'account', 'accounts', 'activate', 'activity', 'ad', 'add', 'address', 'adm', 'admin', 'administration', 'administrator', 'admins', 'ads', 'adult', 'advertising', 'affiliate', 'affiliates', 'ajax', 'all', 'anal', 'analytics', 'android', 'anon', 'anonymous', 'anti-bullying', 'anus', 'api', 'app', 'apple', 'apps', 'archive', 'arse', 'ass', 'atom', 'auth', 'authentication', 'autoconfig', 'avatar', 'backup', 'bad', 'badges', 'balls', 'ballsack', 'banner', 'banners', 'bastard', 'best', 'beta', 'biatch', 'billing', 'bin', 'bitch', 'blackberry', 'blame', 'blob', 'blocks', 'blog', 'blogs', 'bloody', 'blowjob', 'board', 'bollock', 'bollok', 'boner', 'boob', 'bot', 'bots', 'bouncers', 'broadcasthost', 'bugger', 'builds', 'bum', 'bundles', 'business', 'butt', 'buttplug', 'cache', 'cadastro', 'calendar', 'campaign', 'career', 'ca
@pilotpirxie
pilotpirxie / tampermonkey-facebook-hide-feed.js
Last active November 11, 2024 11:23
Tampermonkey Hide Facebook Feed
// ==UserScript==
// @name Tampermonkey Hide Facebook Feed
// @namespace http://tampermonkey.net/
// @version 2024-10-09
// @description Remove Facebook main feed while keeping messages and groups
// @author pilotpirxie
// @match https://*.facebook.com/*
// @grant none
// @run-at document-start
// ==/UserScript==