Skip to content

Instantly share code, notes, and snippets.

View Ellpeck's full-sized avatar

Ell (Julian) Ellpeck

View GitHub Profile
@davidedmundson
davidedmundson / PlasmaNested.sh
Last active April 18, 2025 11:48
Run plasma from within gamescope
#!/bin/sh
# Remove the performance overlay, it meddles with some tasks
unset LD_PRELOAD
## Shadow kwin_wayland_wrapper so that we can pass args to kwin wrapper
## whilst being launched by plasma-session
mkdir $XDG_RUNTIME_DIR/nested_plasma -p
cat <<EOF > $XDG_RUNTIME_DIR/nested_plasma/kwin_wayland_wrapper
#!/bin/sh
@OliverBalfour
OliverBalfour / README.md
Last active January 29, 2025 19:44
Obsidian custom checkbox snippet

Custom checkboxes for Obsidian! It's like deathau's snippet except updated to work really well in Live Preview mode in Obsidian 1.0.

Simply edit the x inside checkboxes to >, ?, etc. to see styling like below!

Editing Live Preview Viewing
image image image

Installation:

  • Download the checkbox.css file on this page
@maybemkl
maybemkl / remove_links.py
Created September 6, 2021 23:00
Remove markdown wiki-link brackets during pandoc exports
@kepano
kepano / obsidian-web-clipper.js
Last active April 6, 2025 19:24
Obsidian Web Clipper Bookmarklet to save articles and pages from the web (for Safari, Chrome, Firefox, and mobile browsers)
javascript: Promise.all([import('https://unpkg.com/[email protected]?module'), import('https://unpkg.com/@tehshrike/[email protected]'), ]).then(async ([{
default: Turndown
}, {
default: Readability
}]) => {
/* Optional vault name */
const vault = "";
/* Optional folder name such as "Clippings/" */
@ttalexander2
ttalexander2 / BinaryTreePacker.cs
Last active December 18, 2024 21:11
Binary Tree Image Packer for C# ( .NET Framework)
using System;
using System.Drawing;
namespace TexturePacker
{
public class PackedNode
{
public PackedNode Left { get; private set; }
public PackedNode Right { get; private set; }
public System.Drawing.Rectangle Rect { get; private set; }
@kherge
kherge / Stylus.css
Last active May 17, 2023 18:11
Google Calendar Dark Mode
/* calendar.google.com */
:root {
--base-bg-color: #111111;
--base-fg-color: #eeeeee;
--border-color: #202020;
--button-hover-bg-color: #333333;
--button-hover-border-color: #404040;
@tarleb
tarleb / noexport-subtrees.lua
Last active October 21, 2024 12:46
Emulating org-mode's :noexport: behavior for Markdown.
--[[
Remove all subtrees whose headlines contain class `noexport`.
License: MIT
Copyright: © Albert Krewinkel
]]
-- pandoc.utils.make_sections exists since pandoc 2.8
PANDOC_VERSION:must_be_at_least {2,8}
{
'I',
'you',
'my',
'mine',
'myself'
'we',
'us',
'our',
'ours',
@xoppa
xoppa / outline.fragment.glsl
Created October 12, 2015 20:42
very basic outline shader
#ifdef GL_ES
#define LOWP lowp
precision mediump float;
#else
#define LOWP
#endif
const float offset = 1.0 / 128.0;
varying vec2 v_texCoords;
uniform sampler2D u_texture;
@polo2ro
polo2ro / dump-imap.py
Last active January 5, 2025 08:56 — forked from FiloSottile/dump-imap.py
Simple script to dump an IMAP folder into eml files, store email using the message-id
#!/usr/bin/env python
#-*- coding:utf-8 -*-
import imaplib
import argparse
import email
import re
argparser = argparse.ArgumentParser(description="Dump a IMAP folder into .eml files")
argparser.add_argument('-s', dest='host', help="IMAP host, like imap.gmail.com", required=True)