Skip to content

Instantly share code, notes, and snippets.

View erikgall's full-sized avatar
🏠
Working from home

Erik Galloway erikgall

🏠
Working from home
View GitHub Profile
@dcode
dcode / fanimation_notes.txt
Last active December 23, 2021 06:57
Notes about Fanimation BTLE interface
# Fan List
Sitting Area b0:7e:11:fe:5f:73
Patio 78:04:73:18:bf:8b
Living Room 78:04:73:18:ea:20
# primary
attr handle 0x0001, end grp handle 0x0009 uuid 539c6813-0ad0-2137-4f79-bf1a11984790
attr handle 0x000a, end grp handle 0x0014 uuid 00001800-0000-1000-8000-00805f9b34fb
attr handle 0x0015, end grp handle 0xffff uuid 0000e000-0000-1000-8000-00805f9b34fb
@Akryum
Akryum / List.vue
Created December 15, 2019 14:40
Vue - onScrollBottom composable function
<script>
import { ref } from '@vue/composition-api'
import { onScrollBottom } from '@/scroll'
export default {
setup () {
function loadMore () {
// ...
}
#!/bin/bash
brew update
brew upgrade
brew cleanup -s
brew cask cleanup
brew doctor
brew missing
apm upgrade -c false
@holmberd
holmberd / php-pools.md
Last active September 25, 2024 05:44
Adjusting child processes for PHP-FPM (Nginx)

Adjusting child processes for PHP-FPM (Nginx)

When setting these options consider the following:

  • How long is your average request?
  • What is the maximum number of simultaneous visitors the site(s) get?
  • How much memory on average does each child process consume?

Determine if the max_children limit has been reached.

  • sudo grep max_children /var/log/php?.?-fpm.log.1 /var/log/php?.?-fpm.log
@bradwestfall
bradwestfall / S3-Static-Sites.md
Last active October 14, 2024 15:38
Use S3 and CloudFront to host Static Single Page Apps (SPAs) with HTTPs and www-redirects. Also covers deployments.

S3 Static Sites

⚠ This post is fairly old. I don't keep it up to date. Be sure to see comments where some people have posted updates

What this will cover

  • Host a static website at S3
  • Redirect www.website.com to website.com
  • Website can be an SPA (requiring all requests to return index.html)
  • Free AWS SSL certs
  • Deployment with CDN invalidation
@PurpleBooth
PurpleBooth / README-Template.md
Last active November 5, 2024 15:29
A template to make good README.md

Project Title

One Paragraph of project description goes here

Getting Started

These instructions will get you a copy of the project up and running on your local machine for development and testing purposes. See deployment for notes on how to deploy the project on a live system.

Prerequisites

@qzaidi
qzaidi / pbewithmd5anddes.js
Last active June 1, 2020 22:09
Emulates Java's insecure PBEWITHMD5ANDDES with node.js crypto. Useful for interop with old java programs.
"use strict";
/*
* Emulates Java's PBEWITHMD5ANDDES for node.js
*/
var crypto = require('crypto');
var pbewithmd5anddes = {
KDF: function(password,salt,iterations) {