Compare commits

..

No commits in common. "master" and "machina" have entirely different histories.

9 changed files with 14074 additions and 2250 deletions

1
.achievements Normal file

File diff suppressed because one or more lines are too long

1
.gitignore vendored
View File

@ -47,7 +47,6 @@
# Forge database
/forge-database.sqlite
/forge-database-v*.sql
/forge-database-v*.sqlite
# request.el cookie jars
/request/curl-cookie-jar

View File

@ -19,7 +19,6 @@
gpolonkai/duplicate-line
gpolonkai/move-to-beginning-of-line
gpolonkai/move-to-end-of-line
gpolonkai/org-space-key
hungry-delete-backward
hungry-delete-forward
indent-for-tab-command
@ -36,6 +35,7 @@
org-meta-return
org-return
org-self-insert-command
org-space-key
org-yank
overwrite-mode
sp-backward-delete-char
@ -45,7 +45,6 @@
sp-kill-region
sp-kill-word
sp-remove-active-pair-overlay
sp-rewrap-sexp
sp-unwrap-sexp
toggle-char-case
upcase-region

File diff suppressed because it is too large Load Diff

10678
keyfreq Normal file

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1,75 @@
# git show :stage:filename
# common ancestor: 1
# HEAD: 2
# MERGE_HEAD: 3
import re
from subprocess import Popen, PIPE
import sys
BASE = 1
HEAD = 2
MERGE_HEAD = 3
FINAL = 0
outputs = {}
for stage in (BASE, HEAD, MERGE_HEAD):
p = Popen(['git', 'show', f':{stage}:keyfreq'], stdout=PIPE, stderr=PIPE)
output, err = p.communicate()
if p.returncode:
print(output)
sys.exit(1)
outputs[stage] = {}
output = output.decode('utf-8')[1:-1].split('\n')
for line in output:
line = line.strip()
if not line:
continue
if '"' in line:
continue
m = re.match(r'^\(\(([^) ]+) .\ ([^) ]+)\) \. ([0-9]+)\)$', line)
if not m:
raise ValueError(f'Invalid cons cell: {line}')
mode, command, count = m.groups()
count = int(count)
outputs[stage].setdefault(mode, {})
outputs[stage][mode][command] = count
outputs[FINAL] = {}
for stage in (BASE, HEAD, MERGE_HEAD):
for mode in outputs[stage]:
outputs[FINAL][mode] = {}
for command, count in outputs[stage][mode].items():
base_mode = outputs[BASE].get(mode, {})
base_count = base_mode.get(command, 0)
this_count = outputs[stage][mode][command]
outputs[FINAL][mode].setdefault(command, base_count)
if stage != BASE:
outputs[FINAL][mode][command] += this_count - base_count
output = '('
for mode in outputs[FINAL]:
for command, count in outputs[FINAL][mode].items():
output += f'(({mode} . {command}) . {count})\n'
output = output[:-1] + ')'
with open('keyfreq', 'w') as f:
f.write(output)

View File

@ -0,0 +1,20 @@
# Installing
Add the following hook to your emacs conf:
```elisp
(add-hook 'eshell-load-hook 'nyan-prompt-enable)
```
# Why
James J Porter showed me nyan-mode. I love nyan cat but hate scroll bars. I wanted to bring nyan-cat to my emacs so I found a middle way.
# How could you enhance the awesomeness.
* Make nyan-cat move!
* Make it a multline prompt with the rainbow taking up the folder space
* Unite with nyan-mode and see where else can we stick nyan cat in?
# License
Copying is an act of Love, please copy.
# Author
Javier Olaechea (<pirata@gmail.com>), 2013.

View File

