Skip to content

Instantly share code, notes, and snippets.

;;; unicad-autoloads.el --- automatically extracted autoloads (do not edit) -*- lexical-binding: t -*-
;; Generated by the `loaddefs-generate' function.
;; This file is part of GNU Emacs.
;;; Code:
(add-to-list 'load-path (or (and load-file-name (directory-file-name (file-name-directory load-file-name))) (car load-path)))
@QiangF
QiangF / README.org
Created July 6, 2023 06:52 — forked from douo/README.org
Emacs (no-x) as kitty scrollback_pager

Test on:

  • Linux
  • macOS

Linux dependencies:

  • xsel

~/.local/bin/kitty_emacs_pager

@QiangF
QiangF / eink_clean.ahk
Created April 12, 2023 06:10 — forked from llinfeng/eink_clean.ahk
Force full-screen refresh on e-ink monitors
#SingleInstance, force ; Allow only one instance of this script to be running.
#Persistent ; To stop the script from exiting.
; Here, press F1 to trigger the black/white flash
F1::
; Source: https://superuser.com/questions/662264/i-would-like-to-make-the-screen-go-black-every-8-seconds-how
Gui, Color, 000000
Gui, Show, x-5000 y-20 w8000 h8000
sleep 333
Gui, Color, FFFFFF
@QiangF
QiangF / erofi.sh
Last active January 2, 2023 03:10
rofi in elisp
emacsclient -c -F '((auto-raise . t) (visibility . t) (sticky . nil) (skip-taskbar . t) (undecorated . t) (name . "erofi") (width . 120) (height . 20) (vertical-scroll-bars . nil) (minibuffer . only))' -e "(progn (x-focus-frame nil) (rofi-in-elisp \"$1\"))"
conky.config = {
alignment = 'bottom_right',
double_buffer = true,
background = true,
border_width = 1,
cpu_avg_samples = 2,
default_color = 'green',
draw_borders = false,
draw_graph_borders = true,
draw_outline = false,
@QiangF
QiangF / sway_workspaces.py
Created September 14, 2022 01:36 — forked from Nama/sway_workspaces.py
Restore workspaces in sway to displays and move applications to saved workspaces
#!/usr/bin/python
'''
* setup displays first, e.g. with wdisplay
* run after setting up your displays `python sway_workspaces.py save <profilename>`
* repeat for every display setup
* setup kanshi and make it run `python sway_workspaces.py load <profilename>`
Multiple windows of an application/class aren't handled. No idea how to do so.
Had to alter the default tree, so the outputs are not the ports.
@QiangF
QiangF / lisp-resources-digikar-2020.md
Created September 11, 2022 07:10 — forked from digikar99/lisp-resources-digikar-2020.md
If programming is more than just a means of getting things done for you, then Common Lisp is for you!

Why not: from Common Lisp to Julia

This article is a response to mfiano’s From Common Lisp to Julia which might also convey some developments happening in Common Lisp. I do not intend to suggest that someone coming from a Matlab, R, or Python background should pickup Common Lisp. Julia is a reasonably good language when compared to what it intends to replace. You should pickup Common Lisp only if you are interested in programming in general, not limited to scientific computing, and envision yourself writing code for the rest of your life. It will expand your mind to what is possible, and that goes beyond the macro system. Along the same lines though, you should also pickup C, Haskell, Forth, and perhaps a few other languages that have some noteworthy things to teach, and that I too have been to lazy to learn.

/I also do not intend to offend anyone. I’m okay with criticizing Common Lisp (I myself have done it below!), but I want t

@QiangF
QiangF / auto-rsync.el
Created September 2, 2022 00:30 — forked from mtmtcode/auto-rsync.el
auto-rsync.el - Emacs minor mode to execute rsync automaticlly
;;; auto-rsync-mode -- minor mode for auto rsync
;;
;; Author: @l3msh0
;;
;;; Example
;;
;; (require 'auto-rsync)
;; (auto-rsync-mode t)
;; (setq auto-rsync-dir-alist
@QiangF
QiangF / i3ass-drr
Created August 27, 2022 02:12 — forked from budRich/i3ass-drr
A small script that runs/activate or hide target window in i3
#!/bin/bash
#
# i3ass-drr -n "name" -c "class" -i "instance/classname" -m "mark" -r "command"
while getopts c:n:r:i:m: option
do
case "${option}"
in
c) aSrch=("${aSrch[@]}" --class "${OPTARG}");;