Skip to content

Instantly share code, notes, and snippets.

@timvisee
timvisee / SUBREDDIT_LIST.md
Last active May 5, 2024 18:13
Get a list of subreddits you're subscribed to on reddit. https://timvisee.com/blog/list-export-your-subreddits/

As posted on: https://timvisee.com/blog/list-export-your-subreddits/

Get a list of your subreddits

To obtain a list of your subreddits, do the following:

  • First make sure you're logged in on reddit, on a desktop browser.
  • Then visit reddit.com/subreddits.
  • Then put the following snippet in your browsers address bar, and press Enter.
    Make sure javascript: is included at the beginning, your browser might remove it while copy-pasting for security reasons:
@aamiaa
aamiaa / CompleteDiscordQuest.md
Last active May 5, 2024 18:09
Complete Recent Discord Quest

Complete Recent Discord Quest

Note

This no longer works in browser!

Note

This no longer works if you're alone in vc! Somebody else has to join you!

How to use this script:

  1. Accept the quest under User Settings -> Gift Inventory
# ** Basic API Call **
import requests
import urllib
API_KEY = ''
ENDPOINT = '/api/v2.0/reporting?'
BASE_REPORTING_URL = 'https://api.singular.net{0}'.format(ENDPOINT)
params = {
'api_key': API_KEY,
@Reedbeta
Reedbeta / cool-game-programming-blogs.opml
Last active May 5, 2024 18:07
List of cool blogs on game programming, graphics, theoretical physics, and other random stuff
<?xml version="1.0" encoding="UTF-8"?>
<opml version="1.0">
<head>
<title>Graphics, Games, Programming, and Physics Blogs</title>
</head>
<body>
<outline text="Tech News" title="Tech News">
<outline type="rss" text="Ars Technica" title="Ars Technica" xmlUrl="http://feeds.arstechnica.com/arstechnica/index/" htmlUrl="https://arstechnica.com"/>
<outline type="rss" text="Polygon - Full" title="Polygon - Full" xmlUrl="http://www.polygon.com/rss/index.xml" htmlUrl="https://www.polygon.com/"/>
<outline type="rss" text="Road to VR" title="Road to VR" xmlUrl="http://www.roadtovr.com/feed" htmlUrl="https://www.roadtovr.com"/>
@ted-piotrowski
ted-piotrowski / nodejs.sh
Created September 26, 2016 02:36
Install latest NodeJS on Ubuntu ARM
sudo apt-get uninstall nodejs # uninstall nodejs 4.2.6
wget https://nodejs.org/dist/v6.6.0/node-v6.6.0-linux-armv7l.tar.gz # get latest ARM build
tar -xvf node-v6.6.0-linux-armv7l.tar.gz # extract it
sudo cp node-v6.6.0-linux-armv7l /etc/node6.6 # copy extracted file to /etc folder
sudo ln -s /etc/node6.6/bin/node /usr/bin/node # link the nodejs executable
sudo ln -s /etc/node6.6/bin/npm /usr/bin/npm # link the npm executable
node --version # should output v6.6.0
@gragland
gragland / use-optimistic-mutation-example.ts
Last active May 5, 2024 18:07
useOptimisticMutation for React Query. Optimistically update data in multiple locations with rollback on error.
import axios from 'axios'
import { useOptimisticMutation } from "./useOptimisticMutation.ts"
type Response = boolean
type Error = unknown
type MutationVariables = {itemId: string}
type Items = {id: string; name: string}[]
type Likes = {itemId: string}[]
type History = {type: string}[]
@AgentOak
AgentOak / youtube_formats.md
Last active May 5, 2024 18:03
Youtube Format IDs

Last updated: April 2021

Also known as itag or format codes and way back they could be specified with the fmt parameter (e.g. &fmt=22). Depending on the age and/or popularity of the video, not all formats will be available.

DASH video

Resolution AV1 HFR High AV1 HFR AV1 VP9.2 HDR HFR VP9 HFR VP9 H.264 HFR H.264
MP4 MP4 MP4 WebM WebM WebM MP4 MP4
@xrman
xrman / gist:4468f545b169969466bceb694d742dad
Created March 12, 2019 21:47
FastStone Capture Full Serial Key
Registration Code
Name : www.xyraclius.com
Serial : OOCRYIMDMDPWRETFPSUZ
using mode_t = unsigned int;
using size_t = decltype(sizeof(int));
namespace detail
{
struct invalid_permission_character {};
struct invalid_permission_string_length {};
consteval mode_t from_readable_mode_string(const char * const s)
{
@MogulChris
MogulChris / screenshot.php
Created April 10, 2019 22:15
Automation and taking full-screen screenshots using Laravel Dusk and Chrome webdriver
<?php
/**
* This script is using Laravel Dusk to take screenshots of a URL, but not in the context of a regular Dusk test.
* My Laravel application is taking screenshots of *other* sites, but you could adapt this to a Dusk test taking screenshots of your Laravel site.
* 1. Install Dusk https://laravel.com/docs/5.8/dusk#installation
* 2. Make sure it works with regular Dusk tests first.
* 3. Use the code below for a stand-alone Chrome webdriver instance to do automation things.
*/