Skip to content

Instantly share code, notes, and snippets.

View jakswa's full-sized avatar

Jake Swanson jakswa

View GitHub Profile
@jakswa
jakswa / Cargo.toml
Last active June 23, 2023 21:53
showing rustls error case
[package]
name = "rustls_conn_reset"
version = "0.1.0"
edition = "2021"
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
[dependencies]
error-chain = "*"
@jakswa
jakswa / index.js
Last active May 15, 2020 16:31
This is my weekly 15five script.
#!/usr/bin/env node
const { firefox } = require('playwright');
const util = require('util');
const setTimeoutPromise = util.promisify(setTimeout);
(async () => {
if (!process.env.FIVE15UN || !process.env.FIVE15PW) {
console.log("env vars FIVE15UN & FIVE15PW are required. exiting.");
return;
@jakswa
jakswa / playground.rs
Created August 19, 2018 00:42 — forked from rust-play/playground.rs
Code shared from the Rust Playground
// error[E0277]: the trait bound `(): actix_web::ResponseError` is not satisfied
// --> src/main.rs:25:32
// |
//25 | r.method(http::Method::GET).with_async(index)
// | ^^^^^^^^^^ the trait `actix_web::ResponseError` is not implemented for `()`
// |
// = note: required because of the requirements on the impl of `std::convert::From<()>` for `actix_web::Error`
// = note: required because of the requirements on the impl of `std::convert::Into<actix_web::Error>` for `()`
<a href="tel:678–315-4567">woo click here</a>

Install needed node packages:

npm install -g cylon-ble
npm install cylon cylon-ollie

First scan for your BB8 (the device name should contain BB in it):

> sudo cylon-ble-scan
[...]
@jakswa
jakswa / gzip.md
Last active September 24, 2015 20:04

non-gzip (35KB):

➜  callrail git:(js/phones) ✗ wget -S  http://cdn.callrail.com/companies/297407543/f6b60be971df89061219/12/swap.js
--2015-09-24 16:01:20--  http://cdn.callrail.com/companies/297407543/f6b60be971df89061219/12/swap.js
Resolving cdn.callrail.com... 94.31.29.146
Connecting to cdn.callrail.com|94.31.29.146|:80... connected.
HTTP request sent, awaiting response...
  HTTP/1.1 200 OK
  Date: Thu, 24 Sep 2015 20:01:20 GMT
### Keybase proof
I hereby claim:
* I am jakswa on github.
* I am jakswa (https://keybase.io/jakswa) on keybase.
* I have a public key whose fingerprint is 7D53 0FE7 2E7F 75CB 2D54 0197 1992 D824 1500 6FF6
To claim this, I am signing this object:
@jakswa
jakswa / 0-readme.md
Last active December 17, 2015 19:29 — forked from samgranieri/0-readme.md

ruby-1.9.3-p385 cumulative performance patch for rbenv

This installs a patched ruby 1.9.3-p385 with various performance improvements and a backported COW-friendly GC, all courtesy of funny-falcon.

Requirements

You will also need a C Compiler. If you're on Linux, you probably already have one or know how to install one. On OS X, you should install XCode, and brew install autoconf using homebrew.