Skip to content

Instantly share code, notes, and snippets.

View erran's full-sized avatar

Erran Carey erran

View GitHub Profile
@erran
erran / _readme.md
Last active November 23, 2021 20:29
Collect all NFTs for a given owner wallet based on the specified update authority.

Clone this gist locally as a github repository and run the following commands:

# install dependencies:
yarn install

# run script with OWNER_ADDRESS set to trashy pandas burn wallet and UPDATE_AUTHORITIES set to all three Trashy Pandas collection update authorities.
env OWNER_ADDRESS=2tszvJtNLoreu8R16ERwQFWu4gywqwfLW9rpgMF7tEJj UPDATE_AUTHORITIES=BsK12QfLSAUH6UBJs7baDEy5vvfTgyHuaR4VX43YDdyZ,CjFEeNaHhdtKpWbk9LwUJtn5aMGut34q4VP4Ky5ovF51,gfEZGsSFMnwazJFeQ2gQKeQy7ip2hsR6SmEKsoxZFV3 node index.js

Keybase proof

I hereby claim:

  • I am erran on github.
  • I am erran (https://keybase.io/erran) on keybase.
  • I have a public key whose fingerprint is 693C 0364 F28F ABA7 377D FFB2 D937 CCA4 6475 9B1D

To claim this, I am signing this object:

@erran
erran / tf-configure-credentials
Last active May 21, 2021 23:20
Script(s) to create Terraform Cloud login profiles.
#!/usr/bin/env bash
set -e
USAGE="usage: $(basename $0) [organization]"
organization="$1"
if [ -z "$organization" ]; then
echo $USAGE 2>&1
exit 1
fi
@erran
erran / twitter-question.py
Last active September 26, 2019 16:23
Twitter question about syntax error
def main():
input('Please enter all information in the order listed. Press ENTER to continue.')
emp1 = str(input('Employee 1: Employee Name, SSN, Phone Number, Email, Salary '))
emp2 = str(input('Employee 2: Employee Name, SSN, Phone Number, Email, Salary '))
emp3 = str(input('Employee 3: Employee Name, SSN, Phone Number, Email, Salary '))
emp4 = str(input('Employee 4: Employee Name, SSN, Phone Number, Email, Salary '))
emp5 = str(input('Employee 5: Employee Name, SSN, Phone Number, Email, Salary '))
@erran
erran / replace-terraform-docs.rb
Last active March 20, 2018 13:10
Replace a HTML tag (<terraform-docs>) with markdown documentation via terraform-docs.
#!/usr/bin/env ruby
require 'optparse'
options = { output: STDOUT }
OptionParser.new do |opts|
opts.banner = 'Usage: replace.rb <source-file.md> [options]'
opts.on("-o", "--output=OUTPUT", "The file path to output results from (default: STDOUT)") do |v|
options[:output] = File.open(options[:output], 'w')
end
2018/03/02 17:47:09 [INFO] Terraform version: 0.11.3 3802b14260603f90c7a1faf55994dcc8933e2069
2018/03/02 17:47:09 [INFO] Go runtime version: go1.9.1
2018/03/02 17:47:09 [INFO] CLI args: []string{"/Users/ecarey/rapid7/rad/tf-rad/staging/us-east-1/.tfenv/versions/0.11.3/terraform", "plan", "-target", "module.agent_auth_service.module.agent_auth_service.aws_lambda_function.lambda", "-out", "todo.tfplan"}
2018/03/02 17:47:09 [DEBUG] Attempting to open CLI config file: /Users/ecarey/.terraformrc
2018/03/02 17:47:09 [DEBUG] File doesn't exist, but doesn't need to. Ignoring.
2018/03/02 17:47:09 [INFO] CLI command args: []string{"plan", "-target", "module.agent_auth_service.module.agent_auth_service.aws_lambda_function.lambda", "-out", "todo.tfplan"}
2018/03/02 17:47:09 [TRACE] module source: "../../common_modules/agentmanagementcachesearchapp"
2018/03/02 17:47:09 [TRACE] module source: "../../common_modules/agentmanagementcachestorageapp"
2018/03/02 17:47:09 [TRACE] module source: "../../common_modules/agentnotific
@erran
erran / keybase.md
Last active February 28, 2018 10:32

Keybase proof

I hereby claim:

  • I am erran on github.
  • I am erran (https://keybase.io/erran) on keybase.
  • I have a public key whose fingerprint is 506A 447F 27EC 9335 DB16 961A 72CF 8079 5D17 E5DB

To claim this, I am signing this object:

index 8160abe4..f2d42e3f 100644
--- a/pkg/aws/ec2/ec2.go
+++ b/pkg/aws/ec2/ec2.go
@@ -2,6 +2,7 @@ package ec2
import (
"fmt"
+ "net"
"time"
puts "testing stdout\n" * 10
# $stdout.flush # Flush stdout/stderr to force output without a terminal based wait period (i.e. the order of STDOUT vs. STDERR is not guaranteed)
# sleep 2.0 # Add some sleep time to test output with intentional wait times
warn "testing stderr\n" * 10
# $stderr.flush # Flush stdout/stderr to force output without a terminal based wait period (i.e. the order of STDOUT vs. STDERR is not guaranteed)
# sleep 2.0 # Add some sleep time to test output with intentional wait times
puts "Lorem Ipsum, awesome stuff.\n" * 10
# $stdout.flush # Flush stdout/stderr to force output without a terminal based wait period (i.e. the order of STDOUT vs. STDERR is not guaranteed)
/home/jenkins/.rvm/gems/ruby-2.2.0/gems/rex-2.0.5/lib/rex/proto/http/server.rb:83: warning: duplicated key at line 84 ignored: "jpeg"
/home/jenkins/.rvm/gems/ruby-2.2.0/gems/rex-2.0.5/lib/rex/proto/smb/exceptions.rb:11: warning: duplicated key at line 12 ignored: 0
/home/jenkins/.rvm/gems/ruby-2.2.0/gems/rex-2.0.5/lib/rex/proto/smb/exceptions.rb:17: warning: duplicated key at line 18 ignored: 128