Skip to content

Instantly share code, notes, and snippets.

Ben Peachey Potherca

Block or report user

Report or block Potherca

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
@Potherca
Potherca / pipeline-components-pulls.md
Last active Dec 6, 2019
Amount of pulls from docker hub for each of the gitlab pipeline-components.
View pipeline-components-pulls.md

This page shows the amount of pulls each one of the Gitlab Pipeline-Components have received thus far.

(List sorting update December 2019)

100k+

@Potherca
Potherca / README - Fair Finance Guide International.md
Last active Dec 2, 2019
Dutch Fair Finance Guide Scores (eerlijkegeldwijzer.nl) - Total scores
View README - Fair Finance Guide International.md

Introduction

Fair Finance Guide International (FFGI) is an international civil society network initiated by Oxfam, that seeks to strengthen the commitment of banks and other financial institutions to social, environmental and human rights standards.

Every year, the FFGI publishes records of how financial institutions perform on a set of subjects.

For the Netherlands these results are published at https://eerlijkegeldwijzer.nl/

The website shows the scores for each company per subject but does not show a total.

View programming-quotes.md
@Potherca
Potherca / README.md
Last active Nov 15, 2019
Converting a webm file to GIF (using FFmpeg and Gifsicle)
View README.md

Introduction

Sometimes I want to make a screencapture of a websites behaviour.

In Chrome, I am quite happy doing this with the [Awesome Screenshot: Screen Video Recorder][1] extension.

Besides screenshots, the extension offers the ability to make a recording. (Limited to 30 seconds in the free version).

The recording can be uploaded to Youtube or Google Drive. It can also be downloaded as WebM file.

@Potherca
Potherca / Create-branch-with-Github-API.md
Last active Nov 11, 2019
Create a branch on Github without access to a local git repo using http://hurl.eu/
View Create-branch-with-Github-API.md

Ever had the need to create a branch in a repo on Github without wanting (or being able) to access a local repo?

With the aid of [the Github API][1] and [hurl.eu][2] this is a piece of cake!

Just follow these steps:

  1. Open [http://hurl.eu/][2]
  2. Find the revision you want to branch from. Either on Github itself or by doing a GET request from Hurl: https://api.github.com/repos/<AUTHOR>/<REPO>/git/refs/heads
  3. Copy the revision hash
  4. Do a POST request from Hurl to https://api.github.com/repos/<AUTHOR>/<REPO>/git/refs with the following as the POST body :
@Potherca
Potherca / mini-mustache.php
Last active Nov 6, 2019
A minimal implementation of Mustache in PHP. Supports escaped and HTML Variables, Comments, Sections and Inverted Section. Does not support Lists, Callbacks, Partials or Delimiter setting.
View mini-mustache.php
<?php
/**
* In Mustache syntax, values are represented by "tags".
*
* Tags are indicated by double braces (a.k.a. curly brackets): {{name}}
*
* To check if a value is available use a "section". A section is a tag that is
* prefixed with a pound `#` character. The closing tag is prefixed with a
* slash `/`. For example, to only show "name" when it is available:
*
@Potherca
Potherca / README.md
Last active Oct 27, 2019
HOWTO: Skip files outside PhpStorm project in Xdebug sessions
View README.md

Introduction

In PHP development environments, it is not entirely uncommon to use an auto_prepend_file to add development-specific functionality to an application. Usually such a file is used for several projects at the same time. This means the prepend file resides somewhere in a more high-level location.

A more common practice is to use Xdebug te debug PHP code.

When combining these two with PhpStorm this will lead to the prepend file being marked as "not mapped".

Problem

View programming-quotes.md
@Potherca
Potherca / logo-pipeline-components-animated.svg
Last active Oct 5, 2019
Animated SVG version of the Pipeline-Component logo
View logo-pipeline-components-animated.svg
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@Potherca
Potherca / README.md
Last active Sep 23, 2019
The search for a Regex to match BEM CSS class-names
View README.md

The search for a Regex to match BEM CSS class-names

TL;DR

Use this regular expression to match BEM class-names:

^\.[a-z]([a-z0-9-]+)?(__([a-z0-9]+-?)+)?(--([a-z0-9]+-?)+){0,2}$
You can’t perform that action at this time.