Skip to content

Instantly share code, notes, and snippets.

View mattmcgiv's full-sized avatar
😎

Matt McGivney mattmcgiv

😎
View GitHub Profile
# update dependency lists
sudo apt-get update
# install build dependencies
sudo apt-get install build-essential libtool autotools-dev automake pkg-config bsdmainutils python3
# more dependencies
sudo apt-get install libevent-dev libboost-dev libboost-system-dev libboost-filesystem-dev libboost-test-dev
# get repo
#!/usr/bin/env python3
# Copyright (c) 2017-2020 The Bitcoin Core developers
# Distributed under the MIT software license, see the accompanying
# file COPYING or http://www.opensource.org/licenses/mit-license.php.
"""A modified version of an example functional test
This test is modified to do the following:
(1) get node 1 to mine another block and send it to node 2
(2) check that node 2 received it
@mattmcgiv
mattmcgiv / add-autocomplete-to-gravity-forms.php
Created January 11, 2017 18:56
add-autocomplete-to-gravity-forms
<?php
add_filter( 'gform_field_content', function ( $field_content, $field ) {
if ( $field->type == 'email' ) {
return str_replace( 'type=', "autocomplete='email' type=", $field_content );
}
if ( $field->type == 'name' ) {
return str_replace( 'type=', "autocomplete='name' type=", $field_content );
}
return $field_content;
import { Component } from '@angular/core';
@Component({
selector: 'app-example',
templateUrl: './example.component.html',
styleUrls: [ './example.component.css' ],
providers: [ MaybeSomeProvider, MaybeAnotherProvider ]
})
export class ExampleComponent {
@mattmcgiv
mattmcgiv / wp-easy-file-path.php
Last active July 9, 2018 02:28
wp easy file path
<?php
/*
* Returns a WP file path
* Parameter: path to file relative to current file
*/
function mm_get_file_path($relative_path_no_preceding_slash) {
return plugin_dir_path(__FILE__) . $relative_path_no_preceding_slash;
}
?>
@mattmcgiv
mattmcgiv / category.php
Created August 17, 2015 19:27 — forked from wpsmith/category.php
Custom Genesis Category Template with Pagination
<?php
/**
* Custom Category Template
*
* @package my_child_theme
* @since 1.0.0
* @author Travis Smith <t@wpsmith.net>
* @copyright Copyright (c) 2013, Travis Smith
* @license http://opensource.org/licenses/gpl-2.0.php GNU Public License
* @link https://gist.github.com/wpsmith/5062834

Contributing

When contributing to this repository, please first discuss the change you wish to make via issue, email, or any other method with the owners of this repository before making a change.

Please note we have a code of conduct, please follow it in all your interactions with the project.

Pull Request Process

  1. Ensure any install or build dependencies are removed before the end of the layer when doing a
#!/bin/bash
curl -o- https://raw.githubusercontent.com/creationix/nvm/v0.33.2/install.sh | bash
export NVM_DIR="$HOME/.nvm"
nvm install 8.2.1 # node newer version install
npm install -g npm
@mattmcgiv
mattmcgiv / 02
Created September 13, 2017 16:35
0x22b07cfd25cf068a444364e8531be5fac8af7ef1
@mattmcgiv
mattmcgiv / 01
Created September 13, 2017 15:21
0xfb70456839B62ca7bA09a1fA9E5a553E5e36D4c4