Skip to content

Instantly share code, notes, and snippets.

Josh Loomis BlueInkAlchemist

Block or report user

Report or block BlueInkAlchemist

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@BlueInkAlchemist
BlueInkAlchemist / fetch.php
Created Jan 8, 2019
WordPress plugin for API consumption
View fetch.php
<?php
/**
* @package WooCommerce API Data Builder
* @version 0.4
*/
/*
Plugin Name: API Data Builder
Description: Creates REST API endpoint & builds the JSON response from the WooCommerce API
Author: Josh Loomis
Version: 0.4
@BlueInkAlchemist
BlueInkAlchemist / Makefile
Created May 18, 2018
Node Bootstrap Makefile
View Makefile
REPORTER = spec
all: jshint test
test:
@NODE_ENV=test ./node_modules/.bin/mocha --recursive --reporter $(REPORTER) --timeout 3000
jshint:
jshint lib examples test index.js
@BlueInkAlchemist
BlueInkAlchemist / paypal-payout-helper.class.php
Last active Jun 8, 2018
WordPress PHP Class facilitating automated PayPal transactions.
View paypal-payout-helper.class.php
<?php
class Paypal_Payout_Helper {
protected static $instance = null;
private function __construct() {
}
public static function get_instance() {
if( null == self::$instance ) {
self::$instance = new self;
}
return self::$instance;
@BlueInkAlchemist
BlueInkAlchemist / sum_multiples.py
Created Apr 7, 2018
Sum all multiples of 3 & 5 up to 1000, using Python
View sum_multiples.py
# 1. Get the upper bounds for the arithmetic series.
## Ensure that no limit reaches 1000.
LIMIT=999
upper_for_three = LIMIT // 3
upper_for_five = LIMIT // 5
upper_for_fifteen = LIMIT // 15
# 2. Calculate sums from within individual bounds.
sum_three = 3*upper_for_three*(1 + upper_for_three) / 2
View countUp.html
<h1>The results of the function are:</h1>
<p id="fill"></p>
You can’t perform that action at this time.