Skip to content

Instantly share code, notes, and snippets.

cp mqtt.db ebusd-from-mqtt.db
sqlite3 ebusd-from-mqtt.db "DROP TRIGGER mqtt_after_insert; DROP TRIGGER mqtt_after_update;ALTER TABLE mqtt DROP qos; ALTER TABLE mqtt DROP retain; ALTER TABLE mqtt DROP history_enable; ALTER TABLE mqtt DROP history_diffonly; UPDATE mqtt SET ts=datetime(ts, '-1 hour'); UPDATE mqtt_history SET ts=datetime(ts, '-1 hour');"
sqlite3 ebusd-from-mqtt.db < newtriggers.sql
{
"data": [
{
"package": null,
"note": "sa;dlfkjasd;flkjasd f;lkasdjf a;sldkfj asd;flkjasdf",
"replaces": {
"name": "php"
},
"vetted": true
},
{
"data": [
{
"package": null,
"note": "sa;dlfkjasd;flkjasd f;lkasdjf a;sldkfj asd;flkjasdf",
"replaces": {
"name": "php"
},
"vetted": true
},
$ http GET https://wimleers.com/.well-known/webfinger
HTTP/1.1 200 OK
Accept-Ranges: bytes
Age: 1172
Connection: keep-alive
Content-Length: 475
Content-Type: application/octet-stream
Date: Sun, 28 May 2023 08:05:52 GMT
ETag: "6473069d-1db"
Last-Modified: Sun, 28 May 2023 07:45:33 GMT
@wimleers
wimleers / gist:706420
Created November 19, 2010 11:52
OpenTracker stats
http://tracker.driverpacks.net:6969/stats?mode=tpbs&format=ben
-> per torrent: hash (ben-encoded), complete, downloaded, incomplete
http://tracker.driverpacks.net:6969/stats?mode=tpbs&format=txt
-> per torrent: hash, seeders, leechers
http://tracker.driverpacks.net:6969/stats?mode=statedump
-> per torrent: hash, base (time in minutes since epoch when the torrent last had >0 peers, *60 = unix timestamp), downloaded
@wimleers
wimleers / ama-manual-cloud-deploy.md
Created June 10, 2020 15:24 — forked from balsama/ama-manual-cloud-deploy.md
Instructions to manually deploy Migrate Assistant to an Acquia Cloud environment

Manually deploy a newly created migrate project to Acquia Cloud

@TODO

Updated 10 June

  • Manually test again
  • Add instructions on scp-ing files directory too

Prerequisites

  1. Admin access to an Acquia Cloud hosting environment.
  2. A Drupal 7 site running locally
@wimleers
wimleers / dps-cdn-rsync.sh
Created October 31, 2010 23:58
Script that syncs a directory recursively to a Push CDN using rsync.
#!/bin/sh
LOGFILE=/data/logs/dps-cdn-rsync/$(date "+%Y-%m").log
# Append a header first, so we know when this script was run.
date "+%n%n=====%nSyncing DriverPacks to CDN at %Y-%m-%d %H:%M:%S" >> $LOGFILE
# Now perform the actual syncing, still appending to the logfile.
rsync -avv --progress --delete --exclude lost+found --exclude .ssh --exclude .bash_history /data/www/downloadsorigin.driverpacks.net/ dpsdl.drupalcdn@storage01.netdna.com:/home/dpsdl.drupalcdn/public_html/ >> $LOGFILE

Mateu, Gabe and I just released the first RC of JSON API 2, so time for an update!

It's been three months since the previous "state of JSON API" blog post, where we explained why JSON API didn't get into Drupal 8.6 core.

What happened since then? In a nutshell:

  • We're now much closer to getting JSON API into Drupal core!
  • JSON API 2.0-beta1, 2.0-beta2 and 2.0-rc1 were released
  • Those three releases span 84 fixed issues. (Not counting support requests.)
  • includes are now 3 times faster, 4xx responses are now cached!
@wimleers
wimleers / gist:702387
Created November 16, 2010 19:55
How to convert from a custom date format into a UTC string using Qt.
QDateTime timeConvertor;
QString customDateString = "14-Nov-2010 05:27:03 +0100";
QString dateTime = customDateString.left(20);
int timezoneOffset = customDateString.right(5).left(3).toInt();
timeConvertor = QDateTime::fromString(dateTime, "dd-MMM-yyyy HH:mm:ss");
// Mark this QDateTime as one with a certain offset from UTC, and set that
// offset.
timeConvertor.setTimeSpec(Qt::OffsetFromUTC);
modules/json82/json82.info.yml | 5 +++++
modules/json82/json82.services.yml | 5 +++++
modules/json82/src/Json82Encoder.php | 14 ++++++++++++++
modules/json82/src/Json82ServiceModifier.php | 28 ++++++++++++++++++++++++++++
4 files changed, 52 insertions(+)
diff --git a/modules/json82/json82.info.yml b/modules/json82/json82.info.yml
new file mode 100644
index 0000000..3eabde8
--- /dev/null