Skip to content

Instantly share code, notes, and snippets.

View gentlecat's full-sized avatar
🙃
It's complicated

Roman Tsukanov gentlecat

🙃
It's complicated
View GitHub Profile
@gentlecat
gentlecat / draft.txt
Created May 5, 2016 09:43
AcousticBrainz API changes
We are making some improvements to the way AcousticBrainz API is structured. These changes don't affect the data you can already retrieve and submit.
The most significant change is that all API points are now located at *https://acousticbrainz.org/api/v1/*. This should make it easier to understand where all resources are located and how to interact with them. To help this, we also created a new documentation page: https://acousticbrainz.readthedocs.io/api.html. It lists all enpoints that are currently available and describes how to use them.
Old endpoints for working with data that we store will keep working for some time. We'll announce when they are going to be removed as soon as the decision is made. If you already have an application that uses AcousticBrainz data, you should switch to the new API.
@gentlecat
gentlecat / schema_change.sql
Last active August 29, 2015 14:20
MetaBrainz Donation Records
BEGIN;
-- Changes to donation table from the old website to new one.
-- See http://git.io/vfhUF (old) and http://git.io/vfhTZ (new).
ALTER TABLE donation ALTER COLUMN moderator DROP DEFAULT;
ALTER TABLE donation ALTER COLUMN contact DROP DEFAULT;
ALTER TABLE donation ALTER COLUMN anon DROP DEFAULT;
ALTER TABLE donation ALTER COLUMN address_street DROP DEFAULT;
ALTER TABLE donation ALTER COLUMN address_city DROP DEFAULT;
@gentlecat
gentlecat / actual
Created January 15, 2015 00:11
Weird release years
year
mbid
02ded147-aec7-4f40-9641-802d48ec5e17 4
096e8440-2ba1-4c62-8a8e-fe3191175243 4
118fd8d4-e4ef-40f8-9320-6400fb2d3a1b 4
16376d56-e424-414d-97bb-87f33c571764 4
1a184342-e2f3-4ff4-b24d-4be52bd613b8 4
1af054d4-7fae-435c-bb80-fbe8acefaad9 4
1f5ca931-2fae-472a-bf9f-0b69a5e2bf91 4
3443a949-a7cf-4295-8620-fc04c94bad7b 4
### Keybase proof
I hereby claim:
* I am gentlecat on github.
* I am tsukanov (https://keybase.io/tsukanov) on keybase.
* I have a public key whose fingerprint is 69BF 501F FA39 5745 6D49 E1DD 89DE 8521 00D5 0E86
To claim this, I am signing this object:
@gentlecat
gentlecat / startup.sh
Last active August 29, 2015 14:02
CritiqueBrainz Sandbox Startup Magic
while true; do /home/gentlecat/critiquebrainz/venv/bin/python /home/gentlecat/critiquebrainz/cb.fcgi & sleep 1200; ps aux | grep cb.fcgi | grep gentlecat | grep -v grep | awk '{print $2}' | xargs kill; done
@gentlecat
gentlecat / cloudflare.php
Last active October 23, 2022 10:13
CloudFlare DNS records updater
<?php
/**
* Settings
*/
define('API_KEY', $_GET['apikey']); // CloudFlare API key
define('USERNAME', 'user@example.com'); // Email address used to login into CloudFlare
define('IP', getCurrentIP()); // Current IP address
echo 'Setting IP address to "' . IP . '"...<br />';