Skip to content

Instantly share code, notes, and snippets.

View kienstra's full-sized avatar
🏠
Working from home

Ryan Kienstra kienstra

🏠
Working from home
View GitHub Profile
@kienstra
kienstra / CLI Setup
Last active June 28, 2022 21:16
Installs CLI packages, like Node and Composer
#!/bin/bash
# Usage:
# curl -o- https://gist.githubusercontent.com/kienstra/af4f8ad4c0606343eeb09e7de117ed93/raw/84d11672958d6d5802fd2cd5cd0c35083dbb7cfc/CLI%2520Setup | bash
echo "Checking that git is installed…"
if [ "$(git --version)" ]
then
echo "git is installed, as expected"
else
@kienstra
kienstra / config.yml
Created January 28, 2022 05:02
A starter .circleci/config.yml
# https://circleci.com/docs/2.0/config-intro/
version: 2.1
jobs:
test:
docker:
- image: cimg/node:16.8.0-browsers
steps:
- checkout
@kienstra
kienstra / launch.json
Last active November 18, 2020 19:53
VS Code Jest debugging configuration for a WordPress plugin
{
"version": "0.2.0",
"configurations": [
{
"name": "WP Plugin Jest unit tests",
"type": "node",
"request": "launch",
"protocol": "inspector",
"cwd": "${workspaceFolder}/sitio/wp-content/plugins/augmented-reality/",
"program": "${workspaceFolder}/sitio/wp-content/plugins/augmented-reality/node_modules/@wordpress/scripts/scripts/test-unit-jest.js",
@kienstra
kienstra / google.svg
Created January 7, 2020 23:45
Mock file for unit test
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
<?php
/**
* Plugin Name: Invalid AMP
* Description: Intentionally outputs invalid AMP.
*/
/**
* Outputs a disallowed <script> for post types of 'page' only.
*/
add_action( 'wp_print_footer_scripts', function() {
.gform_wrapper ul {
padding-left: 0;
list-style: none; }
.gform_wrapper li {
margin-bottom: 15px; }
.gform_wrapper form {
margin-bottom: 0; }