Skip to content

Instantly share code, notes, and snippets.

View fuzzysteve's full-sized avatar
💭
Building shit

Steve Anderson / Steve Ronuken fuzzysteve

💭
Building shit
View GitHub Profile
@fuzzysteve
fuzzysteve / checkSSL.py
Created December 1, 2017 10:05
python script to check SSL certs
import socket
import ssl
from ssl import CERT_OPTIONAL
import datetime
import logging
def ssl_cert_info(hostname):
ssl_date_fmt = r'%b %d %H:%M:%S %Y %Z'
context = ssl.create_default_context()
@fuzzysteve
fuzzysteve / gist:1e70aa2b4cbdbf1b70c21932dd829550
Created August 18, 2020 21:28
add / to all zkill links. change the url
// ==UserScript==
// @name New Userscript
// @namespace http://tampermonkey.net/
// @version 0.1
// @description try to take over the world!
// @author You
// @match https://zkillboard.com/*
// @grant none
// ==/UserScript==
@fuzzysteve
fuzzysteve / gist:232f7dd4ff3c8ec7ee45ff7acf61d61b
Created June 6, 2020 16:48
power query - Query blueprints
let
Source = Json.Document(Web.Contents("https://www.fuzzwork.co.uk/blueprint/api/blueprint.php?typeid="&Text.From(Excel.CurrentWorkbook(){[Name="blueprintid"]}[Content]{0}[Column1]))),
blueprintDetails = Source,
activityMaterials = blueprintDetails[activityMaterials],
#"1" = activityMaterials[1],
#"Converted to Table" = Table.FromList(#"1", Splitter.SplitByNothing(), null, null, ExtraValues.Error),
#"Expanded Column1" = Table.ExpandRecordColumn(#"Converted to Table", "Column1", {"typeid", "name", "quantity", "maketype"}, {"Column1.typeid", "Column1.name", "Column1.quantity", "Column1.maketype"})
in
#"Expanded Column1"
@fuzzysteve
fuzzysteve / items.py
Created May 2, 2020 17:38
esi updater
import requests
from sqlalchemy import create_engine,MetaData,Table,Column,INTEGER,FLOAT,VARCHAR,UnicodeText,DECIMAL,Boolean,select,literal_column
import requests_cache
from requests_futures.sessions import FuturesSession
import requests_futures
from concurrent.futures import as_completed
from tqdm import tqdm
@fuzzysteve
fuzzysteve / fleetup-exporter.py
Last active October 17, 2019 15:51
a quick and dirty exporter
import requests
import os
import json
appkey="nope"
userid="nuhu"
apikey="nahmate"
basedir="export"
@fuzzysteve
fuzzysteve / gist:eaef4434773f8e311e417f6c37a16fa8
Last active August 11, 2019 19:37
aggregate loader - powrshell.
let
Source = Binary.Decompress(Web.Contents("https://market.fuzzwork.co.uk/aggregatecsv.csv.gz"),Compression.GZip),
#"Imported CSV" = Csv.Document(Source,[Delimiter=",", Columns=10, Encoding=1252, QuoteStyle=QuoteStyle.None]),
#"Promoted Headers" = Table.PromoteHeaders(#"Imported CSV", [PromoteAllScalars=true]),
#"Changed Type" = Table.TransformColumnTypes(#"Promoted Headers",{{"what", type text}, {"weightedaverage", type number}, {"maxval", type number}, {"minval", type number}, {"stddev", type number}, {"median", type number}, {"volume", Int64.Type}, {"numorders", Int64.Type}, {"fivepercent", type number}, {"orderSet", Int64.Type}})
in
#"Changed Type"
@fuzzysteve
fuzzysteve / editedwright.py
Last active June 25, 2019 18:01
editedwright.py
from collections import defaultdict
import sys
# --------
# - Read in the BLT file
# --------
fname = sys.argv[2]
fp = open(fname, "r")
@fuzzysteve
fuzzysteve / gist:a1582580f650c608990ec823fe154134
Created June 16, 2019 23:04
Powerquery getting market type ids from a sheet.
let
Source = Json.Document(Web.Contents("https://market.fuzzwork.co.uk/aggregates/?region=10000002&types="&Text.Combine(Table.ToList(Table.TransformColumnTypes(Table.SelectRows(Excel.CurrentWorkbook(){[Name="typelist"]}[Content], each ([Column1] <> null)),{{"Column1", type text}})),","))),
#"Converted to Table" = Record.ToTable(Source),
#"Expanded Value" = Table.ExpandRecordColumn(#"Converted to Table", "Value", {"buy", "sell"}, {"Value.buy", "Value.sell"}),
#"Expanded Value.buy" = Table.ExpandRecordColumn(#"Expanded Value", "Value.buy", {"weightedAverage", "max", "min", "stddev", "median", "volume", "orderCount", "percentile"}, {"Value.buy.weightedAverage", "Value.buy.max", "Value.buy.min", "Value.buy.stddev", "Value.buy.median", "Value.buy.volume", "Value.buy.orderCount", "Value.buy.percentile"}),
#"Expanded Value.sell" = Table.ExpandRecordColumn(#"Expanded Value.buy", "Value.sell", {"weightedAverage", "max", "min", "stddev", "median", "volume", "orderCount", "percentile"}, {"Value.sell.

Keybase proof

I hereby claim:

  • I am fuzzysteve on github.
  • I am fuzzysteve (https://keybase.io/fuzzysteve) on keybase.
  • I have a public key ASCYnNQiwS_Lg2CqNj8Du_8BocVRuHkuTVb8fU-7y-2EPQo

To claim this, I am signing this object:

@fuzzysteve
fuzzysteve / callback.php
Created November 11, 2018 12:41
basic discord
<?php
session_start();
require 'vendor/autoload.php';
use GuzzleHttp\Client;
$client = new Client();