Source: https://boredzo.org/blog/archives/2007-05-22/virtual-key-codes#comment-523980
Apple's Developer Documentation: https://developer.apple.com/documentation/appkit/nsevent/keycode/
| Key | Code |
|---|---|
| KEY_A | 0 |
| KEY_S | 1 |
| KEY_D | 2 |
| KEY_F | 3 |
Source: https://boredzo.org/blog/archives/2007-05-22/virtual-key-codes#comment-523980
Apple's Developer Documentation: https://developer.apple.com/documentation/appkit/nsevent/keycode/
| Key | Code |
|---|---|
| KEY_A | 0 |
| KEY_S | 1 |
| KEY_D | 2 |
| KEY_F | 3 |
| #!/bin/bash | |
| # This script installs libev from source on Debian-based systems (like Raspberry Pi OS), | |
| # based on the official Homebrew formula. | |
| # Original formula: https://github.com/Homebrew/homebrew-core/blob/3f94f7aaead4364ea6905957daacefd73ca40342/Formula/lib/libev.rb | |
| # NOTE: Translated from Ruby to Bash by Gemini Pro 2.5 with the prompt: | |
| # "Look at this brew install script for libev on MacOS – <ORIGINAL RUBY SCRIPT>. \ | |
| # I want to install this libev package on Debian-based Raspberry Pi OS. Please create a shell script based on this." |
What I received:
.sql database file.I figured that the .sql file is the WordPress database.
How to get shit running:
Set up an Ubuntu virtual machine. Why virtual machine? So you get a contained sandbox and a clean slate for your experiments. Why Ubuntu? It's just a whole lot easier to do these things on Linux. Screw your MAMP and WAMP stacks.
Install nginx, mysql-server and php7.4. That's your LEMP stack right there.[^1] DigitalOcean tutorials can help you set these things up. Use php7.4 because most of the Internet breaks on php8.1. You'll need to add a new ppa package for that - DigitalOcean can tell you how. All the additional php packages that you install should also have the php7.4 prefix in front of them. If you install php-fpm you might just get php8.1-fpm. S
If you're trying to make a population map using Datawrapper, this list might be helpful to match data between Wikipedia and Datawrapper.
• Datawrapper country names from www.datawrapper.de • United Nations / Wikipedia country names from List of countries by population (United Nations)
| Datawrapper Country Name | UN / Wikipedia Country Name |
|---|---|
| Afghanistan | Afghanistan |
| Albania | Albania |
| Algeria | Algeria |
Note: These instructions are for my future self.
Assuming you have a remote server with the following details –
IP Address: 192.168.1.1
Username: rockstar
Password: ********
If you've got data that looks like this –
| S.No. | UID | District | Block | Age | Gender | Social Category |
|---|---|---|---|---|---|---|
| 1 | 239140001 | HOOGHLY | ARAMBAGH | 7 | GIRL | GENERAL |
| 2 | 239140002 | HOWRAH | SHYAMPUR-I | 2 | BOY | GENERAL |
| 3 | 239140003 | KOLKATA | WARD 72 | 7 | BOY | SC |
| 4 | 239140004 | HOOGHLY | BALAGARH | 3 | GIRL | ST |
| 5 | 239140005 | BIRBHUM | DUBRAJPUR | 5 | BOY | SC |
| 6 | 239140006 | KOLKATA | WARD 101 | 8 | TRANS | OBC |
| # install dependencies listed here: https://developers.google.com/drive/api/v3/quickstart/python#step_1_install_the_google_client_library | |
| from googleapiclient.discovery import build | |
| from google.oauth2.service_account import Credentials | |
| from googleapiclient.http import MediaFileUpload | |
| # Location of the access token | |
| # Get this from https://console.cloud.google.com/apis/api/drive.googleapis.com/ | |
| ACCESS_TOKEN_LOCATION = "client-secret.json" | |
| # Check the scope for your needs at https://developers.google.com/identity/protocols/oauth2/scopes#drive |
Commento is an open source commenting service. It is privacy first and lightweight.
Commento++ is a fork that I highly recommend. It has some nifty features like commenting with a name instead of logging in (side note: I use this feature as a proxy for SSO on one of my projects).
Here's how to self-host it on your server.
There are five main steps to this –
| """ | |
| ## ATTENTION | |
| The sample Python Quickstart code on Google Developer's site only shows how to access a Google Sheet using OAuth credentials. But that feels like an overkill when you simply want to read data from a sheet. | |
| This code does just that. | |
| ## What is this code snippet useful for? | |
| This code snippet serves the following use-case: | |
| 1. You want to simply READ data from a Google Sheets document | |
| 2. You don't want to set up OAuth and instead want to use the Service Account API that lets you plug the API key in for making requests |