Skip to content

Instantly share code, notes, and snippets.

View ecklf's full-sized avatar
💫
流星

Florentin / 珞辰 ecklf

💫
流星
View GitHub Profile
@ecklf
ecklf / readme.md
Created October 9, 2023 13:53 — forked from mikeatlas/readme.md
maxfiles ulimit on macos
@ecklf
ecklf / bcm4352-wifi-ac.md
Created April 18, 2022 08:57 — forked from jppommet/bcm4352-wifi-ac.md
Linux Ubuntu Drivers for Broadcom Chipset BCM4352 802.11ac Wireless Network Adapter [14e4:43b1]
@ecklf
ecklf / global.d.ts
Last active September 24, 2021 21:50
@mdx/js type defs
declare module "*.mdx" {
let MDXComponent: (props: any) => JSX.Element;
export default MDXComponent;
export const frontMatter: FrontMatter[];
}
@ecklf
ecklf / countries.sql
Created September 23, 2021 12:21 — forked from ereli/countries.sql
Sql dump of all the Countries, Country Codes, Phone codes. PostgreSQL compatible
CREATE SEQUENCE country_seq;
CREATE TABLE IF NOT EXISTS country (
id int NOT NULL DEFAULT NEXTVAL ('country_seq'),
iso char(2) NOT NULL,
name varchar(80) NOT NULL,
nicename varchar(80) NOT NULL,
iso3 char(3) DEFAULT NULL,
numcode smallint DEFAULT NULL,
phonecode int NOT NULL,
@ecklf
ecklf / amazon.md
Created September 22, 2021 19:52 — forked from terabyte/amazon.md
Amazon's Build System

Prologue

I wrote this answer on stackexchange, here: https://stackoverflow.com/posts/12597919/

It was wrongly deleted for containing "proprietary information" years later. I think that's bullshit so I am posting it here. Come at me.

The Question

Amazon is a SOA system with 100s of services (or so says Amazon Chief Technology Officer Werner Vogels). How do they handle build and release?

@ecklf
ecklf / useTimedEvent.ts
Last active September 7, 2021 09:24
Trigger an event after holding down an element for a duration
// Usage:
// const Button = () => {
// const { completion, ...bind } = useTimedEvent(() => { fire(); }, { duration: 1000 });
// return <button {...bind}>Button</button>;
// };
import { useEffect, useRef, useState } from "react";
const useTimedEvent = (
callback: (() => void) | (() => Promise<void>),
netsh winsock reset
ipconfig /release
netsh int ip reset
ipconfig /flushdns
ipconfig /renew
@ecklf
ecklf / useStatusBarHeight.ts
Last active July 2, 2024 19:40
Determine the current status bar height. This is useful to determine keyboardVerticalOffset for KeyboardAvoidingView, since iPhone X and newer use different dimensions.
import { useEffect, useState } from "react";
import {
NativeEventEmitter,
NativeModules,
Platform,
StatusBar,
} from "react-native";
const { StatusBarManager } = NativeModules;
@ecklf
ecklf / Uninstall-pkg.md
Created March 17, 2021 12:55 — forked from githubutilities/Uninstall-pkg.md
Uninstall pkg manually in OS X

Mac Uninstall pkg Manually

  • using pkgutil
# list all your installed packages
pkgutil --pkgs

# show your package info
pkgutil --pkg-info 
@ecklf
ecklf / next.config.js
Created March 15, 2021 19:11 — forked from pi0/next.config.js
Webpackbar with Next.js
const Webpackbar = require('webpackbar')
module.exports = {
webpack: (config, { isServer }) => {
config.plugins.push(new Webpackbar({ name: isServer ? 'server' : 'client' }))
return config
}
}