Skip to content

Instantly share code, notes, and snippets.

View jdimpson's full-sized avatar

Jeremy Impson jdimpson

View GitHub Profile
@hack0x90
hack0x90 / soundcloud_mp3_download_ffmpeg
Last active February 11, 2024 17:33
Using ffmpeg to download mp3 files from SoundCloud
ffmpeg -i \
https://cf-hls-media.sndcdn.com/playlist/uWlzccjYfaS3.128.mp3/playlist.m3u8?Policy=eyJTdGF0ZW1lbnQiOlt7IlJlc291cmNlIjoiKjovL2NmLWhscy1tZWRpYS5zbmRjZG4uY29tL3BsYXlsaXN0L3VXbHpjY2pZZmFTMy4xMjgubXAzL3BsYXlsaXN0Lm0zdTgqIiwiQ29uZGl0aW9uIjp7IkRhdGVMZXNzVGhhbiI6eyJBV1M6RXBvY2hUaW1lIjoxNjUyMDM1NDUzfX19XX0_&Signature=ZLM9vBNwkWm8Di~dPqTlYRK-8rVCL0xFwDThRf9Lm6NWfCEi1C4xQKBsZmZAyMZegCjd~tLB7PQhu~bndZFbg-HS5PLoFowZKvLoqdudl28S7eLWhl~F5a7V~WctrbHBBKnmbcuJgBDodOleYR4jz-kqruQm8gx9TuOrRqp6AmMAihMo53vyHXm8uU3nGhu7D35Y1faKTI5hqGuv3IdS0cxKCAcQBPriSw6cncwEo5vr8S8UCyxnhjZpMteQ16f5B73UKWKvsN9WrKIT6egKI5cg57z7jlLofw8BIUab5pmXX7xpPGAy6K3z620xw5x3nw8CvE91QVSOhkrKH2euMg__&Key-Pair-Id=APKAI6TU7MMXM5DG6EPQ&track_authorization=eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJnZW8iOiJQSyIsInN1YiI6IiIsInJpZCI6ImIxMjgwMTA4LTljMmMtNDM4Mi1iNTBkLWEwNmQzYjc4NGNkNyIsImlhdCI6MTY1MjAzNTE2MX0.Orl46D2FPe7PcJcR-SGxQ5roZ6_75Ss-93PdEkUnEkw \
sc_track.mp3
@anecdata
anecdata / code.py
Last active March 29, 2024 00:19
CircuitPython with 4 Networks: W5100S + W5500 + ESP32-S2 + ESP32SPI
import board
from digitalio import DigitalInOut, Direction
from adafruit_wiznet5k.adafruit_wiznet5k import WIZNET5K
import adafruit_wiznet5k.adafruit_wiznet5k_socket as wiznet5k_socket
from adafruit_esp32spi import adafruit_esp32spi
import adafruit_esp32spi.adafruit_esp32spi_socket as esp_socket
import wifi
import socketpool
import ssl
import adafruit_requests
@Birdie0
Birdie0 / ifttt-webhooks-extended-guide.md
Last active November 1, 2024 08:43
How to use Discord Webhooks

⚠️ This gist is no longer updated! For maintained, improved and even more extended guide click here.


How to use Discord Webhook

It's a JSON

First, learn JSON. It's not programming language, not even close. Just follow syntax rules and you will be fine.

@ianklatzco
ianklatzco / discord-bot-post-message.py
Created December 29, 2016 02:29
sends messages to a discord channel using a bot via http POST
# post a message to discord api via a bot
# bot must be added to the server and have write access to the channel
# you may need to connect with a websocket the first time you run the bot
# use a library like discord.py to do so
import requests
import json
channelID = "your_id_goes_here" # enable dev mode on discord, right-click on the channel, copy ID
botToken = "your_token_here" # get from the bot page. must be a bot, not a discord app
@mbaldessari
mbaldessari / ethtool-speed-test.c
Created April 19, 2015 08:08
Get the speed of a network interface via the ethtool interface
#include <stdio.h>
#include <stdint.h>
#include <string.h>
#include <sys/ioctl.h>
#include <sys/stat.h>
#include <net/if.h>
#include <ctype.h>
#define ETHTOOL_GSET 0x1
#define SIOCETHTOOL 0x8946
@passos
passos / Dumper.py
Last active March 24, 2023 02:55
A perl Data.Dumper clone for Python
"""
A perl Data.Dumper clone for Python
Author: [email protected]
2011-07-08
Copyright 2011 Jinyu LIU
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.