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
| const { Token, WETH9, CurrencyAmount, TradeType } = require('@uniswap/sdk-core') | |
| const { Route, Trade, Pair } = require('@uniswap/v2-sdk') | |
| const ethers = require('ethers') | |
| ;(async () => { | |
| const CHAIN_ID = 1 | |
| const daiAddress = '0x6B175474E89094C44Da98b954EedeAC495271d0F' | |
| const tokenA = WETH9[CHAIN_ID] | |
| const tokenB = new Token(CHAIN_ID, daiAddress, 18, 'DAI', 'DAI') | |
| const pairAddress = Pair.getAddress(tokenA, tokenB) |
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
| Object.class_eval do | |
| def private_inspect | |
| memo = {} | |
| self.instance_variables.inject(memo) do |memo, var| | |
| memo[var] = self.instance_variable_get(var).to_s | |
| memo | |
| end | |
| except = [:__, :_, :_ex_, :_pry_, :_out_, :_in_, :_dir_, :_file_] |
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
| #!/usr/bin/env bash | |
| # Description: Pull a complete hardware list from Samanage and generate a list of MAC addresses | |
| # syntax: ./samanage_GET_MAC.sh | |
| # | |
| # Author: AJ Acevedo | |
| # License: MIT License | |
| # Version 0.5 | |
| # API TOKEN | |
| TOKEN="INSERT YOUR API TOKEN HERE" |
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 | |
| # Source: http://blog.nonuby.com/blog/2012/07/05/copying-env-vars-from-one-heroku-app-to-another/ | |
| set -e | |
| sourceApp="$1" | |
| targetApp="$2" | |
| while read key value; do |