Skip to content

Instantly share code, notes, and snippets.

:octocat:
Probably writing.

Colin Devroe cdevroe

Block or report user

Report or block cdevroe

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
@cdevroe
cdevroe / readme.md
Last active Jun 6, 2018
YouTube pop-up Bookmarklet
View readme.md

YouTube Pop-up Bookmarklet

I forget where I found this originally (sorry). And I've modified it slightly over the years. But if you're on YouTube in a desktop browser and you'd like to have the video in a small pop-up window, tap this bookmarklet and it automatically creates the perfectly sized window for you.

How to install

  1. Create a new bookmark with any URL.
  2. Edit that bookmark in your browser, delete the URL that is there, and paste the code you see in the JS file into the Location field.

You're welcome / Colin

View microblog-userstyle.css
/* Add bottom border and some spacing to each post. */
.post {
border-bottom: 1px solid rgb(230, 236, 240);
margin-bottom: 20px;
}
/* Move avatar to left */
.post .post_avatar {
float: left;
width: 18%;
}
@cdevroe
cdevroe / nepa-gulp.js
Created Jul 14, 2017
NEPA.js Gulp Demo
View nepa-gulp.js
/*
Task: NepaJS
Does some silly things for NEPA JS
*/
gulp.task('nepajs', function() {
var nepajsURL = 'https://www.meetup.com/NEPA-js/',
nepaJSDirWin = '/mnt/c/Users/tucker/Desktop/',
nepaJSDirMac = '/Users/cdevroe/Desktop/',
@cdevroe
cdevroe / tweet-status.php
Created Jan 25, 2017
Publish posts, statuses, images, to Twitter from WordPress
View tweet-status.php
<?php
/**
* Plugin Name: Tweet Statuses
* Description: A simple plugin that will tweet a status when published.
* Author: Colin Devroe
* Author URI: http://cdevroe.com/
* Version: 0.1.0
*
* TwitterAPIExchange is here: http://github.com/j7mbo/twitter-api-php
*/
@cdevroe
cdevroe / convert_roman.js
Created Jan 9, 2017
INCOMPLETE: Convert number into Roman numeral in JavaScript
View convert_roman.js
(function (win,doc) {
'use strict';
var submit = document.getElementById('submit');
submit.addEventListener( 'click', function(){
var number = document.getElementById('number'),
roman_numeral = document.getElementById('roman');
roman_numeral.innerHTML = convert_to_roman(number.value);
@cdevroe
cdevroe / wp-is_published-is_draft.php
Created Jan 6, 2016
WordPress is_published is_draft functions
View wp-is_published-is_draft.php
<?php
/**
* Determine whether a post or page is published or not.
*
* @return bool
*/
function is_published(){
$post = get_post();
if ( $post->post_status == 'publish' ) return true;
@cdevroe
cdevroe / Template_Client-Call.txt
Created Nov 19, 2015
Client Call Text Document Template
View Template_Client-Call.txt
Template: Client Call % Client Name % - % Date %
# Call information
Dial-in information:
- Number:
- Pin:
- URL:
Parties on call:
@cdevroe
cdevroe / hypertext-member-blogs.opml
Last active Dec 10, 2015
Hypertext Member Blogs
View hypertext-member-blogs.opml
<?xml version="1.0" encoding="UTF-8"?>
<opml version="1.0">
<head>
<title>Hypertext Member Blogs</title>
</head>
<body>
<outline text="Hypertext Member Blogs" title="Hypertext Member Blogs">
<outline type="rss" text="Colin Devroe" title="Colin Devroe" xmlUrl="http://cdevroe.com/feed" htmlUrl="http://cdevroe.com/"/>
<outline type="rss" text="Hypertext" title="Hypertext by Justin Blanton" xmlUrl="http://feeds.feedburner.com/jblanton" htmlUrl="http://hypertext.net"/>
@cdevroe
cdevroe / gist:4fb3ebf7806b39020c33
Created May 28, 2015
Open Visual Studio Code from Terminal
View gist:4fb3ebf7806b39020c33
code () {
if [[ $# = 0 ]]
then
open -a "Visual Studio Code" -n
else
[[ $1 = /* ]] && F="$1" || F="$PWD/${1#./}"
open -a "Visual Studio Code" -n --args "$F"
fi
}
@cdevroe
cdevroe / settings.json
Created Dec 14, 2014
settings.json file for GetBarley.com
View settings.json
{
"name": "Streetshark",
"creator": "Plain",
"creator_url": "http://plainmade.com",
"blog": "news",
"content_types": {
"articles": "Article",
"releases": "Release Month"
},
"feed": [
You can’t perform that action at this time.