Language feature | Kotlin | Scala |
---|
Remove contents of /usr/local/var/mysql | |
brew uninstall mysql | |
brew uninstall mariadb | |
brew install mariadb | |
mysql_install_db | |
mysql.server start | |
sudo mysql | |
- this opens a session. Just exit mysql for now | |
mysql_secure_installation | |
- Answer yes to everything |
""" | |
Exploration of a graphql client in Python | |
""" | |
import asyncio | |
from dataclasses import dataclass | |
from typing import Generator | |
from gql import gql | |
from gql.client import Client, AsyncClientSession | |
from gql.transport.aiohttp import AIOHTTPTransport |
<?xml version="1.0" encoding="UTF-8"?> | |
<feed xmlns="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/"> | |
<title>Poema del día de Francisco Álvarez Hidalgo</title> | |
<link rel="alternate" href="http://www.poesiadelmomento.com" /> | |
<link rel="self" href="http://www.poesiadelmomento.com/poemadeldia.xml" /> | |
<subtitle>Poema del día de Francisco Álvarez Hidalgo</subtitle> | |
<id>http://www.poesiadelmomento.com/</id> | |
<updated>2022-10-08T16:19:32.274011+00:00</updated> | |
<dc:date>2022-10-08T16:19:32.274011+00:00</dc:date> | |
<entry> |
Dump the whole database:
mysqldump -u myuser my_database -p > dump.sql
Open the dump.sql
file.
Do a search and replace: for example replace all occurrences of utf8mb3
with utf8mb4
.
Save the file.
Clear zfs snapshots:
- Download this script: https://github.com/bahamas10/zfs-prune-snapshots/blob/master/zfs-prune-snapshots
- Run
sudo bash zfs-prune-snapshots 1w
Uninstall rabbitmq:
sudo apt-get remove --auto-remove rabbitmq-server
sudo apt-get purge --auto-remove rabbitmq-server
command="ls -la" | |
process=command.execute() | |
process.waitFor() | |
def output = process.in.text | |
println "Output:\n$output" | |
def error = process.err.text | |
println "Error:\n$error" |
#!/bin/bash | |
process_active_app() { | |
local last_date_str="" | |
local last_timestamp_s=0 | |
local last_active_app="" | |
while IFS= read -r current_active_app; do | |
local current_timestamp |
Here's how you can develop for an Android 1.5 Cupcake emulator on MacOS 15, in 2025.
We need an old version of the sdk "command line" tools, without android studio.
The available version numbers are here: https://developer.android.com/tools/releases/sdk-tools
You can go to https://developer.android.com/studio and scroll down to "Command line tools only".
Starting from this commit, git log
no longer includes git bisect references like bisect/good
or bisect/bad
.
https://github.com/git/git/commit/92156291ca82ae4f4ad09fde8181c5f2b7dba6ca
This was first included in release v2.38.0, tagged on Sun Oct 2 08:44:15 2022 -0700
You now have to specify git log --clear-decorations
(there may be some global config to set as an alternative).