Skip to content

Instantly share code, notes, and snippets.

View shindakun's full-sized avatar
💭
:shipit:

Steve Layton shindakun

💭
:shipit:
View GitHub Profile
client.on('chat', (channel, user, message, self) => {
switch(message) {
case '!twitter':
client.action('shinbot', `${user['display-name']} you can find it at twitter.com/shindakun`);
break;
case '!github':
client.action('shinbot', `${user['display-name']} you can find it at github.com/shindakun`);
break;
case '!timer':
setTimeout(function(){ client.action('shindakun', `${user['display-name']} 5 seconds has passed`); }, 5000);
@shindakun
shindakun / gbook-post.md
Created December 31, 2019 08:51
Hugo Gbook Shortcode

{{< gbook isbn="1932234411" >}}

@shindakun
shindakun / perfer-darkness.css
Created December 18, 2019 04:52
micro.blog dark mode start
@media (prefers-color-scheme: dark) {
body {
color: #ddd;
background-color: #333;
}
a {
color: #88c0ef;
}
// Without the protocol it will throw the following:
// $ go run main.go
// Get podcasts.files.bbci.co.uk/b006qtl3.rss: unsupported protocol scheme ""
package main
import (
"fmt"
"io/ioutil"
"net/http"

Keybase proof

I hereby claim:

  • I am shindakun on github.
  • I am shindakun (https://keybase.io/shindakun) on keybase.
  • I have a public key ASC6wFaGOP3oBAWQEqW0WhC7xwAMj7nKbm0xucssZc3XGAo

To claim this, I am signing this object:

showAPIError: function (resp, defaultErrorText) {
defaultErrorText = defaultErrorText || 'There was a problem on the server, please try again.';
if (resp && resp.jqXHR && resp.jqXHR.responseJSON && resp.jqXHR.responseJSON.error) {
this.showError(resp.jqXHR.responseJSON.error);
} else if (resp && resp.jqXHR && resp.jqXHR.responseJSON && resp.jqXHR.responseJSON.errors) {
for (var i = 0; i < resp.jqXHR.responseJSON.errors.length; i += 1) {
this.showError(resp.jqXHR.responseJSON.errors[i].message);
}
} else {
@shindakun
shindakun / gist:6380100
Created August 29, 2013 16:09
WordPress child theme header snippet.
<?php if(!is_front_page()) : ?>
<?php $header_image = get_header_image();
if ( ! empty( $header_image ) ) : ?>
<a href="<?php echo esc_url( home_url( '/' ) ); ?>"><img src="<?php echo esc_url( $header_image ); ?>" class="header-image" width="<?php echo get_custom_header()->width; ?>" height="<?php echo get_custom_header()->height; ?>" alt="" /></a>
<?php endif; ?>
<?php endif; ?>
@shindakun
shindakun / index.html
Created October 23, 2012 06:27
A CodePen by Steve. 25 Cent Play Header and Featured Posts - Working on adding a featured posts section to the 25 Cent Play Website, will be part of our WordPress theme when done. http://www.25centplay.com @25centplay
<div class="container">
<div class="content">
<div class="header"> <!-- 860px x 245 px -->
<img src="http://www.shindakun.net/images/25cent_header.jpg" alt="25 Cent Play" /><!-- 800px x 214px -->
<div class="header-featured">
<div class="header-featured-item">
<img src ="http://www.shindakun.net/images/logo_smaller.jpg" alt="XCOM" title="XCOM" />
XCOM Review
</div>
<div class="header-featured-item">