Skip to content

Instantly share code, notes, and snippets.

View fdev's full-sized avatar

Folkert de Vries fdev

View GitHub Profile
@fdev
fdev / nginx.conf
Created August 24, 2021 13:10 — forked from ragingwind/nginx.conf
Redirect old-classic browser including IE 11
worker_processes 1;
events {
worker_connections 1024;
}
http {
map $http_user_agent $outdated {
default 0;
"~MSIE [1-10]\." 1;
@fdev
fdev / keychron_linux.md
Created July 30, 2021 19:08 — forked from andrebrait/keychron_linux.md
Keychron keyboards on Linux (+ bluetooth fixes)

Here the best setup (I think so :D) for Keychron + Linux

Make Fn + F-keys work

  • Step 1: Set fkeyfirst by:
    • Create the file /etc/modprobe.d/hid_apple.conf. Add this line to the file: options hid_apple fnmode=2
    • Save the file and execute the following command: sudo update-initramfs -u
    • Reboot
  • Step 2: Use the keyboard in Windows/Android mode
  • Step 3: If get stuck with numpad mode: Double hit F6 or fn + F6. I've been using this config since the very first day, both bluetooth and cable with no problem.
@fdev
fdev / GitCommitEmoji.md
Created April 30, 2021 10:22 — forked from parmentf/GitCommitEmoji.md
Git Commit message Emoji
@fdev
fdev / useDocumentVisibility.js
Created April 23, 2019 13:00 — forked from NikaBuligini/useDocumentVisibility.js
useDocumentVisibility (react hook)
import React from 'react';
import useEventListener from './useEventListener';
function getVisibilityPropertyNames() {
// Opera 12.10 and Firefox 18 and later support
if (typeof document.hidden !== 'undefined') {
return ['hidden', 'visibilitychange'];
}
@fdev
fdev / ASS.md
Created March 6, 2019 09:49 — forked from anonymous/ASS.md
Acronyms Seriously Suck - Elon Musk

From time to time, Musk will send out an e-mail to the entire company to enforce a new policy or let them know about something that's bothering him. One of the more famous e-mails arrived in May 2010 with the subject line: Acronyms Seriously Suck:

There is a creeping tendency to use made up acronyms at SpaceX. Excessive use of made up acronyms is a significant impediment to communication and keeping communication good as we grow is incredibly important. Individually, a few acronyms here and there may not seem so bad, but if a thousand people are making these up, over time the result will be a huge glossary that we have to issue to new employees. No one can actually remember all these acronyms and people don't want to seem dumb in a meeting, so they just sit there in ignorance. This is particularly tough on new employees.

That needs to stop immediately or I will take drastic action - I have given enough warning over the years. Unless an acronym is approved by me, it should not enter the SpaceX glossary.