ffmpeg -i input.mp4 -vcodec libvpx -qmin 0 -qmax 50 -crf 10 -b:v 1M -acodec libvorbis output.webm
ffmpeg -i input.webm -vcodec libx264 output.mp4
/************************************************************************ | |
Name: XGrid | |
Version: 1.0.0 | |
License: MPL-2.0 | |
Author: Alexander Elias | |
Email: alex.steven.elis@gmail.com | |
This Source Code Form is subject to the terms of the Mozilla Public | |
License, v. 2.0. If a copy of the MPL was not distributed with this | |
file, You can obtain one at http://mozilla.org/MPL/2.0/. | |
************************************************************************/ |
#include <dt-bindings/zmk/matrix-transform.h> | |
/ { | |
chosen { | |
zmk,kscan = &kscan0; | |
zmk,matrix_transform = &default_transform; | |
}; | |
default_transform: keymap_transform_0 { | |
compatible = "zmk,matrix-transform"; |
window.location.hostname.indexOf('github.io') === -1 ? null : document.querySelector('base').href = '/' + window.location.pathname.split('/')[1] + '/'; |
#!/usr/bin/env bash | |
MCU=atmega32u4 | |
if grep -q -s Microsoft /proc/version; then | |
echo 'ERROR: Pro Micros can not be flashed within the Windows Subsystem for Linux (WSL) currently. Instead, take the .hex file generated and flash it using AVRDUDE, AVRDUDESS, or XLoader.' | |
exit 1 | |
fi | |
if [ "$#" -ne 1 ]; then |
Examples of getting certificates from Let's Encrypt working on Apache, NGINX and Node.js servers.
I chose to use the manual method, you have to make a file available to verify you own the domain. Follow the commands from running
git clone https://github.com/letsencrypt/letsencrypt
cd letsencrypt
const Http = require('http'); | |
const Crypto = require('crypto'); | |
const query = 'key=value'; | |
const sharedSecret = 'secret'; | |
const signature = Crypto.createHmac('sha256', sharedSecret).update(query).digest('hex'); | |
Http.get({ | |
port: 8000, |
'use strict'; | |
const crypto = require('crypto'); | |
const ENCRYPTION_KEY = process.env.ENCRYPTION_KEY; // Must be 256 bytes (32 characters) | |
const IV_LENGTH = 16; // For AES, this is always 16 | |
function encrypt(text) { | |
let iv = crypto.randomBytes(IV_LENGTH); | |
let cipher = crypto.createCipheriv('aes-256-cbc', new Buffer(ENCRYPTION_KEY), iv); |
function each (condition, method, context, index) { | |
index = index === undefined ? 0 : index; | |
if (condition.call(context, index)) { | |
return Promise.resolve().then(function () { | |
return method.call(context, index); | |
}).then(each.bind(null, condition, method, context, index+1)); | |
} else { | |
return Promise.resolve(); | |
} |