Skip to content

Instantly share code, notes, and snippets.

View dr5hn's full-sized avatar
🪄
Turning ☕ into code | Full Stack Magician 🧙‍♂️✨

Darshan Gada dr5hn

🪄
Turning ☕ into code | Full Stack Magician 🧙‍♂️✨
View GitHub Profile
@dr5hn
dr5hn / Win10.preset
Created February 5, 2024 11:12 — forked from Log1x/Win10.preset
Recommended Windows 10 Performance Preset
# See: https://github.com/Disassembler0/Win10-Initial-Setup-Script
### Require administrator privileges ###
RequireAdmin
### Privacy Tweaks ###
DisableTelemetry # EnableTelemetry
DisableWiFiSense # EnableWiFiSense
DisableSmartScreen # EnableSmartScreen
DisableWebSearch # EnableWebSearch
@dr5hn
dr5hn / go.mod
Created January 24, 2024 08:43 — forked from caner-cetin/go.mod
World Data Fix Script on Golang
module cityconv
go 1.20
require github.com/jackc/pgx/v5 v5.4.1
require (
github.com/jackc/pgpassfile v1.0.0 // indirect
github.com/jackc/pgservicefile v0.0.0-20221227161230-091c0ba34f0a // indirect
golang.org/x/crypto v0.9.0 // indirect
@dr5hn
dr5hn / country-files.js
Created January 5, 2024 16:09 — forked from vis97c/country-files.js
Separate country data from dr5hn/countries-states-cities-database into smaller files
const fs = require("fs/promises");
const path = require("path");
const _ = require("lodash");
/**
* Write file
* @param {string} filePath
* @param {*} data
*/
async function writeFile(filePath, data) {
@dr5hn
dr5hn / README.md
Created March 25, 2023 14:16 — forked from VladimirAlexiev/README.md
How to use Google Sheets to Manage Wikidata Coreferencing

How to use Google Sheets to Manage Wikidata Coreferencing

A previous post How to Add Museum IDs to Wikidata explained how to use SPARQL to find missing data on Wikidata (Getty Museum IDs), how to create such values (from museum webpage URLs) and how to format them properly for QuickStatements.

Here I explain how to use Google sheets to manage a more advanced task. The sheet AAT-Wikidata matches about 3k AAT concepts to Wikipedia, WordNet30 and BabelNet (it restored an old mapping to Wordnet, retrieved it from BabelNet, mapped to Wikipedia).

  • For each row, it uses the following Google sheet formula (column C) to query the Wikipedia API and get the corresponding Wikidata ID (wikibase_item); split on two lines for readability:
=ImportXml(concat("https://en.wikipedia.o