Skip to content

Instantly share code, notes, and snippets.

View neyer's full-sized avatar

Mark P Neyer neyer

View GitHub Profile
{"meta":{"username":"apxhard"},"content":{"sites":[{"title":"Living A Good Life Means Being a Good Investor – APXHARD","url":"https://apxhard.com/2021/11/05/living-a-good-life-means-being-a-good-investor/","timestamp_ms":1647305953973},{"title":"Controlling Your Dopamine For Motivation, Focus & Satisfaction | Huberman Lab Podcast #39 - YouTube","url":"https://www.youtube.com/watch?v=QmOF0crdyRU","timestamp_ms":1647306023391},{"title":"Your Mind is an Excellent Servant, but a Terrible Master - David Foster Wallace - YouTube","url":"https://www.youtube.com/watch?v=OsAd4HGJS4o&t=750s","timestamp_ms":1647307289994},{"title":"Marcus Aurelius on What His Father Taught Him About Humility, Honor, Kindness, and Integrity – The Marginalian","url":"https://www.themarginalian.org/2014/10/07/marcus-aurelius-meditations-father/","timestamp_ms":1647391189540}],"peers":[]}}
{"meta":{},"content":{"sites":[{"title":"javascript - Get website's favicon with JS - Stack Overflow","url":"https://stackoverflow.com/questions/2057636/get-websites-favicon-with-js","timestamp_ms":1646504705389},{"title":"Chrome extensions: Local storage - DEV Community","url":"https://dev.to/paulasantamaria/chrome-extensions-local-storage-1b34","timestamp_ms":1646504706970},{"title":"javascript localStorage in extension at DuckDuckGo","url":"https://duckduckgo.com/?q=javascript+localStorage+in+extension&t=brave&ia=web","timestamp_ms":1646504708178},{"title":"Migrating from background pages to service workers - Chrome Developers","url":"https://developer.chrome.com/docs/extensions/mv3/migrating_to_service_workers/","timestamp_ms":1646504709302},{"title":"Samples - Chrome Developers","url":"https://developer.chrome.com/docs/extensions/mv3/samples/","timestamp_ms":1646504712334},{"title":"javascript - Get website's favicon with JS - Stack Overflow","url":"https://stackoverflow.com/questions/2057636/get-website
{"meta":{},"content":{"sites":[{"title":"javascript - Get website's favicon with JS - Stack Overflow","url":"https://stackoverflow.com/questions/2057636/get-websites-favicon-with-js","timestamp_ms":1646504705389},{"title":"Chrome extensions: Local storage - DEV Community","url":"https://dev.to/paulasantamaria/chrome-extensions-local-storage-1b34","timestamp_ms":1646504706970},{"title":"javascript localStorage in extension at DuckDuckGo","url":"https://duckduckgo.com/?q=javascript+localStorage+in+extension&t=brave&ia=web","timestamp_ms":1646504708178},{"title":"Migrating from background pages to service workers - Chrome Developers","url":"https://developer.chrome.com/docs/extensions/mv3/migrating_to_service_workers/","timestamp_ms":1646504709302},{"title":"Samples - Chrome Developers","url":"https://developer.chrome.com/docs/extensions/mv3/samples/","timestamp_ms":1646504712334},{"title":"javascript - Get website's favicon with JS - Stack Overflow","url":"https://stackoverflow.com/questions/2057636/get-website
{"meta":{},"content":{"sites":[{"title":"javascript - Get website's favicon with JS - Stack Overflow","url":"https://stackoverflow.com/questions/2057636/get-websites-favicon-with-js","timestamp_ms":1646504705389},{"title":"Chrome extensions: Local storage - DEV Community","url":"https://dev.to/paulasantamaria/chrome-extensions-local-storage-1b34","timestamp_ms":1646504706970},{"title":"javascript localStorage in extension at DuckDuckGo","url":"https://duckduckgo.com/?q=javascript+localStorage+in+extension&t=brave&ia=web","timestamp_ms":1646504708178},{"title":"Migrating from background pages to service workers - Chrome Developers","url":"https://developer.chrome.com/docs/extensions/mv3/migrating_to_service_workers/","timestamp_ms":1646504709302},{"title":"Samples - Chrome Developers","url":"https://developer.chrome.com/docs/extensions/mv3/samples/","timestamp_ms":1646504712334},{"title":"javascript - Get website's favicon with JS - Stack Overflow","url":"https://stackoverflow.com/questions/2057636/get-website
{"meta":{},"content":{"sites":[{"title":"javascript - Get website's favicon with JS - Stack Overflow","url":"https://stackoverflow.com/questions/2057636/get-websites-favicon-with-js","timestamp_ms":1646504705389},{"title":"Chrome extensions: Local storage - DEV Community","url":"https://dev.to/paulasantamaria/chrome-extensions-local-storage-1b34","timestamp_ms":1646504706970},{"title":"javascript localStorage in extension at DuckDuckGo","url":"https://duckduckgo.com/?q=javascript+localStorage+in+extension&t=brave&ia=web","timestamp_ms":1646504708178},{"title":"Migrating from background pages to service workers - Chrome Developers","url":"https://developer.chrome.com/docs/extensions/mv3/migrating_to_service_workers/","timestamp_ms":1646504709302},{"title":"Samples - Chrome Developers","url":"https://developer.chrome.com/docs/extensions/mv3/samples/","timestamp_ms":1646504712334},{"title":"javascript - Get website's favicon with JS - Stack Overflow","url":"https://stackoverflow.com/questions/2057636/get-website
{"meta":{},"content":{"sites":[{"title":"javascript - Get website's favicon with JS - Stack Overflow","url":"https://stackoverflow.com/questions/2057636/get-websites-favicon-with-js","timestamp_ms":1646504705389},{"title":"Chrome extensions: Local storage - DEV Community","url":"https://dev.to/paulasantamaria/chrome-extensions-local-storage-1b34","timestamp_ms":1646504706970},{"title":"javascript localStorage in extension at DuckDuckGo","url":"https://duckduckgo.com/?q=javascript+localStorage+in+extension&t=brave&ia=web","timestamp_ms":1646504708178},{"title":"Migrating from background pages to service workers - Chrome Developers","url":"https://developer.chrome.com/docs/extensions/mv3/migrating_to_service_workers/","timestamp_ms":1646504709302},{"title":"Samples - Chrome Developers","url":"https://developer.chrome.com/docs/extensions/mv3/samples/","timestamp_ms":1646504712334},{"title":"javascript - Get website's favicon with JS - Stack Overflow","url":"https://stackoverflow.com/questions/2057636/get-website
{"meta":{},"content":{"sites":[{"title":"javascript - Get website's favicon with JS - Stack Overflow","url":"https://stackoverflow.com/questions/2057636/get-websites-favicon-with-js","timestamp_ms":1646504705389},{"title":"Chrome extensions: Local storage - DEV Community","url":"https://dev.to/paulasantamaria/chrome-extensions-local-storage-1b34","timestamp_ms":1646504706970},{"title":"javascript localStorage in extension at DuckDuckGo","url":"https://duckduckgo.com/?q=javascript+localStorage+in+extension&t=brave&ia=web","timestamp_ms":1646504708178},{"title":"Migrating from background pages to service workers - Chrome Developers","url":"https://developer.chrome.com/docs/extensions/mv3/migrating_to_service_workers/","timestamp_ms":1646504709302},{"title":"Samples - Chrome Developers","url":"https://developer.chrome.com/docs/extensions/mv3/samples/","timestamp_ms":1646504712334},{"title":"javascript - Get website's favicon with JS - Stack Overflow","url":"https://stackoverflow.com/questions/2057636/get-website
{"meta":{},"content":{"sites":[{"title":"javascript - Get website's favicon with JS - Stack Overflow","url":"https://stackoverflow.com/questions/2057636/get-websites-favicon-with-js","timestamp_ms":1646504705389},{"title":"Chrome extensions: Local storage - DEV Community","url":"https://dev.to/paulasantamaria/chrome-extensions-local-storage-1b34","timestamp_ms":1646504706970},{"title":"javascript localStorage in extension at DuckDuckGo","url":"https://duckduckgo.com/?q=javascript+localStorage+in+extension&t=brave&ia=web","timestamp_ms":1646504708178},{"title":"Migrating from background pages to service workers - Chrome Developers","url":"https://developer.chrome.com/docs/extensions/mv3/migrating_to_service_workers/","timestamp_ms":1646504709302},{"title":"Samples - Chrome Developers","url":"https://developer.chrome.com/docs/extensions/mv3/samples/","timestamp_ms":1646504712334},{"title":"javascript - Get website's favicon with JS - Stack Overflow","url":"https://stackoverflow.com/questions/2057636/get-website
# from a post
"message_tags": {
"9": [
{
"id": "849191185199284",
"name": "Mark Chandler",
"type": "user",
"offset": 9,
"length": 13
@neyer
neyer / rearranging images
Last active August 29, 2015 14:06
rearranging images
from PIL import Image
i = Image.open('static/images/dudes/sheep-2.png')
new_image = Image.new(i.mode, (256,256))
size_per_image = 128
real_image_size = 64
# for changing old sheep with spacing to new sheep
def map_portion(x_num, y_num):
start_x = x_num*size_per_image + 32