Skip to content

Instantly share code, notes, and snippets.

View jpgninja's full-sized avatar
🎯
Got a ton of interesting projects going on, and loving it.

Chris Mewhort jpgninja

🎯
Got a ton of interesting projects going on, and loving it.
View GitHub Profile
@jpgninja
jpgninja / gulpfile.js
Created January 5, 2018 15:08
Default gulpfile.js that I seem to pass from project to project.
var gulp = require('gulp');
var express = require('express');
var lr = require('tiny-lr')();
var browserify = require('browserify');
var source = require('vinyl-source-stream');
var less = require('gulp-less');
var minify = require('gulp-minify');
var minifycss = require('gulp-minify-css');
var transform = require('vinyl-transform');
var less = require('gulp-less');
@jpgninja
jpgninja / wp_vuln_scan.sh
Last active May 17, 2019 21:19
Bash commands to look for potential vulnerabilities - Currently being copy-pasted to bootstrap code audits for WordPress plugins
# Bash script to scan PHP files for potential vulnerabilities
#
# Currently being copy-pasted to bootstrap code audits for WordPress plugins
#
# Based off of @dustyfresh's https://github.com/dustyfresh/PHP-vulnerability-audit-cheatsheet
#
# XSS
clear && \
@jpgninja
jpgninja / package-commands.md
Last active January 3, 2024 23:13
Common apps, bins & packages to use spinning up a new box.

Common apps, bins & packages

This gist is maintained for whenever I start fresh on a new OS. It's comprised of one-liners that I can copy-paste into a terminal and rapidly spin up my needed apps.

Fresh Install

  • Casks: brew install --cask slack sublime-text transmission dropbox cyberghost-vpn spotify vlc signal whatsapp telegram google-chrome exodus skype sequel-pro brave-browser screaming-frog-seo-spider lulu mamp discord iterm2 omnidisksweeper visual-studio-code megasync yacreader transmit disk-inventory-x notion
  • Bottles: brew install nvm node weechat tor wget git wp-cli mysql composer yt-dlp ffmpeg rar mpv aria2c tree
  • Global npm packages: npm install -g peerflix js-beautify
@jpgninja
jpgninja / cmma_boostrap.js
Last active November 11, 2018 18:25
CMMA Skinner
var cmma_bootstrap = () => {
let until,
i = 0,
cmma_bg_img = "https://imagesvc.timeincapp.com/v3/fan/image?url=https%3A%2F%2Fcagepages.com%2Fwp-content%2Fuploads%2Fgetty-images%2F2016%2F08%2F596465956-ufc-202-diaz-v-mcgregor-2.jpg",
cmma_pg_title = "UFC Fight Night 139 :: Korean Zombie vs. Yair Rodriguess :: Coast MMA Live Stats",
cmma_remove_list = [
'#header',
'#fightTickerContainer',
'#subtitleContainer',
@jpgninja
jpgninja / get-amazon-pic.js
Last active March 24, 2019 18:13
Bookmarklets
!function() {
function init() {
var photoUrl;
// Amazon
// photoUrl = jQuery('.imageViewContainer img')[0].src; // User review image.
photoUrl = jQuery('#ivLargeImage img')[0].src; // Product image.
openPhotoInNewTab( photoUrl );
const axios = require('axios');
const cheerio = require('cheerio');
/**
* Checks if a proxy is accessible.
*
* @param host Host of the proxy
* @param port Port of the proxy
*/
var stop = function(host, port, options, callback) {
@jpgninja
jpgninja / bulk-domain-authority-checker.js
Last active January 16, 2022 14:47
Bulk DA Checker Bookmarklet
/*
* Grabs DA, PA, and MozRank from https://www.robingupta.com/bulk-domain-authority-checker.html
*/
let stats_str = [];
let stats = [];
let out = "";
stats_str = [];
stats = [];
/**
* Process profile edit submissions.
*/
function process_edit_profile_submission() {
// Verify nonce, redirect, and exit.
$bad_nonce = ( ! isset( $_POST['cc_profile_edit_nonce'] ) || ! wp_verify_nonce( sanitize_key( $_POST['cc_profile_edit_nonce'] ), 'cc_profile_edit' ) );
if ( $bad_nonce ) {
// Flash error message.
$flash_msg = [