Skip to content

Instantly share code, notes, and snippets.

View chaddy81's full-sized avatar

Chad Bartels chaddy81

View GitHub Profile

Direct copy of pre-encoded file:

$ ffmpeg -i filename.mp4 -codec: copy -start_number 0 -hls_time 10 -hls_list_size 0 -f hls filename.m3u8

@chaddy81
chaddy81 / mysql-docker.sh
Created May 13, 2019 02:57 — forked from spalladino/mysql-docker.sh
Backup and restore a mysql database from a running Docker mysql container
# Backup
docker exec CONTAINER /usr/bin/mysqldump -u root --password=root DATABASE > backup.sql
# Restore
cat backup.sql | docker exec -i CONTAINER /usr/bin/mysql -u root --password=root DATABASE

Keybase proof

I hereby claim:

  • I am chaddy81 on github.
  • I am chaddy81 (https://keybase.io/chaddy81) on keybase.
  • I have a public key ASD49UpA9jDoc9H8x_4jq4MqLINuZHTtqT-o_j9m7maWswo

To claim this, I am signing this object:

@chaddy81
chaddy81 / scss_grid.scss
Created January 28, 2016 19:40
SCSS Grid
$columns: 12 !default;
$gutter: 30px !default;
$max-width: 1170px;
.grid {
margin: 0px auto;
max-width: $max-width;
width: 100%;
}
@chaddy81
chaddy81 / oto
Last active January 22, 2016 15:25 — forked from DannyOutlaw/oto
OTO Test
<?php
/**
* The plugin bootstrap file
*
* This file is read by WordPress to generate the plugin information in the plugin
* admin area. This file also includes all of the dependencies used by the plugin,
* registers the activation and deactivation functions, and defines a function
* that starts the plugin.
*
@chaddy81
chaddy81 / config.json
Last active August 29, 2015 14:24 — forked from anonymous/config.json
PodKeeper Bootstrap Config
{
"vars": {
"@gray-base": "#000",
"@gray-darker": "lighten(@gray-base, 13.5%)",
"@gray-dark": "lighten(@gray-base, 20%)",
"@gray": "lighten(@gray-base, 33.5%)",
"@gray-light": "lighten(@gray-base, 46.7%)",
"@gray-lighter": "lighten(@gray-base, 93.5%)",
"@brand-primary": "darken(#428bca, 6.5%)",
"@brand-success": "#5cb85c",
.calendar-modal {
position: relative;
span {
background: #a0c133;
color: #fff;
font-size: 10px;
left: -30px;
margin-right: 3px;
padding: 3px 3px 2px;
@chaddy81
chaddy81 / api.index.js
Last active December 10, 2016 09:41
Node Sample
var mongodb = require('mongodb');
var mongojs = require('mongojs');
var db = mongojs('database', ['posts']);
exports.index = function(req, res){
var posts = '';
db.posts.find(function(err, docs){
res.json(docs);
});