Skip to content

Instantly share code, notes, and snippets.

@attebury
attebury / status.sh
Created June 16, 2011 14:52
GeekTool website monitor
#!/bin/bash
# GeekTool script to display status of websites you monitor. See http://projects.tynsoe.org/en/geektool/
# Displays name of site if there's no error. Adds "!!!!" in front of unavailable site.
# Sends an email when a site is unavailable.
ARRAY=(
'awebsite.com'
'anotherwebsite.com'
'onemore.com'
)
@attebury
attebury / gist:1030425
Created June 16, 2011 22:15
List and link all documents and create a new html page
ls | egrep '.pdf|.doc' | sed 's/^/http:\/\/www.thedomain.com\//' | sed 's|\(.*\)|<p><a href=\1>\1<\/a><\/p>|' > list.html

Welcome to Drift!

Drift is an always-already versioned, cloud-backed text editor. You can use it to take notes, and save them in the GitHub cloud.

Your gists are always saved locally, and any changes you make will get pushed to GitHub's servers.

To name a gist, touch its name in the toolbar.

You can use the share button at the top-right to copy a link to one of your gists, or view it on the web in Safari.

@mixin border-radius-specific($radius1, $radius2, $radius3, $radius4) {
-webkit-border-radius: $radius1, $radius2, $radius3, $radius4;
-moz-border-radius: $radius1, $radius2, $radius3, $radius4;
border-radius: $radius1, $radius2, $radius3, $radius4;
}
@attebury
attebury / pure-0.1.0.css
Created June 20, 2013 21:39
Unminified copy for reference. From http://yui.yahooapis.com/pure/0.1.0/pure-min.css normalize.css removed for clarity.
/*!
Pure v0.1.0
Copyright 2013 Yahoo! Inc. All rights reserved.
Licensed under the BSD License.
https://github.com/yui/pure/blob/master/LICENSE.md
*/
.pure-button {
display: inline-block;
*display: inline;
@attebury
attebury / 2014-1-28-this-is-a-test-post.md
Last active January 4, 2016 21:09
Test markdown styles in a GitHub Pages Jekyll blog.
layout tags
posts
css github jekyll markdown grunt

This is a test post which will contain enough markup to test CSS styles.

It should have a

@attebury
attebury / in-your-head.html
Last active August 29, 2015 13:55
Touch Icons and Favicon
<!-- Favicon -->
<link rel="shortcut icon" href="/assets/v1/img/icons/favicon.ico" type="image/x-icon">
<link rel="shortcut icon" href="/assets/v1/img/icons/favicon.png">
<!-- Retina iPad -->
<link rel="apple-touch-icon" sizes="144x144" href="/assets/v1/img/icons/apple-touch-icon-144x144.png" />
<!-- Retina iPhone, iPod Touch -->
<link rel="apple-touch-icon" sizes="114x114" href="/assets/v1/img/icons/apple-touch-icon-114x114.png" />
@attebury
attebury / submit-closest-form.js
Last active May 9, 2023 21:21
Submit the form closest to a button.
/*
* A jQuery alternative to providing a custom ID selector to submit a form
* is to submit the form closest to the button that has been clicked.
* See http://api.jquery.com/closest/
*/
$('.js-btn-submit').on('click', function(e) {
e.preventDefault();
$(this).closest('form').submit();
});
@attebury
attebury / bo-table__data--collapsible.html
Last active August 15, 2018 19:19
Collapsible table example
<!--
*
* The table container expands to fill the width of its parent column.
*
* Uses progressive enhancement so hidden rows are visible without javascript.
* Requires the absence of a .no-js class on the <html> node.
*
* Place this in the document head for progressive enhancement
* <script type="text/javascript">
* document.documentElement.classList.remove('no-js');
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>JS Bin</title>
</head>
<body>
<label>
<input type="radio" name="days" value="15" checked /> 15