Skip to content

Instantly share code, notes, and snippets.

@unxok
unxok / List of icons.md
Last active January 11, 2025 09:19 — forked from ljavuras/List of icons.md
List of icons in Obsidian
// codeblock language should be dataviewjs

/**
 * List all icons available to `obsidian.setIcon()`
 * 
 * @author Unxok <me@unxok.com>  
 * 
 * Based on the original work from:
 * @author Ljavuras <ljavuras.py@gmail.com>
@ddahan
ddahan / shell.py
Created September 8, 2024 20:29
FastAPI context-aware shell with model discovery and other auto-imports
# Requires Python 3.12+, IPython, rich
import datetime
import hashlib
import importlib
import inspect
import json
import logging
import os
import pkgutil
@ljavuras
ljavuras / List of icons.md
Last active March 16, 2025 09:54
List of icons in Obsidian
/**
 * List all icons available to `obsidian.setIcon()`
 * 
 * @author Ljavuras <[email protected]>
 */

dv.container.createEl("style", { attr: { scope: "" }, text: `
.icon-table {
 display: flex;
@25yeht
25yeht / khanmingo_lite_prompt.txt
Created May 31, 2024 00:09
The system prompt for Khanmingo Lite
You are a GPT created by a user, and your name is Tutor Me. Note: GPT is also a technical term in AI, but in most cases if the users asks you about GPTs assume they are referring to the above definition.
Here are instructions from the user outlining your goals and how you should respond:
You are a tutor that always responds in the Socratic style. I am a student learner. Your name is Khanmigo Lite. You are an AI Guide built by Khan Academy. You have a kind and supportive personality. By default, speak extremely concisely at a 2nd grade reading level or at a level of language no higher than my own.
If I ask you to create some practice problems for them, immediately ask what subject I’d like to practice, and then practice together each question one at a time.
You never give the student (me) the answer, but always try to ask just the right question to help them learn to think for themselves. You should always tune your question to the knowledge of the student, breaking down the problem into simpler parts until
@lzjluzijie
lzjluzijie / warp.js
Created February 25, 2024 07:55
Cloudflare Warp 24PB key generator
# See https://halu.lu/%E6%9D%82%E8%B0%88/cloudflare-warp/
# Depolyed at https://warp.halu.lu/
// Change keys if needed
const keys = [
"9WO41D5p-6OP8xj27-36gQG75D",
"R65K12Up-aU907O2e-4nuvD581",
"06LM94EJ-1nl0V2d7-V847va5y",
]
@boecko
boecko / README.md
Last active August 28, 2024 23:16
Greasemonkey script to bulk edit gps in photoprismn
@dannberg
dannberg / obsidian-daily-note-template.txt
Last active April 16, 2025 07:10
Dann Berg's Daily Note Template for Obsidian. Uses Dataview & Templater plugins. Should be saved as a Markdown file in Obsidian. Read the full tour: https://dannb.org/blog/2022/obsidian-daily-note-template/
---
created: <% tp.file.creation_date() %>
---
tags:: [[+Daily Notes]]
# <% moment(tp.file.title,'YYYY-MM-DD').format("dddd, MMMM DD, YYYY") %>
<< [[Timestamps/<% tp.date.now("YYYY", -1) %>/<% tp.date.now("MM-MMMM", -1) %>/<% tp.date.now("YYYY-MM-DD-dddd", -1) %>|Yesterday]] | [[Timestamps/<% tp.date.now("YYYY", 1) %>/<% tp.date.now("MM-MMMM", 1) %>/<% tp.date.now("YYYY-MM-DD-dddd", 1) %>|Tomorrow]] >>
---
@AllanChain
AllanChain / netease_music_dl.py
Created June 29, 2021 03:37
网易云音乐歌单下载,保留 ID3 属性
from bs4 import BeautifulSoup
from pathlib import Path
from dataclasses import dataclass
import urllib.request
import re
from unicodedata import normalize
from mutagen.mp3 import EasyMP3
DOWNLOAD_TEMPLATE = "http://music.163.com/song/media/outer/url?id=%s.mp3"
@usametov
usametov / topics-search.txt
Created February 16, 2021 01:50
how to search github.com for multiple topics
Github.com ui .currently does not natively supoport search for multiple topic tags as of now. However their api allows you to query multiple tags. Below is a simple example to query github.com with ecs and go topic tags.
curl -H "Accept: application/vnd.github.mercy-preview+json" \
https://api.github.com/search/repositories?q=topic:ecs+topic:go
Response from the github can be rather verbose so lets filter only relavant info such repo url and description.
curl -H "Accept: application/vnd.github.mercy-preview+json" \
https://api.github.com/search/repositories\?q\=topic:ecs+topic:go | jq '.items[] | {url:.url, description:.description}'
"""A set of helpers for reversing urls, similar to Django ``reverse``.
Usage:
.. code:: python
@router.get("/class/{class_id}")
async def get_class(request: Request, class_id: int = Path(...)):
student_route = get_route(request.app, "list_students")
class_students_url = URLFactory(student_route).get_path(class_id=class_id)