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
"""Find import and import from statements | |
""" | |
import ast | |
from pathlib import Path | |
class ImportRecord: | |
@classmethod | |
def toplevel_imports(cls, root: Path, prune: list[str] = None) -> list[str]: |
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
""" short module description goes here. | |
Longer module description goes here. | |
""" | |
from typing import List, Union | |
__author__ = "[email protected]" |
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 | |
""" a quick and dirty books query thing | |
""" | |
from pprint import pprint | |
import requests |
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 string import digits | |
from typing import List, Tuple | |
def make_number_lists(base: str = None) -> Tuple[List[str], List[str]]: | |
base = base or digits[1:] |
This file has been truncated, but you can view the full file.
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
{"caused_by":"macos","macos_version":"Mac OS X 11.3.1 (20E241)","os_version":"Bridge OS 5.3 (18P4556)","macos_system_state":"running","incident_id":"5D23D70E-B825-42B6-AA03-135B7361F5C4","timestamp":"2021-05-19 16:30:12.00 +0000","bug_type":"210"} | |
{ | |
"binaryImages" : [ | |
[ | |
"3fa744a7-0f34-36da-aa6d-f6503a3176ed", | |
18446744005107531776, | |
"K" | |
], | |
[ | |
"00000000-0000-0000-0000-000000000000", |
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 hid | |
d = hid.device() | |
d.open(0x2c0d, 1) |
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
# Makefile - Generate HTML, PDF, EPUB, MOBI from ASC | |
# This is how you assign a string to a variable name in 'make'. The | |
# variable name doesn't have to be all caps and the equal doesn't have | |
# to be snugged up to the variable name; it's just how I write | |
# Makefiles | |
FILENAME= the_document | |
# $(IDENTIFIER) is how you reference a 'make' variable, you can use |
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 | |
""" short module description | |
Longer module description goes here. | |
""" | |
from collections import defaultdict | |
from dateutil.parser import parse |
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 dateutil.parser import parse | |
import re | |
import datetime | |
def get_min_max_amount_of_commits( | |
commit_log: str = commits, year: int = None | |
) -> (str, str): | |
""" | |
Calculate the amount of inserts / deletes per month from the |
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 | |
import click | |
import numpy as np | |
import matplotlib.pyplot as plt | |
import pandas as pd | |
# Requirements: | |
# python3 -m pip install -U click pandas matplotlib numpy xlwt |
NewerOlder