Skip to content

Instantly share code, notes, and snippets.

@ZeroEcks
ZeroEcks / text-from-screenshot.sh
Last active February 24, 2022 13:59
I sometimes get sent screenshots of text and I don't like typing it out. Here's a script that attempts to read it and put it on your clipboard. Requires `brew install tesseract`
#!/usr/bin/env bash
set -eou pipefail
# Create a temporary file and delete when we are done
TEMP_LOCATION=$(mktemp)
trap 'rm $TEMP_LOCATION' EXIT
# Use scrot on linux instead of macos screencapture
screencapture -ds "$TEMP_LOCATION"
tesseract "$TEMP_LOCATION" - | pbcopy # you can use xclip for this too
#cloud-config
ssh_authorized_keys:
- ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABgQCnek+3GQu/J+J6p2hBfFY8anX/oqEPR1l15mnh5kgfjW5z+uwWD6S0p4ygUHdBnClJPk89IOlRabMDdu6xBtgxyBuXwqk/sSO98iLsfHY1tAbL5jYQISKfVrLoHmsWERBfZlvnjofl7iKzfhXBX5QIpmlLgs9dSiJ3+SQiOq19xPA2tgdFusnqWrIUXGIc/c2h4Ix0XUsoZCFBVQZB9Xew1uilQGmcUBN/jjE3tiuoD8S3COMzCZXdpm67n+o4LQ3dxgadMELwYIQn1mTA0K14DRqnlDDRg+cVMVLvGto1iYjaJbuhdMcnNY5vroSSWoilokV7peuWt+zd3uRvmUOfIcwjGXUVaVENlFEUlDf4p5DyLLPoEmiRlDCGQGmCBD6bWNHSjg3wy7Wo0QPsRd9t6pqQ4GbDFywYUa4xLy/910jIRRgrfmB1BBmJD6ZODbEoY5KiLVR/MltOGwKo+frYDRtB+xUM4TsdmG1kTP9qGXs4WFWscczrttd23yaaiC8= melody@earth-2020-03-04
### Keybase proof
I hereby claim:
* I am knighthawk3 on github.
* I am knighthawk3 (https://keybase.io/knighthawk3) on keybase.
* I have a public key ASCWcSvGhzrOQYrAK1U1JbKDlMON03vB2aBrT5mbZCb4Rwo
To claim this, I am signing this object:
@ZeroEcks
ZeroEcks / university
Created July 28, 2016 09:31
University wifi
Description='University Wifi'
Interface=wlp2s0
Connection=wireless
Security=wpa-configsection
IP=dhcp
TimeoutWPA=60
TimeoutDHCP=60
ESSID=ssid
763519b5c8d1c478f44296c2b6c82dcb772dc4b0fbafa66b68d889cd41da4d71
6ecb90487aaf53377f8a0e536c7a4a4ba3b142bb972d838b1034858bd5e670e5
### Keybase proof
I hereby claim:
* I am KnightHawk3 on github.
* I am knighthawk3 (https://keybase.io/knighthawk3) on keybase.
* I have a public key whose fingerprint is 585C 9C1C 0FF7 4874 C88B 9523 A146 6AED 1EF3 7B9E
To claim this, I am signing this object:
Excadrill @ Focus Sash
Ability: Sand Rush
EVs: 252 Atk / 4 Def / 252 Spe
Adamant Nature
- Earthquake
- Rock Slide
- Earthquake
- Iron Head
Salamence @ Salamencite
Smeargle @ Focus Sash
Ability: Own Tempo
EVs: 96 HP / 120 Def / 40 SpD / 252 Spe
Timid Nature
- Sticky Web
- Stealth Rock
- Spore
- Memento
Exploud @ Choice Specs
@ZeroEcks
ZeroEcks / Mono Normal
Created September 17, 2014 21:34
Monotype teams.
Smeargle @ Focus Sash
Ability: Own Tempo
EVs: 96 HP / 120 Def / 40 SpD / 252 Spe
Timid Nature
- Sticky Web
- Stealth Rock
- Spore
- Counter
Exploud @ Choice Specs
Ramiel (Gengar) @ Black Sludge
Ability: Levitate
EVs: 4 Def / 252 SpA / 252 Spe
Timid Nature
- Shadow Ball
- Substitute
- Will-O-Wisp
- Taunt
Shamshel (Latias) @ Life Orb