Skip to content

Instantly share code, notes, and snippets.

View samb1729's full-sized avatar

Sam Broughton samb1729

  • London, United Kingdom
View GitHub Profile
@samb1729
samb1729 / keybase.md
Last active January 17, 2021 01:06
Keybase proof

Keybase proof

I hereby claim:

  • I am samb1729 on github.
  • I am samb1729 (https://keybase.io/samb1729) on keybase.
  • I have a public key ASDvqVZR3pouSG_Aioj-MSuqPuq0c2-pBH5Y_J6uF9TlpQo

To claim this, I am signing this object:

package main
import (
"bytes"
"flag"
"io"
"log"
"sync"
"time"
import pyperclip
from flask import Flask
app = Flask(__name__)
@app.route("/copy/<text>")
def copy_to_clipboard(text):
pyperclip.copy(text)
print(text)
public long GetSteamId()
{
var manager = new UserManager();
var accounts = manager.GetLogins(User.Identity.GetUserId());
var providerkeys = accounts.Where(a => a.LoginProvider == "Steam").Select(a => a.ProviderKey).ToList();
if (!providerkeys.Any()) return 0;
var key = providerkeys.First();
if (key.StartsWith("http://steamcommunity.com/openid/id/"))
@samb1729
samb1729 / s3.rb
Last active August 29, 2015 14:02
require "aws-sdk"
require "clipboard"
AWS.config access_key_id: "UseYourOwn", secret_access_key: "SeriouslyYouCantHaveMyKeys"
s3 = AWS::S3.new
bucket_name = "i.samby.co.uk"
bucket = s3.buckets[bucket_name]
latest_screenshot = Dir["#{ENV["HOME"]}/Dropbox/Screenshots/*"].last