Skip to content

Instantly share code, notes, and snippets.

View alphapapa's full-sized avatar

Adam Porter alphapapa

  • USA
View GitHub Profile
@alphapapa
alphapapa / README.md
Created January 5, 2021 03:17 — forked from thibaudcolas/README.md
Video Downloader professional kmdldgcmokdpmacblnehppgkjphcbpnn background.js

Video Downloader professional kmdldgcmokdpmacblnehppgkjphcbpnn background.js

This is the source of background.js for a now-unpublished Chrome extension called "Video Download professional" (ID kmdldgcmokdpmacblnehppgkjphcbpnn, since then replaced with another "Video Download professiona" (ID bacakpdjpomjaelpkpkabmedhkoongbi). This script is republished here for educational purposes. It has initially been extracted from the extension’s archive available as v2.4 on https://www.crx4chrome.com/.

Why is this interesting?

The extension has appeared in malware discussions in the past. Its replacement of Video downloader professional "bacakpdjpomjaelpkpkabmedhkoongbi" seems related to the ownership change of The Great Suspender.

What does t

@alphapapa
alphapapa / org-ql-rasmi.el
Created December 18, 2020 09:50 — forked from mskorzhinskiy/org-ql-rasmi.el
Current configuration for personal org queries
(setq
org-ql-views
'(("stuck" lambda nil
(interactive)
(org-ql-search
(org-agenda-files)
'(and (tags "story")
(not (tags "ignore"))
(not (done)) ;; Finished stories should be excluded
(not (descendants (todo "NEXT"))) ;; If there are already
@alphapapa
alphapapa / emacsconf2020poster.svg
Created November 11, 2020 07:49
EmacsConf 2020 poster design
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@alphapapa
alphapapa / dired.sh
Last active April 4, 2021 09:37
Standalone Dired launcher
#!/bin/bash
# Launch Dired in a plain Emacs configuration.
# Arguments are passed to Emacs, e.g. "-nw" works as expected.
emacs -q "$@" \
--eval "(dired default-directory)" \
--eval "(defun kill-window-or-emacs () (interactive) (if (one-window-p) (kill-emacs) (delete-window)))" \
--eval "(setq dired-dwim-target t delete-by-moving-to-trash t)" \
@alphapapa
alphapapa / native-comp-convenience.org
Created September 19, 2020 20:01
Emacs native-comp branch convenience c ode

Emacs native-comp Recipes

For lack of a better term.

Update Docker image

  1. Update Andrea’s image.
@alphapapa
alphapapa / emacs-27-svg-screenshot.svg
Last active August 22, 2020 15:53
Emacs 27 can take SVG screenshots of itself
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
- command-execute 207 89%
- call-interactively 207 89%
- funcall-interactively 146 63%
- execute-extended-command 116 50%
- sit-for 61 26%
- redisplay 49 21%
- redisplay_internal (C function) 4 1%
- funcall 4 1%
- #<compiled 0x26ac9b> 4 1%
- gui-backend-selection-exists-p 4 1%
@alphapapa
alphapapa / elfeed-views.el
Last active February 11, 2020 23:47
Elfeed views (i.e. filter sets)
;; See https://github.com/alphapapa/unpackaged.el#filter-hydra
@alphapapa
alphapapa / intersection-benchmarks.org
Last active January 30, 2020 06:24
Benchmarking list intersections

Note that the update to the macros which provide the :setup argument is not published yet…

(bench-multi-lexical ;; :ensure-equal t
  :times 100
  :setup (progn
           (setq lst1 (make-random-list 1000)
                 lst2 (make-random-list 1000))
           (defun make-random-list (n)
             (let ((l nil))
(defun ap/overlay-isearch-test ()
(interactive)
(with-current-buffer (get-buffer-create "*overlay-isearch-test*")
(pop-to-buffer (current-buffer))
(erase-buffer)
(dolist (ov (overlays-in (point-min) (point-max)))
(delete-region (overlay-start ov) (overlay-end ov))
(delete-overlay ov))
(insert "foo\n")
(ap/insert-overlaid "bar\n" :transcluded-content t)