Skip to content

Instantly share code, notes, and snippets.

Howard Panton howardpanton

Block or report user

Report or block howardpanton

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
@howardpanton
howardpanton / brew_symlink_error_sierra.md
Created Oct 20, 2018 — forked from dalegaspi/brew_symlink_error_sierra.md
Homebrew Symlink errors in Mac OSX High Sierra
View brew_symlink_error_sierra.md
@howardpanton
howardpanton / sanitizehtml.pipe.ts
Created Apr 17, 2018 — forked from Bloggerschmidt/sanitizehtml.pipe.ts
angular 4 pipe for bypass security trust html
View sanitizehtml.pipe.ts
// <div [innerHTML]="your.value | sanitizeHtml" ></div>
import { Pipe, PipeTransform } from '@angular/core';
import { DomSanitizer, SafeHtml } from '@angular/platform-browser';
@Pipe({name: 'sanitizeHtml'})
export class SanitizeHtmlPipe implements PipeTransform {
constructor(private _sanitizer:DomSanitizer) {
}
transform(v:string):SafeHtml {
@howardpanton
howardpanton / Dockerfile
Created Feb 8, 2018
Angular Dockerfile
View Dockerfile
# Pull the latest Node image from Docker
FROM node:latest
# Copy the current directory contents into the container at /app
COPY ./ /app/
# Set the working directory to /app
WORKDIR /app
# Install Node Modules
@howardpanton
howardpanton / hapijs-rest-api-tutorial.md
Created Jul 28, 2016 — forked from agendor/hapijs-rest-api-tutorial.md
A practical introduction to building a RESTful API with the hapi.js server framework for Node.js
View hapijs-rest-api-tutorial.md
@howardpanton
howardpanton / Fix Cygwin Issue with RubyGem
Created Oct 8, 2015 — forked from devcfgc/Fix Cygwin Issue with RubyGem
No such file or directory — /cygdrive/c/Ruby/bin/gem (LoadError)
View Fix Cygwin Issue with RubyGem
//We must add the following to your .bashrc (C:\cygwin\home\user\.bashrc):
alias ruby='/cygdrive/c/Ruby21-x64/bin/ruby'
alias gem='/cygdrive/c/Ruby21-x64/bin/gem.bat'
alias irb='/cygdrive/c/Ruby21-x64/bin/irb.bat'
alias compass='/cygdrive/c/Ruby21-x64/bin/compass.bat'
alias sass='/cygdrive/c/Ruby21-x64/bin/sass.bat'
alias scss='/cygdrive/c/Ruby21-x64/bin/scss.bat'
View Matslabs question 5 bonus
//
// Matslab Question 5 Bonus
// Howard PAnton
//
(function() {
// Add new input option
$(".add_button").click(function(){
var value = $(".option_name").val();
View Web Development test
<?php
//Q1. PHP - Complete remove_nonAtoZ() below
function remove_nonAtoZ($input) {
// example data: $input = "BA'3Ndf$%^A&*(nN)A";
// $output = "BANANA";
// Create RegExpr to remove non capital letters
$pattern = "/[A-Z]+/";
// Filter using Preg Match
preg_match_all($pattern, $input, $match);
View licence agreement
<head>
<!--[Font include]
/**
* @license
* MyFonts Webfont Build ID 2886433, 2014-09-19T11:53:00-0400
*
* The fonts listed in this notice are subject to the End User License
* Agreement(s) entered into by the website owner. All other parties are
* explicitly restricted from using the Licensed Webfonts(s).
*
View README.md

Adding HipChat support to applications

Simple instruction that show you how to add HipChat support for your app so that it will post to a room of your choice, preferably one for the application in question. Both require an API token which you can get from Niklas. v2 of the HipChat API lets you use your own tokens, but I couldn't get that working intially.

Travis

You can optionally use secure tokens in your travis.yml file. It requires you to install the travis command line tool:

$ gem install travis

View gulpfile.js
var gulp
= require('gulp'),
gutil = require('gulp-util'),
gutils = require('gulp-load-utils')(['date']);
sass = require('gulp-sass'),
csso = require('gulp-csso'),
uglify = require('gulp-uglify'),
jade = require('gulp-jade'),
concat = require('gulp-concat'),
livereload = require('gulp-livereload'), // Livereload plugin needed: https://chrome.google.com/webstore/detail/livereload/
You can’t perform that action at this time.