This file contains hidden or 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
| // ==UserScript== | |
| // @name Add Quick Calculations to Uniswap | |
| // @namespace http://tampermonkey.net/ | |
| // @version 0.6.0 | |
| // @description Add quick links on uniswap, similar to trading interfaces | |
| // @author Korkey128k | |
| // @match https://app.uniswap.org/ | |
| // @match https://uniswap.hedron.pro/* | |
| // @match https://*.pulsex.com/* | |
| // @icon https://www.google.com/s2/favicons?domain=uniswap.org |
This file contains hidden or 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
| This module contains operations for working with radix trees. A radix tree | |
| is a data structure for efficient storage and lookup of values that often | |
| share prefixes, typically used with strings. | |
| A common question when I show this to people is: how do I add to the tree? | |
| delete? update? For these, grab the Range of the tree, use set logic to | |
| add/remove any elements, and construct a new tree with RadixTree. | |
| For educational purposes, I've heavily commented all the operations. I | |
| recommend using the constant expression evaluator to try the building blocks |
This file contains hidden or 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
| #!/bin/bash | |
| python3 --version || { echo "ERROR: Missing python3"; exit 1; } | |
| tmp=$(python3 -c "import os, sys; print(os.path.realpath('/tmp'))") | |
| function test { | |
| MESSAGE=$1 | |
| RECEIVED=$2 | |
| EXPECTED=$3 |
This file contains hidden or 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
| // This worker is designed to be able to neatly handle MTA-STS policies for multiple domains. | |
| // Make a new worker with this script and add your domains to the stsPolicies dict like the example. | |
| // Add a DNS AAAA record for mta-sts.yourdomain.com pointing to 100:: and set to proxied, | |
| // then add a workers route for mta-sts.yourdomain.com/* pointing to this worker. | |
| // You should probably also create a Cloudflare configuration rule disabling Browser Integrity Check for the mta-sts subdomain | |
| // to ensure MTAs aren't blocked from retrieving your policy. | |
| // You'll still need to manually add the appropriate _mta-sts.yourdomain.com TXT record to enable the policy, |
This file contains hidden or 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
| // @ts-check | |
| "use strict" | |
| /** | |
| * Set up datadog tracing. This should be called first, so Datadog can hook | |
| * all the other dependencies like `http`. | |
| */ | |
| function setUpDatadogTracing() { | |
| const { tracer: Tracer } = require('dd-trace') | |
| const tracer = Tracer.init({ |
Note: PBSS in Geth >=1.13.0 removes the need to prune manually.
Geth (Go-Ethereum) as of July 2022 takes about 650 GiB of space on a fast/snap sync, and then grows by ~ 14 GiB/week with default cache, ~ 8 GiB/week with more cache.
This file contains hidden or 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
| /**! | |
| * Fast CRC32 in JavaScript | |
| * 101arrowz (https://github.com/101arrowz) | |
| * License: MIT | |
| */ | |
| // If you use this code, please link this gist or attribute it somehow. | |
| // This code uses the Slice-by-16 algorithm to achieve performance | |
| // roughly 2x greater than all other JS CRC32 implementations (e.g. |
The package that linked you here is now pure ESM. It cannot be require()'d from CommonJS.
This means you have the following choices:
- Use ESM yourself. (preferred)
Useimport foo from 'foo'instead ofconst foo = require('foo')to import the package. You also need to put"type": "module"in your package.json and more. Follow the below guide. - If the package is used in an async context, you could use
await import(…)from CommonJS instead ofrequire(…). - Stay on the existing version of the package until you can move to ESM.
source: actions/runner-images#599
Use NPM_CONFIG_PREFIX - docs.npmjs.com/resolving-eacces-permissions-errors-when-installing-packages-globally
export NPM_CONFIG_PREFIX=~/.npm-global
npm install -g lerna