@ -0,0 +1,167 @@
/* XPM */
static char * nyan_xpm[] = {
"25 15 149 2",
" c None",
". c #522244",
"+ c #3F1E31",
"@ c #403326",
"# c #2C2F32",
"$ c #002D5B",
"% c #003366",
"& c #BF1119",
"* c #7C0B10",
"= c #947256",
"- c #FFCC99",
"; c #FFBBBB",
"> c #FFB3CC",
", c #FFC7A2",
"' c #D8AD82",
") c #3A3C3E",
"! c #F52A02",
"~ c #490C00",
"{ c #F0C090",
"] c #FFBCB9",
"^ c #FF9DF7",
"/ c #FF99FF",
"( c #FF5FC5",
"_ c #FF6BD1",
": c #FF8DF3",
"< c #FFA6E6",
"[ c #745D46",
"} c #002850",
"| c #FC7800",
"1 c #4C2400",
"2 c #F0B6A2",
"3 c #FF66CC",
"4 c #FF92F8",
"5 c #D882D8",
"6 c #C576C5",
"7 c #FF8AF0",
"8 c #FF94FA",
"9 c #FFA8E0",
"0 c #02284E",
"a c #FBA500",
"b c #4C3100",
"c c #D17DD1",
"d c #614C61",
"e c #514C51",
"f c #AA66AA",
"g c #FF79DF",
"h c #FF90F6",
"i c #001428",
"j c #494949",
"k c #1F265A",
"l c #F0D300",
"m c #483F00",
"n c #FF68CE",
"o c #A261A2",
"p c #5D5D5D",
"q c #969696",
"r c #AE68AE",
"s c #999999",
"t c #00264C",
"u c #6F7509",
"v c #262626",
"w c #1D1F00",
"x c #868F00",
"y c #292B00",
"z c #FF86EC",
"A c #575757",
"B c #2B2525",
"C c #646464",
"D c #131313",
"E c #727272",
"F c #4F4F4F",
"G c #2A2A2A",
"H c #000000",
"I c #FF72D8",
"J c #F069C9",
"K c #6D4C6D",
"L c #7B7B7B",
"M c #122539",
"N c #20980E",
"O c #236119",
"P c #242424",
"Q c #FF80E6",
"R c #E073CD",
"S c #383838",
"T c #A0A0A0",
"U c #A6A6A6",
"V c #686868",
"W c #CFCFCF",
"X c #464646",
"Y c #20D15C",
"Z c #1AAF4D",
"` c #083417",
" . c #020F06",
".. c #FF8FF5",
"+. c #E086E0",
"@. c #A89999",
"#. c #A68F8F",
"$. c #20262C",
"%. c #666666",
"&. c #4C4646",
"*. c #B09999",
"=. c #0EA7CB",
"-. c #04323D",
";. c #F0BB99",
">. c #FF77DD",
",. c #FF85EB",
"'. c #D79999",
"). c #F69999",
"!. c #7F7F7F",
"~. c #5F5F5F",
"{. c #B59999",
"]. c #FF9999",
"^. c #3E2525",
"/. c #1E80F7",
"(. c #1354A2",
"_. c #020912",
":. c #FF95D5",
"<. c #FF97FD",
"[. c #F794F7",
"}. c #885788",
"|. c #7B6C6C",
"1. c #161616",
"2. c #232323",
"3. c #0C0C0C",
"4. c #070B0F",
"5. c #0F2643",
"6. c #5247F7",
"7. c #39329C",
"8. c #251E17",
"9. c #BF9973",
"0. c #4B3C2D",
"a. c #616161",
"b. c #737373",
"c. c #54575A",
"d. c #001D3A",
"e. c #5536D9",
"f. c #222126",
"g. c #241856",
"h. c #191919",
"i. c #001932",
"j. c #000A14",
"k. c #414141",
"l. c #333333",
"m. c #000E1D",
"n. c #002040",
"o. c #263498",
"p. c #08090C",
"q. c #23308F",
"r. c #002B56",
". . . . . . + @ @ @ @ @ @ @ @ @ @ @ @ # $ % % % % ",
"& & & & & * = - ; > > > > > > > > > , ' ) $ % % % ",
"! ! ! ! ! ~ { ] ^ / / / ( / _ : / / < - [ } % % % ",
"| | | | | 1 2 / 3 4 / / / / 5 6 ^ 7 8 9 [ } 0 $ % ",
"a a a a a b 2 / / / / / / c d e f g h 9 [ i j k $ ",
"l l l l l m 2 / / / / n h o p q p r ^ 9 [ p s j t ",
"u v v w x y 2 / / z / / / o p s s A B B C s s j t ",
"D E s F G H 2 / / I / / J K L s s s s s s s s E M ",
"N O v v j P 2 g Q / / / R S s T U V s s s W X s v ",
"Y Y Y Z ` .2 / / / ..h +.S @.#.$.V s L %.) &.*.B ",
"=.=.=.=.=.-.;.9 >.8 ,.z +.S '.).= !.q C s ~.{.].^.",
"/./././.(._.{ , :.<./ / [.}.|.*.C 1.2.3.$.4.s |.5.",
"6.6.6.7.v v 8.9.9.9.9.9.9.9.0.a.E E b.b.b.b.c.d.% ",
"e.e.e.f.s C g.h.F 4.i.i.i.i.j.k.l.m._.F v i n.% % ",
"o.o.o.p.v k q.k v _.% % % % r.$.h.d.0 v D } % % % "};

View File

@ -0,0 +1,60 @@
;;; nyan-prompt.el --- Nyan Cat on the eshell prompt.
;; Author: Javier "PuercoPop" Olaechea <pirata@gmail.com>
;; URL: http://github.com/PuercoPop/nyan-prompt
;; Version: 0.2.0
;; Keywords: nyan, cat, lulz, eshell, rainbow
;; Dependencies ((rx 0))
;;; Commentary:
;; Usage: (add-hook 'eshell-load-hook 'nyan-prompt-enable)
;; Inspired by from Jacek "TeMPOraL" Zlydach nyan-mode, to make Porter happy.
;; Copying is an act of love, please copy. ♡
;; The xpm taken awesome nyan-mode
;;; Code:
(require 'rx)
(defconst nyan-prompt-dir (file-name-directory
(or load-file-name buffer-file-name)))
(defconst nyan-prompt-nyan-cat-image
(create-image (concat nyan-prompt-dir "img/nyan.xpm")
'xpm nil :ascent 'center))
(defconst nyan-prompt-nyan-cat-emoticon "~=[,,_,,]:3"
"ASCII art representing the nyan-cat.")
(defconst nyan-prompt-nyan-cat-string
(propertize nyan-prompt-nyan-cat-emoticon
'display nyan-prompt-nyan-cat-image))
(defvar nyan-prompt-original-prompt nil
"The eshell prompt function before enabling nyan-prompt")
(defvar nyan-prompt-enabled nil
"t if nyan-prompt is enabled")
(defun eshell-nyan-prompt ()
(concat nyan-prompt-nyan-cat-string " " (funcall nyan-prompt-original-prompt)))
(defun nyan-prompt-disable ()
(when nyan-prompt-enabled
(setq nyan-prompt-enabled nil
eshell-prompt-function nyan-prompt-original-prompt)))
;;;###autoload
(defun nyan-prompt-enable ()
(when (not nyan-prompt-enabled)
(setq nyan-prompt-enabled t
nyan-prompt-original-prompt eshell-prompt-function
eshell-prompt-function 'eshell-nyan-prompt)))
(provide 'nyan-prompt)
;;; nyan-prompt.el ends here