Skip to content

Instantly share code, notes, and snippets.

@GitTom
GitTom / supa_audit--0.3.1--changes.sql
Created July 31, 2024 20:14
Variation of supabase's supa_audit PostgreSQL extension - adds 'changes' column to highlight changes made by UPDATE operations.
-- SPDX-License-Identifier: Apache-2.0
/*
Generic Audit Trigger
Linear Time Record Version History
Date:
2022-02-03
Purpose:
Generic audit history for tables including an indentifier

Stopping Autoplay Videos

Browser's should include a setting that allows users to disable autoplay on videos (and then reenable it on a site by site basis, ideally).

I appreciate that Mozilla & Google try to balance the rights/interests/integrity of websites and their developers with the interests of their end-users, to keep the web healthy, but autoplay videos are a menace IMO.

I think most people would love to be able to end autoplay on Netflix!

I'm frustrated by the number of tech headlines that have pronounced that a new version of either browser has finally truly 'blocked autoplay videos' but so far it has never been true. Mostly what they do is block the sound from autoplay videos.

@GitTom
GitTom / RedditOAuth.java
Last active June 30, 2019 15:42
Reddit OAuth2 Java sample code (uses Google HTTP and json.org libs)
import java.io.IOException;
import java.util.HashMap;
import java.util.Map;
import org.json.JSONObject;
import org.json.JSONTokener;
import com.google.api.client.extensions.appengine.http.UrlFetchTransport;
import com.google.api.client.http.GenericUrl;
import com.google.api.client.http.HttpContent;
import com.google.api.client.http.HttpRequest;