Skip to content

Instantly share code, notes, and snippets.

View public-space's full-sized avatar
🎯
Focusing

Donovan Martinez public-space

🎯
Focusing
View GitHub Profile
@calmez
calmez / person.py
Created August 27, 2012 20:58
Programming Python (Mark Lutz / 4th Edition / O'Reilly) – Examples
#!/usr/local/bin/python3
"""
Implementation of persons for a pim database
"""
import shelve
import tkinter
import tkinter.messagebox
@dcloud
dcloud / elec_shopping_ch1.markdown
Last active August 14, 2023 14:29
Make Electronics Shopping List

Chapter 1 Parts List

Tools

###Small pliers

RadioShack 4.5-inch mini long-nose pliers, part number 64-0062, or Xcelite 4-inch mini long-nose pliers, model L4G. Or similar. The brand is unimportant. After you use them for a while, you'll develop your own preferences. In particular, you have to decide whether you like spring-loaded handles. If you decide you don't, you'll need a second pair of pliers to pull the springs out of the first.

I have small pliers, probably okay.

@augbog
augbog / Free O'Reilly Books.md
Last active July 23, 2024 15:24
Free O'Reilly Books

Free O'Reilly books and convenient script to just download them.

Thanks /u/FallenAege/ and /u/ShPavel/ from this Reddit post

How to use:

  1. Take the download.sh file and put it into a directory where you want the files to be saved.
  2. cd into the directory and make sure that it has executable permissions (chmod +x download.sh should do it)
  3. Run ./download.sh and wee there it goes. Also if you do not want all the files, just simply comment the ones you do not want.
@wojteklu
wojteklu / clean_code.md
Last active July 25, 2024 11:12
Summary of 'Clean code' by Robert C. Martin

Code is clean if it can be understood easily – by everyone on the team. Clean code can be read and enhanced by a developer other than its original author. With understandability comes readability, changeability, extensibility and maintainability.


General rules

  1. Follow standard conventions.
  2. Keep it simple stupid. Simpler is always better. Reduce complexity as much as possible.
  3. Boy scout rule. Leave the campground cleaner than you found it.
  4. Always find root cause. Always look for the root cause of a problem.

Design rules

@diewland
diewland / wav2flac.py
Last active February 5, 2023 10:37
convert wav to flac from python
from os.path import splitext
from pydub import AudioSegment
def wav2flac(wav_path):
flac_path = "%s.flac" % splitext(wav_path)[0]
song = AudioSegment.from_wav(wav_path)
song.export(flac_path, format = "flac")
if __name__ == "__main__":
import sys
@mouseroot
mouseroot / psychwiki.py
Created February 25, 2020 00:30
Psychonaut Wiki API
# This is the API we need to POST too..
# https://api.psychonautwiki.org/
#
import requests
import json
#We ask for input, displaying "Which Psych?"
query = input("Which Psych?")