This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python3 | |
# bf_format - format brainfuck code listings using nested indentation | |
# originally from https://pastebin.com/raw/FN1YMQ6r | |
# updated 2019-05-26-09:23 comment out the lf insertion for ']' | |
# I think it looks better this way, also results in shorter listing | |
# updated 2022-06-11 convert to use argv, add '-i' arg | |
# and indent every [ and ] | |
from io import StringIO | |
from pathlib import Path | |
from sys import argv, stdout |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
+++++++++++++ | |
[->++>>>+++++>++>+<<<<<<]>>>>>++++++>--->>>>>>>>>>+++++++++++++++ | |
[ | |
[>>>>>>>>>]+ | |
[<<<<<<<<<]>>>>>>>>>-]+ | |
[>>>>>>>> | |
[-]>]<<<<<<<<< | |
[<<<<<<<<<]>>>>>>>> | |
[-]+<<<<<<<+++++ | |
[- |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python3 | |
# bf_format - format brainfuck code listings using nested indentation | |
# originally from https://pastebin.com/raw/FN1YMQ6r | |
# updated 2019-05-26-09:23 comment out the lf insertion for ']' | |
# I think it looks better this way, also results in shorter listing | |
# updated 2022-06-11 convert to use argv, add '-i' arg | |
from io import StringIO | |
from pathlib import Path | |
from sys import argv, stdout |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from dotenv import load_dotenv | |
from email import message_from_bytes | |
from imaplib import IMAP4_SSL | |
from itertools import islice | |
from os import getenv | |
from pathlib import Path | |
load_dotenv() | |
username = getenv("GMAIL_USERNAME") | |
password = getenv("GMAIL_APP_PASS") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Script to send email with optional | |
# attachments using gmail | |
# | |
import re | |
import smtplib | |
from pathlib import Path | |
from email.mime.multipart import MIMEMultipart | |
from email.mime.base import MIMEBase | |
from email.mime.text import MIMEText | |
from email.utils import COMMASPACE, formatdate |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import re | |
import bs4 | |
import sys | |
import time | |
import random | |
import requests | |
import urllib.parse | |
import urllib.request | |
from urllib.error import HTTPError as UrllibHTTPError | |
from requests.exceptions import HTTPError |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python3 | |
from datetime import datetime | |
from sys import argv | |
from bs4 import BeautifulSoup, GuessedAtParserWarning, Tag | |
from warnings import simplefilter | |
from urllib.request import Request, urlopen | |
from urllib.parse import quote_plus, urljoin | |
simplefilter(category=GuessedAtParserWarning,action="ignore") | |
query = " ".join(argv[1:]) if argv[1:] else "gif" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<h1>Thank you for using this library! Here are the basic ways to use it:</h1> | |
<h2>To import, do:</h2> | |
<blockquote> | |
<p>from G_Sketch import *</p> | |
</blockquote> | |
<h2>To create an object do:</h2> | |
<blockquote> | |
<p>my_sketch = Sketch("path/to/file.png")</p> | |
</blockquote> | |
<p>There are 3 functions for a sketch:</p> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python3 | |
# Modified 2021-12-19 by @greyblue92 | |
# - Convert from python 2 to python 3 | |
# - Add API call to convert json to C# | |
# - Fix a bunch of problems with the python output | |
# - Type renaming and generics | |
# Original code from https://github.com/shannoncruey/csharp-to-python | |
######################################################################## | |
# Apache License, Version 2.0 (the "License"); | |
# the License. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# EDITOR=vi | |
export EDITOR='vim' | |
export CLICOLOR=1; | |
export LSCOLORS=exfxcxdxbxegedabagacad; | |
PATH=.:~/bin:/usr/local/mysql/bin:/usr/local/bin:~/local/node/bin:$PATH | |
alias ll="ls -golAF" | |
alias lll="ls -lAF" |
NewerOlder