Skip to content

Instantly share code, notes, and snippets.

pkgbase = eve-v-drivers-dkms
pkgdesc = Patched drivers for Eve V
pkgver = 4.15.9
pkgrel = 1
url = https://www.kernel.org/
arch = x86_64
license = GPL2
depends = dkms
source = https://www.kernel.org/pub/linux/kernel/v4.x/linux-4.15.tar.xz
source = https://www.kernel.org/pub/linux/kernel/v4.x/linux-4.15.tar.sign
#!/usr/bin/env python3
import contextlib, ctypes, os, pathlib, subprocess, sys
EFIVARSFS = pathlib.Path('/sys/firmware/efi/efivars')
LOADER_GUID = '4a67b082-0a4c-41cf-b6c7-440b29bb8c4f'
LOADER_ENTRY_ONE_SHOT = 'LoaderEntryOneShot'
FS_IMMUTABLE_FL = 0x00000010 # see <linux/fs.h>
try:
#!/bin/sh
set -euo pipefail
case ${1:-0} in
0|normal) rot=normal mat=( 1 0 0 0 1 0 0 0 1) ;;
1|left) rot=left mat=( 0 -1 1 1 0 0 0 0 1) ;;
2|flip) rot=inverted mat=(-1 0 1 0 -1 1 0 0 1) ;;
3|right) rot=right mat=( 0 1 0 -1 0 1 0 0 1) ;;
*)
echo "Usage: $(basename "$0") [<0|1|2|3>|<normal|left|flip|right>]" >&2
[Unit]
Description=Map absolute input touch device to fixed output
BindsTo=dev-input-%i.device
After=dev-input-%i.device
[Service]
Type=oneshot
ExecStart=/bin/sh -c ' \
/usr/bin/libinput list-devices | \
/usr/bin/awk \' \
import android.graphics.Canvas
import android.graphics.DashPathEffect
import android.graphics.Paint
import android.text.style.LineBackgroundSpan
import android.text.style.UnderlineSpan
/** Draws a dotted underline (as opposed to solid [UnderlineSpan]). */
class DottedUnderlineSpan : LineBackgroundSpan {
private val paint = Paint()
private val dashIntervals = FloatArray(2)
/dev/zram0 none swap defaults,pri=8192 0 0
@ephemient
ephemient / ⁄etc⁄systemd⁄network⁄90-wifi.network
Created January 29, 2018 19:26
systemd-networkd + wpa_supplicant integration
[Match]
Type=wlan
[Network]
DHCP=yes
[DHCP]
RouteMetric=2048
@ephemient
ephemient / .SRCINFO
Last active January 10, 2018 02:14
nodejs-watchman-processor
pkgbase = nodejs-watchman-processor
pkgdesc = Folder synchronization tool with a simple dashboard
pkgver = 2.2.0
pkgrel = 1
url = https://github.com/markis/watchman-processor
arch = any
license = MIT
makedepends = npm
depends = nodejs
depends = rsync
import heapq
import sys
if sys.version_info >= (3, 0):
xrange = range
def is_prime_trial_division(n):
"""Prime checking by trial division, checking only odds up to sqrt(n).
@ephemient
ephemient / .SRCINFO
Last active December 5, 2017 21:42
pam_recent
pkgbase = pam_recent-git
pkgdesc = pam_recent is a small PAM module for making iptables' recent match more useful
pkgver = r12.9c942dc
pkgrel = 1
url = https://github.com/az143/pam_recent
arch = x86_64
license = GPL
provides = pam_recent
conflicts = pam_recent
source = git+https://github.com/az143/pam_recent.git