This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// | |
// CORS Anywhere -- Cloudflare Workers edition! | |
// | |
// try: https://cors-anywhere.0xhorizon.workers.dev/https://discordapp.com/api/guilds/444586810765475860/widget.json | |
// | |
addEventListener('fetch', event => { | |
event.respondWith(handleRequest(event, event.request)) | |
}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ stdenv, lib, fetchurl, dpkg, atk, glib, pango, gdk-pixbuf, gnome3, gtk3, cairo | |
, freetype, fontconfig, dbus, libXi, libXcursor, libXdamage, libXrandr | |
, libXcomposite, libXext, libXfixes, libXrender, libX11, libXtst, libXScrnSaver | |
, libxcb, nss, nspr, alsaLib, cups, expat, udev, libpulseaudio | |
, libuuid, at-spi2-atk, at-spi2-core, nodejs-13_x }: | |
let | |
libPath = stdenv.lib.makeLibraryPath [ | |
stdenv.cc.cc gtk3 gnome3.dconf atk glib pango gdk-pixbuf cairo freetype fontconfig dbus | |
libXi libXcursor libXdamage libXrandr libXcomposite libXext libXfixes libxcb |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ pkgs, lib, ...}: | |
with lib; | |
let machine = import ~/.dotfiles/machine.nix; | |
in | |
{ | |
enable = true; | |
hooks.postswitch = { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
prometheus setup | |
================ | |
1. sudo docker network create prom | |
2. mkdir -p /data/prometheus | |
3. create the prometheus.yml file.. | |
3. sudo docker run -d --name prometheus --network prom -p 9090:9090 -v /data/prometheus:/prometheus-data/ prom/prometheus --config.file=/prometheus-data/prometheus.yml |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"keyboard": "kbdfans/kbd75/rev1", | |
"keymap": "pkkb", | |
"layout": "LAYOUT_ansi", | |
"layers": [ | |
[ | |
"KC_ESC", | |
"KC__MUTE", | |
"KC__VOLDOWN", | |
"KC__VOLUP", |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
with import <nixpkgs> {}; | |
stdenv.mkDerivation { | |
name = "ngrok"; | |
src = fetchzip { | |
url = https://bin.equinox.io/c/4VmDzA7iaHb/ngrok-stable-linux-amd64.zip; | |
sha256 = "16gd92gqpb2fhgk2r2yzm7ralgcqy0gymh888k6h6n32j6pglzwi"; | |
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
## | |
## HTTP Router benchmarks -- Nov 29, 2020 with Go 1.15.5 on Linux AMD 3950x | |
## | |
## This benchmark suite is based on https://github.com/julienschmidt/go-http-routing-benchmark | |
## using the most up-to-date version of each pkg as of today. Each router has their own | |
## pros and cons, so consider the designs of each router to suit your application. | |
## | |
## *NOTE*: the memory reports below by the go benchmark tool look quite wrong, as there must | |
## be a bug somewhere in the go bench tool with the Go version I'm running. I will re-run | |
## with future versions and report back. However, in general you'll want to look at the "ns/op" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const path = require('path') | |
const fs = require('fs') | |
const contractBuildDir = path.join(path.dirname(require.main.filename), '../build/contracts') | |
const abiDir = path.join(path.dirname(require.main.filename), '../abi') | |
fs.readdir(contractBuildDir, (err, files) => { | |
if (err) { | |
console.error('whoops', err) | |
process.exit() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
theme = "solarized-dark" | |
[icons] | |
name = "awesome" | |
[icons.overrides] | |
#backlight_empty = " \\u{1f311} " | |
#backlight_partial1 = " \\u{1f312} " | |
#backlight_partial2 = " \\u{1f313} " | |
#backlight_partial3 = " \\u{1f314} " |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
'use strict'; | |
import { Provider } from './provider'; | |
import { EtherscanProvider } from './etherscan-provider'; | |
import { FallbackProvider } from './fallback-provider'; | |
import { IpcProvider } from './ipc-provider'; | |
import { InfuraProvider } from './infura-provider'; | |
import { JsonRpcProvider, JsonRpcSigner } from './json-rpc-provider'; | |
import { Web3Provider } from './web3-provider'; |
NewerOlder