Skip to content

Instantly share code, notes, and snippets.

@kajeagentspi
kajeagentspi / go-install.sh
Last active August 20, 2022 19:36 — forked from ssandeep/go-install.sh
Go Installer
#!/bin/bash
set -e
VERSION="1.19rc2"
[ -z "$GOROOT" ] && GOROOT="$HOME/.go"
[ -z "$GOPATH" ] && GOPATH="$HOME/go"
OS="$(uname -s)"
ARCH="$(uname -m)"
@kajeagentspi
kajeagentspi / Multicall.sol
Created May 14, 2022 01:20 — forked from 0xAlcibiades/Multicall.sol
A Pre EIP-1559 MEV/Multicall in pure Yul integrated with ApeBank and with Native GasTokens
// SPDX-License-Identifier: MIT
object "Multicall" {
code {
// Deploy the contract
// Store gas token burn cost in zero slot
sstore(0, 0)
sstore(1, 0)
sstore(2, 0)
datacopy(0x0, dataoffset("MulticallRuntime"), datasize("MulticallRuntime"))
@kajeagentspi
kajeagentspi / getvpnport.sh
Created December 7, 2020 08:41
PIA Token patch
#!/bin/bash
# check endpoint is port forward enabled (pia only)
function port_forward_status() {
echo "[info] Port forwarding is enabled"
echo "[info] Checking endpoint '${VPN_REMOTE_SERVER}' is port forward enabled..."
# run curl to grab api result
REM 自動的に解凍
REM -ibck launch winrar in background mode
REM -o+ overwrite files
FOR %%i IN (*.zip) DO "%ProgramFiles%\WinRAR\winrar.exe" x -ibck -o+ %%i *.* %%~ni/
FOR %%i IN (*.rar) DO "%ProgramFiles%\WinRAR\winrar.exe" x -ibck -o+ %%i *.* %%~ni/
@kajeagentspi
kajeagentspi / cloudSettings
Created July 25, 2018 11:20
Visual Studio Code Settings Sync Gist
{"lastUpload":"2018-07-25T11:20:40.081Z","extensionVersion":"v3.0.0"}
@kajeagentspi
kajeagentspi / hash.c
Created April 11, 2017 08:49 — forked from tonious/hash.c
A quick hashtable implementation in c.
#define _XOPEN_SOURCE 500 /* Enable certain library functions (strdup) on linux. See feature_test_macros(7) */
#include <stdlib.h>
#include <stdio.h>
#include <limits.h>
#include <string.h>
struct entry_s {
char *key;
char *value;