Compare commits

...

913 Commits

Author SHA1 Message Date
contrapunctus babf615646 Define test command for Common Lisp projects
I tried `projectile-test-project`, but it only accepts shell commands,
whereas I wanted a faster way to run tests from the SLIME REPL.
2022-11-20 23:51:17 +05:30
contrapunctus 76d472b0e0 Use more efficient key for Org checkbox 2022-11-18 23:30:48 +05:30
contrapunctus ce435b0993 Add template for initialize-instance 2022-11-18 23:30:28 +05:30
contrapunctus 3e04ea14bc Add tempel-insert keybinding 2022-11-14 02:16:17 +05:30
contrapunctus e71ce0b7e9 Add dired-sidebar configuration 2022-11-13 23:09:47 +05:30
contrapunctus 058fe309b1 Add keybinding for imenus 2022-11-13 22:58:07 +05:30
contrapunctus 1d2ad549a7 Remove unused key 2022-11-13 22:57:56 +05:30
contrapunctus 144f5ec579 Define right-hand keys for window operations 2022-11-13 22:57:39 +05:30
contrapunctus e456bec299 Add newline to print debug template 2022-11-07 11:55:56 +05:30
contrapunctus 331d8e9297 Add :initform and define-presentation-method templates 2022-11-07 11:55:43 +05:30
contrapunctus fb9da3127e Add SLIME inspector keybinding 2022-11-07 11:54:54 +05:30
contrapunctus bc396c2457 Add Hydra keybinding for org-toggle-checkbox 2022-11-04 14:04:36 +05:30
contrapunctus e88aa9065a Add bookmarks file
...as protection against corruption.
2022-11-02 10:33:01 +05:30
contrapunctus 4558eff538 Remove argument from print debugging template
Most uses don't have any arguments to `format`.
2022-10-26 01:17:03 +05:30
contrapunctus e276088bdd Remove parens from :documentation expansion
This makes it useful for slot definitions as well. I can always
insert (|) quickly thanks to my kmonad config, so expanding
to (:documentation "...") forms remain nearly as easy as before.
2022-10-26 01:15:23 +05:30
contrapunctus c07b75be77 Add LaTeX, Texinfo, and Org templates 2022-10-16 15:01:28 +05:30
contrapunctus 3dd83b56bd Quit template when reaching arguments
Much of the time, these print debugging calls don't have arguments,
and the argument field just becomes a hassle to delete.
2022-10-16 14:59:58 +05:30
contrapunctus d4dd016038 Record locations of walk/run tracks 2022-10-12 23:06:19 +05:30
contrapunctus bd2cef2768 Use external programs for images (e.g. WebP) 2022-10-08 15:21:11 +05:30
contrapunctus 8e71ce4132 Disable automatic space insertion after colons 2022-09-22 15:05:22 +05:30
contrapunctus e8e6d30973 Add Quicklisp update template 2022-08-25 17:52:02 +05:30
contrapunctus 0b2c730329 Use MPV for EMMS 2022-08-21 16:41:52 +05:30
contrapunctus e0e48a0f6d Set larger threshold for file size warnings 2022-08-21 16:40:19 +05:30
contrapunctus a04e8cbeeb Define local-nicknames template 2022-08-16 12:52:09 +05:30
contrapunctus 602f0cb5f3 Correct Markor directory paths 2022-08-16 12:51:35 +05:30
contrapunctus d9a464fbb3 Add templates for defpackage and default-initargs 2022-08-10 20:23:29 +05:30
contrapunctus 67dec47813 Add macroexpand keybinding 2022-08-02 00:11:31 +05:30
contrapunctus 8493fa51a3 Rename comment template 2022-08-01 09:25:47 +05:30
contrapunctus 8742f36642 Define documentation template 2022-08-01 09:19:19 +05:30
contrapunctus a6aa231074 Add :import-from template 2022-07-31 10:21:45 +05:30
contrapunctus 1cc5f314c6 Don't add a newline 2022-07-31 10:21:27 +05:30
contrapunctus ee9d074d06 Move Evil configuration to init.org 2022-07-26 09:41:37 +05:30
contrapunctus 5a811e25c0 Add Lisp as source block language 2022-07-25 09:39:05 +05:30
contrapunctus 8a24fef78c Move window-numbering to its own section 2022-07-22 00:40:26 +05:30
contrapunctus 88702cd3b9 Make separate template for class slots 2022-07-20 23:14:20 +05:30
contrapunctus 3763330305 Add print debugging template 2022-07-20 23:13:57 +05:30
contrapunctus bd5c2c6681 Prefix slot names with % 2022-07-18 20:13:40 +05:30
contrapunctus 56ffef857f Correct use-package syntax 2022-07-18 20:13:29 +05:30
contrapunctus 063e5561bf Add templates for Common Lisp reader conditionals 2022-07-18 20:12:46 +05:30
contrapunctus c18c1ad5e5 Use eww bookmarks 2022-07-12 12:22:58 +05:30
contrapunctus 154294c5f2 Bind ? to lispy-describe-inline 2022-07-08 01:13:21 +05:30
contrapunctus d3416185e2 Update Lisp templates 2022-07-05 13:29:23 +05:30
contrapunctus 6da9e69eb0 Ask for date for exercise data 2022-06-24 12:25:23 +05:30
contrapunctus ec78217480 Update cooking presets 2022-06-23 01:10:55 +05:30
contrapunctus 3f73f871e6 Fix incorrect key bug 2022-06-20 20:54:03 +05:30
contrapunctus 542e859b8a Improve editing experience and success message 2022-06-20 20:46:42 +05:30
contrapunctus 5d8562e43d Fix void-variable error 2022-06-20 20:41:41 +05:30
contrapunctus 3faf36b9e3 Copy sports data to kill ring 2022-06-19 22:31:45 +05:30
contrapunctus 3d19def8f7 Calculate distance covered by GPX trace 2022-06-17 14:23:36 +05:30
contrapunctus 965dea65c0 Add support for past dates 2022-06-17 00:20:27 +05:30
contrapunctus 716f2f0373 Add extra keybinding for buffer switching
Thanks to kmonad, my left Alt is an extra RET, and one which involves
less lateral motion at that.
2022-06-10 20:18:03 +05:30
contrapunctus d8dd88abf6 Add keybinding to open the CLIM User Guide 2022-06-10 20:14:10 +05:30
contrapunctus 9a6a5af1ce Add new bindings
My right Alt sends Backspace when tapped, thanks to kmonad. Backspace
is unbound in boon-command-map, making it ideal to use for quick
buffer switching instead of the existing `m m` Hydra.
2022-06-10 18:52:14 +05:30
contrapunctus e2b77f733c Use raise-some instead of raise 2022-06-08 15:02:55 +05:30
contrapunctus bfa14d2bff Use imenus for Common Lisp
imenu is hierarchical; imenus is flat
2022-06-08 15:02:03 +05:30
contrapunctus c5ea259ee7 Make Boon-like bindings for chronometrist-details range commands 2022-06-04 23:20:14 +05:30
contrapunctus fedd63991a Define my-chronometrist-insert-exercise-data
As a consequence, refactor my-copy-gpx-timestamps into
my-get-gpx-timestamps, which just returns the timestamps rather than
copying them.
2022-06-04 23:20:04 +05:30
contrapunctus 93555e80de Remove unnecessary make-local-variable 2022-05-31 12:17:33 +05:30
contrapunctus 165d57ce1b Disable Quelpa updates if not connected to the Internet 2022-05-31 12:15:34 +05:30
contrapunctus 36a81c2797 Update key-value presets for Cooking 2022-05-31 10:22:53 +05:30
contrapunctus 821d1bf726 Disable feather.el
It hasn't seen new commits for a few years...
2022-05-30 21:49:40 +05:30
contrapunctus 5fe8404c96 my-org-fix-newlines - leave point on next heading 2022-05-30 04:07:49 +05:30
contrapunctus 2a62bc002a my-org-fix-newlines - move past property drawers 2022-05-30 04:07:34 +05:30
contrapunctus 4e4f5007e9 my-org-fix-newlines - support point before first heading 2022-05-30 04:06:04 +05:30
contrapunctus 98803acc44 Remove task 2022-05-30 04:03:22 +05:30
contrapunctus b3ba6fa0b7 Fix error when sending email 2022-05-26 04:23:43 +05:30
contrapunctus efda63da09 Add Python config 2022-05-24 23:04:23 +05:30
contrapunctus bc60d3a17d Update paths 2022-05-21 10:27:44 +05:30
contrapunctus e12093d610 Change cp/ prefix to my- 2022-05-15 23:44:50 +05:30
contrapunctus d14d465446 Update paths to reflect rename 2022-05-15 21:33:59 +05:30
contrapunctus ffafda8b4e Decrease ibuffer-sidebar width 2022-05-01 10:02:08 +05:30
contrapunctus d9d2a773b3 Set default ibuffer format 2022-05-01 10:00:46 +05:30
contrapunctus 36e750c5ba Add describe-face keybinding 2022-04-30 21:33:39 +05:30
contrapunctus 300bb816c8 Add ibuffer-sidebar, make ibuffer display flat list of buffers 2022-04-30 21:32:43 +05:30
contrapunctus 805ad94865 Generate CUSTOM_IDs 2022-04-27 22:14:23 +05:30
contrapunctus 0cc6325f12 Add [] to Lisp syntax for CLSQL 2022-04-27 21:32:19 +05:30
contrapunctus 3fb9362383 Use auto-id package 2022-04-27 21:31:45 +05:30
contrapunctus 82252dbb27 Add term configuration 2022-04-27 21:31:10 +05:30
contrapunctus 82fb4d6cca Reformat code 2022-04-27 21:30:10 +05:30
contrapunctus 62dd826b39 my-find-file* - fix error 2022-04-27 21:26:30 +05:30
contrapunctus 1905951cab Prevent error when there is no new OSM data to insert 2022-04-27 21:26:04 +05:30
contrapunctus d4fafb46e7 Define slime-inspector bindings 2022-04-19 09:10:54 +05:30
contrapunctus 4587bada07 Save SQL input history 2022-04-18 07:47:31 +05:30
contrapunctus aa5e499843 undo-tree: Disable persistent history 2022-04-15 17:15:58 +05:30
contrapunctus e6e47744b5 Store all undo-tree history files in ~/.emacs.d/undo-tree/ 2022-04-15 13:08:28 +05:30
contrapunctus d2a7518b5d Move print length settings 2022-04-13 15:56:01 +05:30
contrapunctus 92a9640f27 Org: Automatically add CUSTOM_ID (WIP) 2022-04-13 15:55:14 +05:30
contrapunctus 255983c9fe Move Emacs-wide mail configuration to its own section 2022-03-31 13:21:58 +05:30
contrapunctus a4e02eda2f Update encrypted Chronometrist configuration 2022-03-31 13:20:36 +05:30
contrapunctus c4b8caf520 Move audio output options to mpv.conf 2022-03-16 10:25:15 +05:30
contrapunctus ce729a0187 Don't shadow scrolling keys when point is on a link 2022-03-16 10:23:53 +05:30
contrapunctus f6b5a225de Add org-emms 2022-03-10 22:40:55 +05:30
contrapunctus a63c2ff7dc Add keys for I with umlaut 2022-03-08 17:03:48 +05:30
contrapunctus 8644811ecb Create defclass template; update defvar template 2022-03-08 17:02:47 +05:30
contrapunctus d404225e88 lambda template - skip without input if no arguments 2022-03-08 17:01:39 +05:30
contrapunctus bbfa909491 Try different completion-style order 2022-03-03 15:42:19 +05:30
contrapunctus 5917720e6b Re-enable use of JACK for EMMS/MPV 2022-03-03 15:42:03 +05:30
contrapunctus bcde1f070c Bind imenu for Common Lisp buffers 2022-03-03 15:41:44 +05:30
contrapunctus bf08e6d5b2 Add SQL CREATE TABLE template 2022-02-25 00:48:27 +05:30
contrapunctus 49acc72827 Make defcustom template definition multiline 2022-02-24 21:27:19 +05:30
contrapunctus 8552780d80 Make arguments optional in defun template 2022-02-24 21:27:05 +05:30
contrapunctus 5a4afe9579 Add lambda template for SLIME REPL 2022-02-24 21:25:14 +05:30
contrapunctus 2a929c87c7 Do not hide eldoc on backspace 2022-02-23 08:09:05 +05:30
contrapunctus 32d7a5eafd Do not warn if file is <20M 2022-02-23 08:08:24 +05:30
contrapunctus f7f91a2275 Add with-slots template, move elisp templates to lisp-mode 2022-02-23 08:06:47 +05:30
contrapunctus 5a0afc2c8f Tweak Chronometrist query output padding 2022-02-21 21:54:47 +05:30
contrapunctus daf0a270af Add binding for Org export block 2022-02-21 21:54:02 +05:30
contrapunctus 1a94e00712 Remove org-crypt; use org-superstar 2022-02-21 21:53:39 +05:30
contrapunctus d966e0868f Customize chronometrist-key-value-alist 2022-02-20 21:03:03 +05:30
contrapunctus a16736ee43 Move private configuration into encrypted file 2022-02-20 11:15:35 +05:30
contrapunctus e55008c430 Partially encrypt configuration
It's still in the Git history for the time being, but I'd rather not
make it /too/ accessible.
2022-02-19 15:12:16 +05:30
contrapunctus 9871aace1a Create headings in OSM/Chronometrist config code 2022-02-19 15:05:08 +05:30
contrapunctus 13edd13ba5 Add templates for slime-repl-mode 2022-02-19 03:05:32 +05:30
contrapunctus 49ac8e1e5d Change init-org.el -> init.el; remove ELC-related targets 2022-02-18 20:52:59 +05:30
contrapunctus 9d0d04cee4 Enable Company idle suggestions in text modes 2022-02-18 20:51:30 +05:30
contrapunctus 80a0460fc3 Reindent values 2022-02-17 19:40:42 +05:30
contrapunctus 940d829bc6 Add bindings for occur 2022-02-17 19:40:42 +05:30
contrapunctus 4c68fd40fc Move most font config to User Interface 2022-02-17 19:40:42 +05:30
contrapunctus 24a37e6e59 Try doom-modeline, disable other mode line packages 2022-02-17 19:40:36 +05:30
contrapunctus d6940b2da9 Use custom function for new email alert 2022-02-17 14:04:46 +05:30
contrapunctus 500b983242 Enable lexical binding 2022-02-17 13:29:08 +05:30
contrapunctus 84d468e7bc Move font size setting to after-make-frame-functions 2022-02-17 13:28:24 +05:30
contrapunctus 6cedc1c67d Define use-package template 2022-02-16 18:57:02 +05:30
contrapunctus b737a0b543 Use Quelpa for packages installed from source 2022-02-16 18:56:46 +05:30
contrapunctus a3622b1f99 Increase font size 2022-02-16 02:11:33 +05:30
contrapunctus 29bc996efa Bind imenu in Elisp buffers 2022-02-16 02:10:35 +05:30
contrapunctus ec4bf47843 Move up Chronometrist main config 2022-02-16 02:09:56 +05:30
contrapunctus 0056d41153 Disable Gnus 2022-02-16 02:09:37 +05:30
contrapunctus fd992f16ce Enable mu4e-use-fancy-chars 2022-02-16 02:09:22 +05:30
contrapunctus 4256ae0e8c Change mu4e binding 2022-02-16 02:07:31 +05:30
contrapunctus 5f5e201ec2 Add isearch history bindings 2022-02-15 01:56:19 +05:30
contrapunctus 9f583f7616 Preserve clipboard in kill ring
Thanks http://pragmaticemacs.com/emacs/add-the-system-clipboard-to-the-emacs-kill-ring/
2022-02-15 01:54:30 +05:30
contrapunctus f1931a7768 Add point-min and point-max templates 2022-02-14 21:48:56 +05:30
contrapunctus 3b97dbdcb0 Disable yasnippet, try Tempel 2022-02-14 21:47:14 +05:30
contrapunctus e95ff9421e Run mu4e on startup 2022-02-13 18:35:31 +05:30
contrapunctus 0bba0c8aa3 Add code to debug mu4e/mu4e-alert 2022-02-13 17:51:30 +05:30
contrapunctus c61fce7b3d Prettify yas hooks 2022-02-13 17:50:16 +05:30
contrapunctus 7ff58a141a Fix void-function error 2022-02-13 17:49:58 +05:30
contrapunctus 9db245093d Remove mu4e-conversation and desktop
mu4e-conversation is broken with current mu4e and also unmaintained

desktop pestered me with prompts on nearly every startup and exit;
besides, I was only using it for history, which savehist mode does
just fine. (and unobstrusively at that)
2022-02-13 17:48:16 +05:30
contrapunctus 9a2675f6fb Have alerts stick around longer 2022-02-12 20:59:26 +05:30
contrapunctus 1f349676eb Use consult-org-heading instead of imenus for Org buffers 2022-02-12 20:43:10 +05:30
contrapunctus 922fd20f3b Use company-emoji's setup code 2022-02-12 17:59:58 +05:30
contrapunctus b60870fd37 Align commands 2022-02-12 17:59:30 +05:30
contrapunctus 4d434a54f8 Fix "Did you start mu4e?" error
Doh 🤦
2022-02-12 17:49:56 +05:30
contrapunctus ce55d120d9 Add pdf-view bindings 2022-02-12 17:39:36 +05:30
contrapunctus 825613f6c6 Fix whitespace 2022-02-12 17:38:55 +05:30
contrapunctus 1ee8c8adb7 Update to reflect rename 2022-02-12 17:38:27 +05:30
contrapunctus 8e59fc7d5a Disable desktop.el
Inhibit startup screen because Boon is not enabled there, meaning I
can't use my entry-point `m` key (my-dispatch-hydra) to navigate from
that buffer.
2022-02-12 17:25:55 +05:30
contrapunctus e7aa11ea10 Try stock org-open-at-point 2022-02-12 16:09:02 +05:30
contrapunctus 060c6a91f8 Add single quote bindings 2022-02-12 16:08:44 +05:30
contrapunctus 9013637999 Add compile bindings to TeX hydra 2022-02-12 16:08:30 +05:30
contrapunctus 171bd11cef Fix XMPP link export for LaTeX 2022-02-12 16:08:02 +05:30
contrapunctus 2962f8b669 Add Boon keybindings for grep 2022-02-12 16:07:30 +05:30
contrapunctus e49fe07fc6 Use patched version of mu4e-alert 2022-02-12 16:04:04 +05:30
contrapunctus 06704bee4e Use Quelpa 2022-02-12 16:03:40 +05:30
contrapunctus fa3c501408 Update mu4e keys 2022-02-12 09:02:25 +05:30
contrapunctus b302052dbb Add xref support for LaTeX 2022-02-11 15:34:27 +05:30
contrapunctus 8a267574ab Fix color disable code 2022-02-11 15:23:28 +05:30
contrapunctus 7e4fdaf93d Remove unmatched #+END_SRC 2022-02-11 15:23:03 +05:30
contrapunctus 3e6eaa7524 Correct heading name 2022-02-11 15:23:03 +05:30
contrapunctus 095460670c Use chronometrist-third 2022-02-11 15:23:03 +05:30
contrapunctus 3bd9335a76 Open mu4e headers view by default 2022-02-11 13:51:09 +05:30
contrapunctus 4da3d07eb4 Create my-mu4e-mkdir 2022-02-11 13:50:57 +05:30
contrapunctus fb06810c66 Add mu4e keybindings 2022-02-11 13:40:40 +05:30
contrapunctus b461d1e41a Disable colors when viewing HTML mail
The CSS clashes horribly with my Emacs theme.
2022-02-11 13:03:19 +05:30
contrapunctus 3d74494a5d Add defcustom snippet 2022-02-11 13:03:04 +05:30
contrapunctus 6c154cda40 Inhibit error "[mu4e] root maildir unknown; did you start mu4e?" 2022-02-11 12:48:48 +05:30
contrapunctus 51ec6352a1 Add mu4e extensions 2022-02-11 11:23:51 +05:30
contrapunctus 9e85e600b6 Update treemacs keys 2022-02-09 22:03:05 +05:30
contrapunctus 261184be43 Prettify Company hooks 2022-02-09 22:02:39 +05:30
contrapunctus a92e786331 Swap Elpher and EMMS keys 2022-02-09 22:02:11 +05:30
contrapunctus 0a047c8d7a Add defhydra and in-package snippets 2022-02-09 16:42:00 +05:30
contrapunctus db13c38f17 Change name of snippets to override existing snippets 2022-02-09 16:41:34 +05:30
contrapunctus 182c0f01a3 Fix overriding of I keybinding 2022-02-09 16:39:47 +05:30
contrapunctus a60aeaa915 Do not sort consult-line candidates 2022-02-08 13:27:14 +05:30
contrapunctus 8d141c9867 Scroll Vertico candidates with PgUp/PgDn 2022-02-08 13:25:16 +05:30
contrapunctus 4f36d525d5 Enable Company in tex-mode 2022-02-08 13:24:14 +05:30
contrapunctus eef145c3cb Configure mu4e keys 2022-02-08 13:23:55 +05:30
contrapunctus 98b054e240 Show verbose mbsync output 2022-02-08 13:23:41 +05:30
contrapunctus c17c35cbaf Use vertico for mu4e completion 2022-02-08 13:23:23 +05:30
contrapunctus aedcc4600f Add hydra head for mu4e 2022-02-08 13:23:03 +05:30
contrapunctus f7a6c1e30a Don't run recentf-cleanup on mode enable; auto-backup recentf file 2022-02-07 00:04:32 +05:30
contrapunctus d419b9a901 Add mu4e configuration 2022-02-07 00:04:14 +05:30
contrapunctus 36759d7dfe Add help hydra to comint hydra 2022-02-06 17:39:30 +05:30
contrapunctus 2eef05cb80 Create helper command my-org-fix-newlines 2022-02-06 17:38:19 +05:30
contrapunctus a3577588bb Update frameset 2022-02-06 17:38:07 +05:30
contrapunctus 9cfc2a433c Fix esxml-query error 2022-02-06 17:37:10 +05:30
contrapunctus 68d7aee35c Refactor and tweak output of Chronometrist query 2022-02-06 17:36:43 +05:30
contrapunctus 5fd4be9f85 Move bookmark and recentf config to Completion
Use bookmark's own autosave mechanism
2022-01-31 15:56:47 +05:30
contrapunctus 3021215afa Disable automatic recentf cleanup 2022-01-31 15:54:33 +05:30
contrapunctus 2b26a782b7 Save bookmarks on exit and when idle 2022-01-31 15:54:15 +05:30
contrapunctus 6af600db1b Enable mouse control of completion 2022-01-27 23:28:14 +05:30
contrapunctus bd57f0d03e Disable sorting for chronometrist-toggle-task-button 2022-01-27 23:27:59 +05:30
contrapunctus 93d75f0b2a Enable yasnippet in shells and REPLs 2022-01-27 23:27:31 +05:30
contrapunctus 5b5b2fd41b Write command my-copy-gpx-timestamps 2022-01-27 23:26:41 +05:30
contrapunctus f9ae684967 Add org-global-cycle binding 2022-01-27 23:26:03 +05:30
contrapunctus 05ea748538 Split Org config into multiple blocks; remove unused code; update prefixes 2022-01-25 14:12:19 +05:30
contrapunctus 5b1c670b1b Add comint navigation hydra 2022-01-24 20:58:51 +05:30
contrapunctus d348a2b4cc Don't use Vertico's sorting for Chronometrist prompts 2022-01-24 20:38:27 +05:30
contrapunctus e5827408e1 Correct cl-launch script detection 2022-01-24 20:38:03 +05:30
contrapunctus 6d82212760 Defer loading of ox-texinfo 2022-01-24 14:33:59 +05:30
contrapunctus 15080c1372 Disable explain-pause-mode 2022-01-24 14:33:52 +05:30
contrapunctus 6bfebe5b51 Use lisp-mode for cl-launch scripts 2022-01-24 00:43:07 +05:30
contrapunctus ea55857cd3 Add snippets 2022-01-24 00:32:22 +05:30
contrapunctus edf7b828d5 Add personal directory to load-path 2022-01-24 00:27:56 +05:30
contrapunctus 24d837f6ca Don't enable visual-fill-column-mode in org-mode buffers
It's sometimes a bother, and it's more difficult to disable it than to
enable it.
2022-01-24 00:26:29 +05:30
contrapunctus 5c8989bfe2 Add keybinding for org-global-cycle 2022-01-22 21:48:55 +05:30
contrapunctus 64a18add12 Use shorter package prefix for personal definition 2022-01-22 20:11:36 +05:30
contrapunctus 2876f4ed0f Add source comment 2022-01-22 20:11:11 +05:30
contrapunctus dc6a05440e Disable automatic completion popups 2022-01-22 20:11:04 +05:30
contrapunctus dc4095c505 Bind TAB to indent and completion 2022-01-21 23:46:48 +05:30
contrapunctus fad24f9910 Prevent yas-minor-mode from being enabled in EMMS playlist buffers 2022-01-21 23:46:10 +05:30
contrapunctus 5c02744cc0 Swap imenus and save-buffer bindings 2022-01-21 21:47:32 +05:30
contrapunctus b79ef3edaa Ask for language when my-org-src-default-lang is nil 2022-01-21 13:58:37 +05:30
contrapunctus 22e297ba0f Recenter after selecting imenu entry 2022-01-21 00:17:26 +05:30
contrapunctus 7aedd2b6fd Add keybindings for isearch-repeat-* 2022-01-20 22:41:55 +05:30
contrapunctus 081f338b50 Disable automatic heading timestamps
They're undesired in Org literate programs; I'll use this in file
local variables instead.
2022-01-20 12:11:57 +05:30
contrapunctus b713fe1efa Fix error when region is inactive 2022-01-20 11:51:21 +05:30
contrapunctus e7f90c1b0d Address use-package-lint warnings 2022-01-20 00:26:21 +05:30
contrapunctus 96f033220f Cycle through completion results 2022-01-20 00:21:30 +05:30
contrapunctus a64cbe5310 Change keybind to prevent snippet expansion when completion is desired 2022-01-20 00:09:15 +05:30
contrapunctus 2662ba9489 Add Hydra head for slime-repl-set-package 2022-01-19 21:51:42 +05:30
contrapunctus 4d83ee32c2 Bind backspace and C-backspace to vertico-directory-delete-char/word 2022-01-19 16:07:54 +05:30
contrapunctus 7e5f058fae Enable undo-tree-mode in wdired-mode 2022-01-19 15:31:39 +05:30
contrapunctus a95a7ec521 Change binding for Org navigation 2022-01-19 01:28:26 +05:30
contrapunctus 60b79410fe Fix newlines 2022-01-19 01:28:13 +05:30
contrapunctus 065a89234a Enable keyfreq 2022-01-19 01:22:31 +05:30
contrapunctus 61668fbe8b Create additional Hydra head for save-buffer
I barely use text scale adjustments, so it can be moved to
farther-away keys.
2022-01-18 19:43:20 +05:30
contrapunctus ad8ee289c4 Use common-lisp-snippets 2022-01-17 18:32:01 +05:30
contrapunctus c2de0faffc Enable yasnippet from any programming mode 2022-01-17 18:31:20 +05:30
contrapunctus 74995b3a7e Use asdf-mode 2022-01-17 18:31:04 +05:30
contrapunctus 1dce14455f Change literate-elisp form 2022-01-17 18:27:50 +05:30
contrapunctus 02315b1b8b Add hydra head to prompt for source language 2022-01-17 12:22:51 +05:30
contrapunctus 0cbfa4c24c Remove language-specific source block hydra heads 2022-01-17 12:03:37 +05:30
contrapunctus 6d85a1d42e Add tags 2022-01-17 11:31:00 +05:30
contrapunctus d65bd41cac Fix undesired literate-elisp-load ing of block 2022-01-17 11:29:30 +05:30
contrapunctus b9fd71965c Load with literate-elisp when opened 2022-01-17 11:28:30 +05:30
contrapunctus 92fca31eca Open TeX PDFs using pdf-tools 2022-01-16 19:48:10 +05:30
contrapunctus ca34e0c509 Add isearch keybindings; keep Org from indenting source blocks
Fix error about org-link-set-parameters not being defined
2022-01-16 19:45:27 +05:30
contrapunctus 9054ce9071 Bind consult-mark and consult-global-mark 2022-01-16 16:08:41 +05:30
contrapunctus 59fbab31e2 Enable use-package statistics 2022-01-16 16:06:34 +05:30
contrapunctus df7ee7d684 Move ido-mini to Navigation 2022-01-16 15:27:22 +05:30
contrapunctus 38077b5313 Make section for text-mode bindings 2022-01-16 14:05:47 +05:30
contrapunctus 952012182c Remove old function-key bindings 2022-01-16 14:02:15 +05:30
contrapunctus bfeeef02ce Add keybinding for consult-yank-pop 2022-01-16 13:58:17 +05:30
contrapunctus 2bd9910080 Enable EXWM helpers 2022-01-16 13:58:17 +05:30
contrapunctus e855eeca3d Add Boon layout polemic 😼 2022-01-16 13:58:10 +05:30
contrapunctus 2244f39f51 Mark ido-mini as disabled 2022-01-16 13:57:26 +05:30
contrapunctus 210aa37df8 Add tags to headings 2022-01-16 13:57:26 +05:30
contrapunctus 2f19538913 Move global and built-in mode keybindings to Emacs section, cleanup 2022-01-16 13:57:26 +05:30
contrapunctus 73d9959a52 Reorganize 2022-01-16 13:57:26 +05:30
contrapunctus dc738b849b Bind C-. to end-of-line (QWERTY C-e) 2022-01-16 13:57:26 +05:30
contrapunctus f011b31c56 Use default value of orderless-component-separator 2022-01-16 13:57:26 +05:30
contrapunctus 15a2d0a475 Replace ido-mini with consult-buffer 2022-01-16 13:57:26 +05:30
contrapunctus 21e42234b0 Clarify and correct commentary 2022-01-16 13:57:26 +05:30
contrapunctus c436539446 Disable orderless-initalism style
It resulted in some very far-off matches.
2022-01-16 13:57:26 +05:30
contrapunctus 22ce684297 Add and update custom_ids 2022-01-16 13:57:26 +05:30
contrapunctus 7651d2f592 Make consult-line bindings more similar to previous setup 2022-01-16 13:57:26 +05:30
contrapunctus 13acd66c78 Fix Boon keymap error 2022-01-16 13:57:26 +05:30
contrapunctus 7481a65db1 Bind package-menu-execute even if Boon is not loaded 2022-01-16 13:57:26 +05:30
contrapunctus 065469efdb Replace ivy/counsel with vertico/consult/orderless/marginalia 2022-01-16 13:57:26 +05:30
contrapunctus 6959d557b3 Reformat function 2022-01-16 13:57:26 +05:30
contrapunctus bf3ea9abc1 Move disabled sections below 2022-01-16 13:57:26 +05:30
contrapunctus 11865af0b7 Move Hydra to User Interface 2022-01-16 13:57:26 +05:30
contrapunctus ee7347c516 Add eshell configuration 2022-01-16 13:57:26 +05:30
contrapunctus f5121d50dd Move markdown-mode bindings into use-package 2022-01-16 13:57:26 +05:30
contrapunctus 381b74304b Move yasnippet to Completion 2022-01-16 13:57:26 +05:30
contrapunctus ee19410056 Add newlines 2022-01-16 13:57:26 +05:30
contrapunctus 13aca6aea8 Get rid of bootstrap/non-LP init.el 2022-01-16 13:57:26 +05:30
contrapunctus 364753b025 Remove old tangling functions 2022-01-15 12:52:17 +05:30
contrapunctus 663a5cf76a Add note about keybindings 2022-01-15 12:52:17 +05:30
contrapunctus d0a85f8b88 Don't warn about ORG_PATH
Org v9.3.8+ is now available on MELPA
2022-01-15 12:41:30 +05:30
contrapunctus bfc5ca2b5a Remove old library 2022-01-15 10:31:07 +05:30
contrapunctus 0564bde343 Use when-let instead of awhen 2022-01-15 10:29:24 +05:30
contrapunctus 671b7c2ab6 Use (file/dir-local) compile-command to determine command to run 2022-01-15 10:28:01 +05:30
contrapunctus 67e5bbda66 Reinstate :commands 2022-01-15 10:11:47 +05:30
contrapunctus c51ecd08b8 Remove compile targets from Makefile
Apparently there's no benefit to compiling the init.
2022-01-15 10:09:27 +05:30
contrapunctus 57bbbdb701 Remove unnecessary :commands 2022-01-15 10:06:34 +05:30
contrapunctus c0adf42577 Remove obsolete find-tag commands and bindings 2022-01-15 10:05:51 +05:30
contrapunctus f56f8fe182 Disable :ensure for explain-pause-mode
It is not present in MELPA or ELPA.
2022-01-15 01:06:25 +05:30
contrapunctus 2956ec4f27 Use `:ensure t` instead of use-package-always-ensure
The latter would break if I use-package'd a library which was not also
a package.
2022-01-15 01:02:48 +05:30
contrapunctus cf98d4e53f Add newlines 2022-01-15 00:46:44 +05:30
contrapunctus f00012df16 Enable company in SLIME buffers 2022-01-15 00:45:52 +05:30
contrapunctus b3d08694d0 Fix emms-playlist-mode keymap error 2022-01-15 00:44:11 +05:30
contrapunctus ffce737819 Add snippets 2022-01-14 21:59:48 +05:30
contrapunctus ba2db8d6c8 Define missing special variants of Lispy commands 2022-01-14 21:04:58 +05:30
contrapunctus 6a707d8468 Update disabled tags, add headings 2022-01-14 19:27:10 +05:30
contrapunctus e3584f2712 Change Lispy keys 2022-01-14 19:26:09 +05:30
contrapunctus 6760668c4c Comment on completion setup 2022-01-14 16:52:46 +05:30
contrapunctus 6beef200ff Reorganize sections 2022-01-14 16:41:12 +05:30
contrapunctus 4fff1af7ad Create sections in web development 2022-01-14 16:28:40 +05:30
contrapunctus 61906a14a8 Extract text from source block 2022-01-14 16:28:30 +05:30
contrapunctus 31e185f669 Move wgrep to Search 2022-01-14 16:27:23 +05:30
contrapunctus 9438bf2d25 Remove disabled command forms 2022-01-14 16:26:50 +05:30
contrapunctus 81a4ff624e Fix newlines 2022-01-14 16:26:35 +05:30
contrapunctus c95e364c30 Add headings, custom_ids 2022-01-14 13:31:07 +05:30
contrapunctus 257da23a01 Add custom_ids 2022-01-14 13:27:34 +05:30
contrapunctus 752c0e41a6 Enable prescient-persist-mode 2022-01-14 13:17:42 +05:30
contrapunctus f11a55851f Cleanup empty stuff 2022-01-14 13:17:02 +05:30
contrapunctus d78ef06fb3 Move Theme to UI, undo-tree to Editing 2022-01-14 13:06:20 +05:30
contrapunctus 7320598352 Add help hydra to SQL hydra 2022-01-14 13:02:04 +05:30
contrapunctus 3b33079d42 Fit PDFs to width 2022-01-14 13:01:40 +05:30
contrapunctus 7f183de07d Add custom_ids, move ediff and atomic-chrome to Editing
Move gnutls to Emacs
2022-01-14 13:00:18 +05:30
contrapunctus aee17834e2 Set up Company with SLIME (successfully) 2022-01-14 12:53:35 +05:30
contrapunctus d906a78c02 Remove old config 2022-01-14 12:28:22 +05:30
contrapunctus 4178488f64 Try to use Company in slime-repl-mode 2022-01-14 12:26:57 +05:30
contrapunctus 8e83db5b58 Move easy-kill to Editing section 2022-01-14 12:25:59 +05:30
contrapunctus 62689ca339 Fix "void-variable emms-playlist-mode-map" error 2022-01-14 12:24:52 +05:30
contrapunctus 18d307d0dd Move nov.el to Applications section 2022-01-14 01:35:59 +05:30
contrapunctus 053a818622 Move Company to Completion section 2022-01-14 01:34:37 +05:30
contrapunctus 60297d870a Enable Company in IELM 2022-01-14 01:30:03 +05:30
contrapunctus 64f1755755 Move cp-parens into init.org, deleting lots of junk 2022-01-13 23:08:12 +05:30
contrapunctus d9f31b9e0b Add company-prescient 2022-01-13 23:02:35 +05:30
contrapunctus 8a42f22b59 Reorganize, change cp-set-keys to bind-keys
Change use-package calls to non-package libraries, to support
use-package-always-ensure
2022-01-13 23:00:23 +05:30
contrapunctus b3bd77ae53 Use easier keybinding for emms-playlist-mode-center-current 2022-01-13 21:46:02 +05:30
contrapunctus a2d25a60ed Comment on ivy-rich-mode 2022-01-13 21:45:31 +05:30
contrapunctus ce4ade6e25 Remove edebug print limits 2022-01-13 21:43:34 +05:30
contrapunctus be8753ce8a Remove contrasync configuration 2022-01-13 21:43:11 +05:30
contrapunctus 11dd43bcd5 Enable Chronometrist debug logging 2022-01-13 21:41:55 +05:30
contrapunctus f257c5921d Update Chronometrist load-paths 2022-01-13 21:41:22 +05:30
contrapunctus a92c571a40 Update Chronometrist hook functions 2022-01-13 21:40:55 +05:30
contrapunctus 507452d412 Add function to run makem.sh 2022-01-13 21:40:07 +05:30
contrapunctus 79a23641b7 Add newlines between headings 2022-01-13 21:40:07 +05:30
contrapunctus 3e3392fda6 Disable jabber.el 2022-01-13 21:38:48 +05:30
contrapunctus ebd40d8d8f Compile even if directory is not found 2022-01-13 21:37:55 +05:30
contrapunctus ad47f5df1f Get rid of backup delete prompts 2022-01-13 21:37:26 +05:30
contrapunctus 62201a5579 Use initials completion-style 2022-01-13 21:37:15 +05:30
contrapunctus b129daa1d5 Remove obsolete definitions 2022-01-13 21:36:07 +05:30
contrapunctus 26d06fec15 Move comint to applications 2022-01-13 21:33:14 +05:30
contrapunctus d7858cc50a Don't use ix.io for pastes 2022-01-13 21:32:38 +05:30
contrapunctus 9b9c28b542 Move cp-editing, cp-lily, cp-lisp into init.org 2022-01-13 21:10:16 +05:30
contrapunctus 3ae8385c70 Move god-mode config to init.org 2022-01-11 13:17:18 +05:30
contrapunctus b4429a1e69 Update Lilypond compilation hydra heads 2022-01-10 10:07:35 +05:30
contrapunctus 9ee8302a6b Add Common Lisp source block to Org block hydra 2022-01-10 10:06:47 +05:30
contrapunctus 24f1812ec5 Add literate-elisp hydra to elisp-hydra 2022-01-10 10:06:17 +05:30
contrapunctus cf789f9113 Set chronometrist-task-list 2022-01-10 10:05:28 +05:30
contrapunctus 6a98469ee5 Add newlines between headings 2022-01-10 10:04:08 +05:30
contrapunctus 6e08bacd71 Use smartparens from MELPA 2022-01-10 10:00:50 +05:30
contrapunctus 092cd73eaf Enable explain-pause-mode 2022-01-10 10:00:24 +05:30
contrapunctus 441f415a66 Address init errors 2022-01-06 13:02:53 +05:30
contrapunctus 2d9b6b8557 Enable auto-revert in Dired buffers 2022-01-06 11:29:32 +05:30
contrapunctus 1fd76b849a Move docview configuration to Applications section 2022-01-06 11:28:28 +05:30
contrapunctus 605ce6f748 Move custom.el config into Emacs built-ins config
This way, theme configuration can be placed in the desired section,
not at the end of the file.
2022-01-06 11:26:48 +05:30
contrapunctus c3ba59fc83 Create headings in UI section 2022-01-06 11:26:05 +05:30
contrapunctus 8f55255e40 Move cp-ui into init.org 2022-01-06 11:19:40 +05:30
contrapunctus c960da5d18 Add newlines before headings 2022-01-06 11:11:09 +05:30
contrapunctus 1edfe873b2 Use async-backup 2022-01-06 11:11:09 +05:30
contrapunctus 766557dbde Create SQL hydra 2022-01-06 11:11:09 +05:30
contrapunctus 1c1c5fcc80 Add slime-eval-region to CL hydra 2022-01-06 11:11:06 +05:30
contrapunctus ea59097345 Add hydra head for CL-Lib info manual 2022-01-06 11:11:03 +05:30
contrapunctus 7002441fcb Bind g and l to navigation in pdf-view
Keep r from being shadowed by pdf-history-minor-mode-map
2022-01-06 11:11:03 +05:30
contrapunctus 80e05d4aea Change lambda to named function 2022-01-06 11:11:03 +05:30
contrapunctus b352e0c54a Disable "disabled commands" behaviour 2022-01-06 11:11:03 +05:30
contrapunctus 903bfa4691 Enable yasnippets in emacs-lisp-mode 2022-01-06 11:11:03 +05:30
contrapunctus 6ab8685c3e Add defclass snippet, change defgeneric and defmethod keys 2022-01-06 11:11:03 +05:30
contrapunctus c90545730c Create elisp-insert hydra, yasnippet config 2022-01-06 11:11:03 +05:30
contrapunctus 469eeda81f Use properties instead of timestamps for Org headings 2022-01-06 11:11:03 +05:30
contrapunctus 83f7432f83 Inhibit annoying table prompt 2022-01-06 11:11:03 +05:30
contrapunctus 01fa2dacc9 Fix Chronometrist query to indent >2 intervals a day correctly 2022-01-06 11:11:03 +05:30
contrapunctus 03da080201 Update Chronometrist running query to print to a buffer 2022-01-06 11:11:03 +05:30
contrapunctus 0f31a600ea Create headings for Chronometrist queries 2022-01-06 11:11:03 +05:30
contrapunctus e8d86308d8 Update running Chronometrist query to handle multiple intervals 2022-01-06 11:11:03 +05:30
contrapunctus eba98d6df5 Make Chronometrist query for running 2022-01-06 11:11:03 +05:30
contrapunctus 1ad9b02f1a Enable auto-installation everywhere 2022-01-06 11:11:03 +05:30
contrapunctus 2e0af9dd83 Add a workaround for when ELPA is down 2022-01-06 11:11:03 +05:30
contrapunctus fafec65119 Add :ensure t 2022-01-06 11:11:03 +05:30
contrapunctus 213553dbdd [general] Create use-package form 2022-01-06 11:11:03 +05:30
contrapunctus 52e647f539 [Unicode] Add keys for double quotes 2022-01-06 11:11:03 +05:30
contrapunctus 42172ec5c0 [Scheme/Hydra] Use CHICKEN as fallback implementation 2022-01-06 11:11:03 +05:30
contrapunctus 2c64fdfba8 [Common Lisp/Hydra] Add binding for slime-edit-definition 2022-01-06 11:11:03 +05:30
contrapunctus 6505e37717 [chronometrist] Update examples to use new iteration conventions
Namely, just use to-list/to-hash-table in conjunction with your
iteration construct of choice.

Use format-seconds rather than ts-human-format-duration
2022-01-06 11:11:03 +05:30
contrapunctus 870c97e17d [chronometrist] Rename activity indicator to use "my-" prefix 2022-01-06 11:11:03 +05:30
contrapunctus d0ffc43e5a [chronometrist] Remove keybinding for details
It has been added to the Chronometrist defaults
2022-01-06 11:11:03 +05:30
contrapunctus 490d7545ff [org] Don't use sxiv to open images
The Emacs viewer can cycle through other images in the same directory,
whereas sxiv only opens the linked image.
2022-01-06 11:11:03 +05:30
contrapunctus dfbf09b7d7 Remove M-x rebinding
I can live with M-n for backward-word
2022-01-06 11:11:03 +05:30
contrapunctus cc3a391f3f Add new Unicode keys 2022-01-06 11:11:03 +05:30
contrapunctus eaafa81426 [org] WIP async tangle code 2022-01-06 11:11:03 +05:30
contrapunctus 5297415cf3 [imenu] add imenus 2022-01-06 11:11:03 +05:30
contrapunctus 30fbaa5462 [hydra] help hydra - add describe-char 2022-01-06 11:11:03 +05:30
contrapunctus 76bd0ef616 [unicode] move currency keys into their own section 2022-01-06 11:11:03 +05:30
contrapunctus bc4830cf1b [ivy] add ivy-xref 2022-01-06 11:11:03 +05:30
contrapunctus 3e89589acb [Unicode] add extra keys for em-dash and en-dash 2022-01-06 11:11:03 +05:30
contrapunctus 0de25c5ffc [window-numbering] bind C-7/8/9 to window 1/2/3 2022-01-06 11:11:03 +05:30
contrapunctus 3780b60625 [pdf-view] add isearch binding, set default display size 2022-01-06 11:11:03 +05:30
contrapunctus 859ddf7674 [chronometrist] update to reflect interface changes 2022-01-06 11:11:03 +05:30
contrapunctus 6517f3ebe4 [hydra] Elisp byte compile - operate on current file 2022-01-06 11:11:03 +05:30
contrapunctus f0ddf36db9 [hydra] fix incorrect call to my-compile-org-lp 2022-01-06 11:11:03 +05:30
contrapunctus 0c4d1a0361 [hydra] window hydra - add balance-windows 2022-01-06 11:11:03 +05:30
contrapunctus 0e749bdb1d [ivy] move bindings to use-package 2022-01-06 11:11:03 +05:30
contrapunctus 0a8e1d8268 [Unicode] add easier keys for umlauts 2022-01-06 11:11:03 +05:30
contrapunctus f6b2bacffd [hydra/org] use metaleft/metaright instead of promote/demote-subtree 2022-01-06 11:11:03 +05:30
contrapunctus b90f9f0216 [nameless] bind nameless-insert-name 2022-01-06 11:11:03 +05:30
contrapunctus 81fb144e60 [elpher] add elpher-reload keybinding 2022-01-06 11:11:03 +05:30
contrapunctus 38145abee7 [hydra] add rgrep 2022-01-06 11:11:03 +05:30
contrapunctus c438daa190 [hydra] make hydra for literate-elisp 2022-01-06 11:11:03 +05:30
contrapunctus ca96cde0d1 [UTF-8] add more variables 2022-01-06 11:11:03 +05:30
contrapunctus fbe7926ce0 [unicode] change prefix to C-t, add en dash 2022-01-06 11:11:03 +05:30
contrapunctus 0ceb8e43bc [org] add newline after block 2022-01-06 11:11:03 +05:30
contrapunctus 019c53b08e [org] set up link comments, disable EXWM code blocks for literate-elisp 2022-01-06 11:11:03 +05:30
contrapunctus 123cc7c422 [backup] update backup settings, configure backup on each save 2022-01-06 11:11:03 +05:30
contrapunctus 50014f4b99 [compile/org] extend docstring 2022-01-06 11:11:03 +05:30
contrapunctus 19129eae62 [compile/org] add headings, handle prefix arg, remove old version 2022-01-06 11:11:03 +05:30
contrapunctus b29c6054cd [org] ORG_PATH not necessary if you have v27.1 with Org v9.5 2022-01-06 11:11:03 +05:30
contrapunctus b365aac259 [compile/org] preserve column 2022-01-06 11:11:03 +05:30
contrapunctus 6623a59e04 [compile/org] handle being called via literate-elisp-byte-compile-file 2022-01-06 11:11:03 +05:30
contrapunctus 31da5dcf03 [compile/org] automatically jump to Org LP from compilation-mode errors 2022-01-06 11:11:03 +05:30
contrapunctus 073d7ce234 Migrate atomic-chrome configuration to use-package 2022-01-06 11:11:03 +05:30
contrapunctus 8b0249e95c Update default LP compile command 2022-01-06 11:11:03 +05:30
contrapunctus 32e1292e1e Unicode: add sharp sign 2022-01-06 11:11:03 +05:30
contrapunctus 3f43f65198 Enable auto-revert-mode in org-mode buffers 2022-01-06 11:11:03 +05:30
contrapunctus d10eef4840 enable Lispy in SLIME REPL 2022-01-06 11:11:03 +05:30
contrapunctus b98c362e22 Set Lisp binary name 2022-01-06 11:11:03 +05:30
contrapunctus 1f7dfe2c94 Correct package name for cc-mode 2022-01-06 11:11:03 +05:30
contrapunctus 728476fbe8 Add tern 2022-01-06 11:11:03 +05:30
contrapunctus 85e401f4ed [hydra] update/extend compilation heads 2022-01-06 11:11:03 +05:30
contrapunctus 5a19d3bc36 disable project sidebars (never used them...) 2022-01-06 11:11:03 +05:30
contrapunctus 5c3a7419a9 [org] use my- instead of cp/ 2022-01-06 11:11:03 +05:30
contrapunctus 4085bf94da [nov.el] set modifier-free keybindings 2022-01-06 11:11:03 +05:30
contrapunctus 7b8e87efcb [slime] update config, see if it's really necessary to set inferior-lisp-program 2022-01-06 11:11:03 +05:30
contrapunctus b3734d4455 [slime] update config, see if it's really necessary to set inferior-lisp-program 2022-01-06 11:11:03 +05:30
contrapunctus a6ec0aed9a Add preliminary web development configuration 2022-01-06 11:11:03 +05:30
contrapunctus 52a116fa05 [package] use Boon-like keys (Dvorak) for movement 2022-01-06 11:11:03 +05:30
contrapunctus f06c37d8c6 Change /home/.../ to ~/ 2022-01-06 11:11:03 +05:30
contrapunctus 23b3a33d17 Move use-package to init.org 2022-01-06 11:11:03 +05:30
contrapunctus d2ae421a7a Use load instead of literate-elisp-load
The latter does not honor the #+OPTIONS: use-property-inheritance:t
line, so we are back to plain old tangling and loading.
2022-01-06 11:11:03 +05:30
contrapunctus e65c0837c6 [exwm] disable section 2022-01-06 11:11:03 +05:30
contrapunctus 38f29f9d47 [chronometrist] use ~/ for home 2022-01-06 11:11:03 +05:30
contrapunctus b015f19942 [recentf] use locate-user-emacs-file for recentf-save-file 2022-01-06 11:11:03 +05:30
contrapunctus 32bf0ea458 chronometrist - define and use frameset for composition and sequencing 2022-01-06 11:11:03 +05:30
contrapunctus 334b422dc6 chronometrist - use plist-group backend 2022-01-06 11:11:03 +05:30
contrapunctus 0c9aaffd9f fix: make iteration through records generic 2022-01-06 11:11:03 +05:30
contrapunctus 96aa0f86ea [literate] remove top-level heading, promote subtree 2022-01-06 11:11:03 +05:30
contrapunctus 07c83847a0 [chronometrist] use frameset for Arrangement task 2022-01-06 11:11:03 +05:30
contrapunctus 585ca01285 [emms] disable recursive search for subtitle files
Most of the time it's more of a hindrance than a help.
2022-01-06 11:11:03 +05:30
contrapunctus e18f66752d [hydra] use "josm" as buffer name instead of "java" 2022-01-06 11:11:02 +05:30
contrapunctus 4196d515b1 [org] clarify code via indentation 2022-01-06 11:11:02 +05:30
contrapunctus 712a604544 [Unicode] add trademark sign 2022-01-06 11:11:02 +05:30
contrapunctus 83f52f3c84 [org] set up shell source blocks 2022-01-06 11:11:02 +05:30
contrapunctus b8e9db537c [hydra] add literate-elisp and compile (prompt) heads 2022-01-06 11:11:02 +05:30
contrapunctus 35f8b1bc05 [hydra] create hydra to evaluate Org shell source blocks 2022-01-06 11:11:02 +05:30
contrapunctus b2055090d2 Use symlinks for multi-machine config; create my-find-file* 2022-01-06 11:11:02 +05:30
contrapunctus 902268f913 Attempt to create multi-machine configuration 2022-01-06 11:11:02 +05:30
contrapunctus 9680150f28 [chronometrist] use generic backend protocol 2022-01-06 11:11:02 +05:30
contrapunctus 16a5f70e6c [compile] fix logic 2022-01-06 11:11:02 +05:30
contrapunctus e2feccc902 [unicode] use shorter keybindings for umlauts 2022-01-06 11:11:02 +05:30
contrapunctus 92a5c08279 [org] use relative links 2022-01-06 11:11:02 +05:30
contrapunctus 5ed54066db [editing] update cp/copy-bus-entry to handle headings and lists 2022-01-06 11:11:02 +05:30
contrapunctus d67dae2918 [emacs] prefer loading newer files 2022-01-06 11:11:02 +05:30
contrapunctus 6e9f1c60ab [desktop] disable restoring of frames 2022-01-06 11:11:02 +05:30
contrapunctus 36be73cacd [exwm] add note 2022-01-06 11:11:02 +05:30
contrapunctus 20c5e08fd0 [hydra] Scheme - use general hydra for other implementations 2022-01-06 11:11:02 +05:30
contrapunctus 188d365629 [unicode] simplify keys 2022-01-06 11:11:02 +05:30
contrapunctus f1eb05270f [compile] run my-compile-project without visual interruption 2022-01-06 11:11:02 +05:30
contrapunctus 036a7388b6 [hydra] use my-compile-project 2022-01-06 11:11:02 +05:30
contrapunctus 4370fa6a10 [hydra] app - add JOSM, Qtractor heads 2022-01-06 11:11:02 +05:30
contrapunctus 55a667bca8 [compile] use my-compile-project to reduce duplication 2022-01-06 11:11:02 +05:30
contrapunctus a746b5c29a [hydra] help hydra - use helpful-callable 2022-01-06 11:11:02 +05:30
contrapunctus e484313852 [exwm] disable package; tweak my-start-app-or-switch to cope 2022-01-06 11:11:02 +05:30
contrapunctus 033937f5d6 [compile] fix my-compile-project 2022-01-06 11:11:02 +05:30
contrapunctus 468b3cd56f [emms] buggy and unnecessary to start mpv in fullscreen with EXWM 2022-01-06 11:11:02 +05:30
contrapunctus 5eec48b77c [chronometrist] bugfix my-get-saved-changeset-id 2022-01-06 11:11:02 +05:30
contrapunctus 87060061cb [hydra] add Texinfo manual to info hydra 2022-01-06 11:11:02 +05:30
contrapunctus 102bb66bba [exwm] try keeping Enter-dependent commands under RH, rest under LH 2022-01-06 11:11:02 +05:30
contrapunctus 93d1433333 [compile] move my-compile-project and update behavior 2022-01-06 11:11:02 +05:30
contrapunctus 191eb0e5f5 [midnight] never kill Gajim buffers 2022-01-06 11:11:02 +05:30
contrapunctus 910f40b242 [company] enable quick access hints, bind C-<number> to quick access 2022-01-06 11:11:02 +05:30
contrapunctus 6b28298ac8 [pdf-tools] add config 2022-01-06 11:11:02 +05:30
contrapunctus 42df0371b2 [org] open PDF files in Emacs 2022-01-06 11:11:02 +05:30
contrapunctus f33cc7cf80 [hydra] change slime-connect keybinding 2022-01-06 11:11:02 +05:30
contrapunctus 35c841e668 [hydra] add Emacs documentation commands to CL help hydra 2022-01-06 11:11:02 +05:30
contrapunctus 65d8e8e954 [hydra] create search hydra 2022-01-06 11:11:02 +05:30
contrapunctus e1309d59b9 [eww] add Boon-like navigation keybindings 2022-01-06 11:11:02 +05:30
contrapunctus 7bf9df4c83 [hydra] make Common Lisp-specific help hydra 2022-01-06 11:11:02 +05:30
contrapunctus 68386ab2c4 [eww] use eww-after-render-hook for line display functions 2022-01-06 11:11:02 +05:30
contrapunctus 418a6a3bc8 [hydra] add eww 2022-01-06 11:11:02 +05:30
contrapunctus 26cd72b160 [exwm] add right-hand keybindings for window switching 2022-01-06 11:11:02 +05:30
contrapunctus a36d9a221f [magit] fix advice function 2022-01-06 11:11:02 +05:30
contrapunctus 0d8c5ce893 [unicode] add symbols 2022-01-06 11:11:02 +05:30
contrapunctus 451a7ed012 [hydra] tweak Scheme implementation discovery 2022-01-06 11:11:02 +05:30
contrapunctus 8c6bbdf518 [outline] move to Navigation; add outshine config 2022-01-06 11:11:02 +05:30
contrapunctus ee5f90dcca [hydra] add text scale commands 2022-01-06 11:11:02 +05:30
contrapunctus fb8bc8fc7a [hydra] applications - add sxiv 2022-01-06 11:11:02 +05:30
contrapunctus 7b394c2192 [hydra] org - add Scheme source block 2022-01-06 11:11:02 +05:30
contrapunctus 2e50afd431 [hydra] refactor duplicate calls to my-compile-project 2022-01-06 11:11:02 +05:30
contrapunctus e20ed27cab [hydra] use my-compile-project instead of compile 2022-01-06 11:11:02 +05:30
contrapunctus 1aa15a842c [compile] my-compile-project - read command before running 2022-01-06 11:11:02 +05:30
contrapunctus 64a4cdef7a [nov] make hydra work when point is on a link 2022-01-06 11:11:02 +05:30
contrapunctus a4bff2032a [exwm] fix inconsistency in keybindings 2022-01-06 11:11:02 +05:30
contrapunctus ef2b9950ac [exwm] add key for shell 2022-01-06 11:11:02 +05:30
contrapunctus 13a31da9a0 Add Makefile 2022-01-06 11:11:02 +05:30
contrapunctus 5c546104cf [company] disable annoying message from the etags backend 2022-01-06 11:11:02 +05:30
contrapunctus 66979d8104 [org] remove unused bindings 2022-01-06 11:11:02 +05:30
contrapunctus fb7a1319c9 [company] bind C-w to backward-kill-word 2022-01-06 11:11:02 +05:30
contrapunctus 5d8cdfbc51 [exwm] bind delete-other-windows closer to Super 2022-01-06 11:11:02 +05:30
contrapunctus 5f601c504c [exwm] place less-used commands on keys farther from Super 2022-01-06 11:11:02 +05:30
contrapunctus c730d2e1fa [hydra] add man command 2022-01-06 11:11:02 +05:30
contrapunctus 418596c895 [magit] update advice 2022-01-06 11:11:02 +05:30
contrapunctus 2427f2b4d1 [exwm] add input method keybinding 2022-01-06 11:11:02 +05:30
contrapunctus 7211ff438e [emacs] increase history-length 2022-01-06 11:11:02 +05:30
contrapunctus 67ac9dba5d Add note about Ctrl-based keybindings 2022-01-06 11:11:02 +05:30
contrapunctus c43933b6cf [hydra] use imenu 2022-01-06 11:11:02 +05:30
contrapunctus d9bc25796d [chronometrist] OSM hook function - bugfix and refactor 2022-01-06 11:11:02 +05:30
contrapunctus edbedbf907 [hydra] move compile out of common heads; rename cp/compile-project 2022-01-06 11:11:02 +05:30
contrapunctus ffff738225 [hydra] app - add xfce4-screenshooter 2022-01-06 11:11:02 +05:30
contrapunctus c5fcac33a9 [hydra] org - use metadown/metaup instead of org-drag-element-* 2022-01-06 11:11:02 +05:30
contrapunctus 13e884b870 [latex] move to markup section 2022-01-06 11:11:02 +05:30
contrapunctus 9cd08478ed [hydra] remove non-existent head, add todo head 2022-01-06 11:11:02 +05:30
contrapunctus c016ef5021 [hydra] add byte-compile hydra 2022-01-06 11:11:02 +05:30
contrapunctus 795527eff7 [chronometrist] use --> for activity indicator 2022-01-06 11:11:02 +05:30
contrapunctus b829d95293 [chronometrist] use lazy loading for OSM hook function 2022-01-06 11:11:02 +05:30
contrapunctus 2e4814eb25 [chronometrist] refactor OSM hook function 2022-01-06 11:11:02 +05:30
contrapunctus cd07480db8 [chronometrist] OSM hook function - handle no saved changeset 2022-01-06 11:11:02 +05:30
contrapunctus 1a4313f02c [chronometrist] improve OSM hook function
The new version doesn't just get the details of the latest changeset -
it gets all changesets until the last one saved in the file.
2022-01-06 11:11:02 +05:30
contrapunctus 679d5d7c83 [hydra] use helpful-* instead of describe-* 2022-01-06 11:11:02 +05:30
contrapunctus fb234ed7ee [exwm] change keys for ido-mini and exwm-input-toggle-keyboard 2022-01-06 11:11:02 +05:30
contrapunctus f09426d0db Create my-buffer-switch 2022-01-06 11:11:02 +05:30
contrapunctus 80b9874d49 [hydra] refactor 2022-01-06 11:11:02 +05:30
contrapunctus 4dc09324b3 [hydra] change color of kill-buffer to red 2022-01-06 11:11:02 +05:30
contrapunctus 1e6660d73a [chronometrist] fix contrapunctus-display-key-values-helper 2022-01-06 11:11:02 +05:30
contrapunctus c50a1fcccc [lispy] enable in inferior-emacs-lisp-mode 2022-01-06 11:11:02 +05:30
contrapunctus 8b618e5f61 [hydra] create help hydra 2022-01-06 11:11:02 +05:30
contrapunctus f238a03085 [volume] add configuration 2022-01-06 11:11:02 +05:30
contrapunctus 3e406a715a [exwm] make window switching more robust 2022-01-06 11:11:02 +05:30
contrapunctus fc5eca36a3 [hydra] change application hydra color to blue 2022-01-06 11:11:02 +05:30
contrapunctus e635a5fa31 Remove s-k binding for kill-buffer 2022-01-06 11:11:02 +05:30
contrapunctus 58efa3da8b [hydra] add Bittorrent client launcher 2022-01-06 11:11:02 +05:30
contrapunctus c7c54cafd0 [exwm] add bindings for exwm-input-toggle-keyboard 2022-01-06 11:11:02 +05:30
contrapunctus 15829f5459 [exwm] run notification-daemon on startup 2022-01-06 11:11:02 +05:30
contrapunctus 321517a863 [hydra] remove programming hydra 2022-01-06 11:11:02 +05:30
contrapunctus 38324e0cdd [hydra] make unified applications hydra 2022-01-06 11:11:02 +05:30
contrapunctus ff6207dcef [org] fix XMPP links 2022-01-06 11:11:02 +05:30
contrapunctus b90362e312 [proced] add configuration and hydra entry 2022-01-06 11:11:02 +05:30
contrapunctus f028e9cc60 [ido-mini] quash keymap warning 2022-01-06 11:11:02 +05:30
contrapunctus 37d6149fb8 [exwm] prioritize hydra over manual buffer switching 2022-01-06 11:11:02 +05:30
contrapunctus ea71f9a905 [lispy] disable C-<number> keybindings 2022-01-06 11:11:02 +05:30
contrapunctus e7f8c4aea9 [exwm] move xset from Elisp to kmonad configuration 2022-01-06 11:11:02 +05:30
contrapunctus 6bcafade0e [chronometrist] simplify key-value display 2022-01-06 11:11:02 +05:30
contrapunctus dfacd9ded4 [exwm] create my-start-app-or-switch 2022-01-06 11:11:02 +05:30
contrapunctus 9322272b54 [exwm] add bindings for general hydra 2022-01-06 11:11:02 +05:30
contrapunctus f705206452 [hydra] extend external hydra, use it in more hydras 2022-01-06 11:11:02 +05:30
contrapunctus 5a844c00ce [hydra] add external application hydra 2022-01-06 11:10:55 +05:30
contrapunctus 1a120e251e [exwm] create my-start-process 2021-08-03 20:26:57 +05:30
contrapunctus 5271489cab [exwm] use window title for buffer name 2021-08-03 20:26:57 +05:30
contrapunctus 5171cc2d9a [exwm] set up buffer switching and window management 2021-08-03 20:26:57 +05:30
contrapunctus b593eb323b [lispy] disable C-<number> keys 2021-08-03 20:26:57 +05:30
contrapunctus 53c99c9667 [exwm] launch kmonad after start 2021-08-03 20:26:57 +05:30
contrapunctus d50fd5722a [lispy] add to scheme-mode 2021-08-03 20:26:57 +05:30
contrapunctus 83c2e854d5 [org] add support for XMPP links 2021-08-03 20:26:57 +05:30
contrapunctus a35e24bae3 [ox-publish] add configuration for blog/gemlog bi-hosting 2021-08-03 20:26:57 +05:30
contrapunctus 8f61851548 Add EXWM 2021-08-03 20:26:57 +05:30
contrapunctus ac68b41bfd [window-numbering] use Ctrl rather than Meta bindings
Since I've configured Space to emit Ctrl when held (using kmonad),
Ctrl bindings are more efficient than Meta bindings.
2021-08-03 20:26:57 +05:30
contrapunctus 73a2ce45f4 [window-numbering] migrate to use-package 2021-08-03 20:26:57 +05:30
contrapunctus 0e1897c6f7 [ibuffer] migrate ibuffer to use-package 2021-08-03 20:26:57 +05:30
contrapunctus 2f3992fdc1 [literate] move Org and Markdown to markup section; move cp-nav to init.org 2021-08-03 20:26:57 +05:30
contrapunctus bfbb95eaa2 [literate] make "Searching" heading 2021-08-03 20:26:57 +05:30
contrapunctus 7d25c64eb0 [company] disable in text modes 2021-08-03 20:26:57 +05:30
contrapunctus f25acf3abb [gemini] set up outline-minor-mode 2021-08-03 20:26:57 +05:30
contrapunctus a7e48011c7 Bind s-k to kill-buffer 2021-07-23 19:31:00 +05:30
contrapunctus ffd5d265b6 [nov.el] change navigation bindings 2021-07-23 19:28:48 +05:30
contrapunctus 2300f0b948 [hydra] add imenu-list and other bindings 2021-07-23 19:28:03 +05:30
contrapunctus e256fd115d [hydra] make hydras more uniform 2021-07-21 12:13:48 +05:30
contrapunctus b9ed987fd4 [org/async-tangle] don't create window if buffer already visible 2021-07-12 08:55:06 +05:30
contrapunctus 150764aa2e [chronometrist] extend display-key-values 2021-07-09 21:30:19 +05:30
contrapunctus a4517fdd58 Add Unlicense 2021-07-09 10:32:06 +05:30
contrapunctus 498f17049a [programming] add sections for common config 2021-07-09 07:16:43 +05:30
contrapunctus 87b3acb009 [programming] add treemacs, imenu, side-hustle 2021-07-09 01:56:50 +05:30
contrapunctus 023c883031 [literate] load tangled file if newer 2021-07-09 01:55:45 +05:30
contrapunctus b99b0d2221 [org] create async tangle command 2021-07-07 09:45:24 +05:30
contrapunctus c2d8c4cd9e [keyswap] disable package
My muscle memory was always getting confused between the different
modes in which () was [] and in which it was not. And it conflicts
with Lispy.
2021-07-07 07:30:22 +05:30
contrapunctus d7e5a0988b [smartparens] move config from cp-parens to init.org 2021-07-06 21:47:53 +05:30
contrapunctus f06ddeb7a1 [lispy] rebind movement to Boon-like (QWERTY) KIOL 2021-07-06 20:55:23 +05:30
contrapunctus 0bc111a4f1 [lispy] add use-package form 2021-07-06 07:13:26 +05:30
contrapunctus 8e6ced554b [linewrapping] clean up config 2021-07-06 06:42:44 +05:30
contrapunctus 14ae91ab21 [elpher] make keys Boon-like 2021-07-06 06:41:53 +05:30
contrapunctus 8484fff8b3 [chronometrist] add more example queries 2021-07-06 06:41:00 +05:30
contrapunctus 8f5ef93023 [chronometrist] clarify number of days 2021-07-06 06:26:14 +05:30
contrapunctus 7d6e7d823a [hydra] don't exit when running window commands 2021-07-06 06:25:33 +05:30
contrapunctus f507db8d66 [nameless] enable in Org mode (literate programs) 2021-07-06 06:22:06 +05:30
contrapunctus 648f871f4e [outline] extend adoc/outline config 2021-07-06 06:21:12 +05:30
contrapunctus 137c525f43 [hydra] add window quick keybindings to Emacs Lisp hydra 2021-07-03 09:36:33 +05:30
contrapunctus 7f49e83a9b [hydra] add window quick keybindings to Org hydra 2021-07-02 07:20:21 +05:30
contrapunctus d753be5599 [hydra] add more windows keybindings; make more consistent 2021-07-01 03:42:22 +05:30
contrapunctus 5257568556 [unicode] add fractions 2021-07-01 03:39:25 +05:30
contrapunctus d9abd04b0d Remove keypad bindings
My wrist is hurting and I suspect these may be the case. Removing them
to encourage using alternative keybindings.
2021-06-27 18:22:39 +05:30
contrapunctus 6e78eaf6a9 [chronometrist-details] fix Programming key-value display; add docstring 2021-06-27 15:01:26 +05:30
contrapunctus 2297bb7393 [literate-elisp] use `require` instead of `load` 2021-06-22 06:09:41 +05:30
contrapunctus 30f5ea3952 [hydra/org] add folding commands 2021-06-17 16:55:25 +05:30
contrapunctus bef33c417a [hydra/org] add org-babel-tangle-jump-to-org keybinding 2021-06-17 16:50:48 +05:30
contrapunctus bbd6926886 [hydra/org] add general keybindings 2021-06-17 16:50:19 +05:30
contrapunctus 9600a81e7e [hydra] order heads alphabetically 2021-06-14 16:39:56 +05:30
contrapunctus 26cc83d2da [hydra] change window command bindings 2021-06-14 16:38:45 +05:30
contrapunctus 5d9119f3bf [hydra] fix errors in language detection 2021-06-14 15:34:11 +05:30
contrapunctus 3c3cd1fccd [hydra] set new bindings for global hydra 2021-06-14 15:33:40 +05:30
contrapunctus e1ff63a8ef [hydra] add new Org block types 2021-06-13 17:24:37 +05:30
contrapunctus f83ba1891e [slime-repl] swap colon and semicolon 2021-06-13 17:24:09 +05:30
contrapunctus 02694968ee [ielm] bind M-' to sp-indent-defun in ielm-map 2021-06-13 17:23:16 +05:30
contrapunctus 1534d70644 [outline] toggle children if on heading, else indent 2021-06-06 07:57:59 +05:30
contrapunctus cf70eed1aa [unicode] add flat sign, rebind arrow symbols 2021-06-06 07:49:48 +05:30
contrapunctus 2ec4f7cadf Add adoc-mode and outline-minor-mode 2021-06-06 07:42:19 +05:30
contrapunctus a5feb7de11 [theme] switch to doom-molokai 2021-06-06 07:41:52 +05:30
contrapunctus 9555eb2e90 [visual-fill-column] move to init.org 2021-06-06 07:41:21 +05:30
contrapunctus f25d825d5f chronometrist - load extensions before core 2021-06-03 11:32:47 +05:30
contrapunctus a28b8e74c8 [chronometrist-details] display opus numbers 2021-05-29 00:03:21 +05:30
contrapunctus 38e615eee8 [chronometrist-details] display Exercise key-values 2021-05-28 23:58:59 +05:30
contrapunctus 4ace157e96 [hydra] use elisp hydra in debugger-mode 2021-05-28 13:45:31 +05:30
contrapunctus 457ba0b886 [org] auto-insert timestamp in new headings 2021-05-28 13:43:51 +05:30
contrapunctus c909deb9cb [chronometrist] add keybindings for report and details 2021-05-27 18:29:03 +05:30
contrapunctus 776a737c04 [chronometrist] update Video editing actions 2021-05-27 18:27:02 +05:30
contrapunctus efdd14695a [chronometrist-details] expand key-value display function 2021-05-27 18:26:39 +05:30
contrapunctus 306dd277ea [chronometrist-details] update config 2021-05-27 18:26:21 +05:30
contrapunctus f56e420101 [chronometrist-details] initial key-value printing config 2021-05-26 10:10:02 +05:30
contrapunctus 346a9b3802 Restucture chronometrist config; add chronometrist-details config 2021-05-26 00:51:35 +05:30
contrapunctus 3e7522f6d6 [org] fix Gemini link export 2021-05-20 16:11:02 +05:30
contrapunctus aeb78321b1 [hydra] open general hydra in non-programming modes 2021-05-15 20:37:16 +05:30
contrapunctus 544063a8a5 [markdown] adapt to Dvorak 2021-05-15 20:37:01 +05:30
contrapunctus c48015832e [emms] adapt to Dvorak 2021-05-15 20:36:42 +05:30
contrapunctus a7bec1d10d [smartparens] bind sp-indent-defun to M-' 2021-05-15 20:28:35 +05:30
contrapunctus 18769a28b2 [chronometrist] add loop-file example 2021-04-16 09:39:48 +05:30
contrapunctus 9372fb7bb0 [chronometrist] adjust goals 2021-04-16 09:38:19 +05:30
contrapunctus 446d5e3f28 [org] move CSS to its own file 2021-04-10 00:12:47 +05:30
contrapunctus a3fa9602c0 [jabber] enable package and Carbons; add account 2021-04-09 14:10:00 +05:30
contrapunctus c3010ec944 [hydra] create Jabber hydra 2021-04-09 14:09:37 +05:30
contrapunctus ad0ab58af9 [keyswap] swap parens in ielm-mode 2021-04-06 15:00:27 +05:30
contrapunctus dcd47d5490 [timestamp] remove org-mode specific behaviour 2021-04-03 14:32:48 +05:30
contrapunctus ceca6912a7 Keybinding changes 2021-04-03 14:31:53 +05:30
contrapunctus 89e2ac50ff [keyswap] add more Lisp modes 2021-04-03 14:26:59 +05:30
contrapunctus 5474584bdf Update paths to reflect partition changes 2021-04-03 14:26:09 +05:30
contrapunctus a9509793ab [unicode] organize keys better, add multiplication sign 2021-04-03 14:24:34 +05:30
contrapunctus d67741ce09 [unicode] add sharp s, c with cedilla 2021-03-27 14:38:28 +05:30
contrapunctus bde5e8076f [nov.el] make Boon keybindings work when point is in a link 2021-03-27 14:38:17 +05:30
contrapunctus bf7c67e711 Update mkly compile commands
I now keep the script in project directories.
2021-03-21 16:11:25 +05:30
contrapunctus c88521ed6c [unicode] add a with diaeresis, three quarters 2021-03-21 12:31:45 +05:30
contrapunctus 6f8150cc7d [chronometrist] update start-project 2021-03-21 12:30:43 +05:30
contrapunctus 3e165ce115 [desktop] remember counsel-M-x-history across sessions 2021-03-16 12:41:42 +05:30
contrapunctus 51ee3842a3 [unicode] add more fractions 2021-03-16 12:41:03 +05:30
contrapunctus b64cfeef64 [literate] move desktop and mail config to init.org 2021-03-16 12:41:03 +05:30
contrapunctus 463db6d685 [comint] change keys to be more congruent with other modes 2021-03-15 19:23:45 +05:30
contrapunctus 56ea4d2d29 [dvorak] adapt window hydra keys 2021-03-15 18:53:07 +05:30
contrapunctus cc65c02dc5 [lilypond] create Boon-like keybindings 2021-03-12 11:48:56 +05:30
contrapunctus c5df847dc5 [dired] add boon-like keybindings 2021-03-12 11:45:16 +05:30
contrapunctus 85eb74a0a2 [org] cp-org-insert-block - clean up code, add comments 2021-03-12 11:44:55 +05:30
contrapunctus 2b2bf26a2f [literate] move file management config to init.org 2021-03-12 11:44:55 +05:30
contrapunctus b76049d21c [org] cp-org-insert-block - fix region behaviour, clean up code 2021-03-10 20:26:41 +05:30
contrapunctus 631d7e0fa6 [hydra] add geiser-eval-last-sexp 2021-03-09 02:27:53 +05:30
contrapunctus 7807d4a133 [org] extend cp-org-insert-src with quote support -> cp-org-insert-block
Also tried adding region support, but I'm not sure it works exactly
like I want yet.
2021-03-09 02:19:45 +05:30
contrapunctus 57a74fb6c4 [hydra] use O for Org to avoid conflict with save-buffer 2021-03-09 02:18:12 +05:30
contrapunctus 60b60f73a7 [magit] fix magit-rebase binding 2021-03-09 02:17:05 +05:30
contrapunctus 2a4ee6ec71 [timestamps] make Hydra heads, merge date and time commands...
,,,handle certain modes differently.
2021-03-09 02:12:19 +05:30
contrapunctus 8a5158a3b8 [Unicode] add new characters 2021-03-05 17:35:07 +05:30
contrapunctus 101d74779a [tex] fix error, move config to init.org 2021-02-22 14:26:57 +05:30
contrapunctus 94cf603750 [git-commit] make history navigation bindings Boon-like 2021-02-22 04:34:24 +05:30
contrapunctus 5ff5547327 [hydra] add head for inserting Emacs Lisp test blocks 2021-02-22 04:32:39 +05:30
contrapunctus 3faa88bc40 [hydra] create Elisp debug hydra 2021-02-22 04:30:59 +05:30
contrapunctus b8ff880ee1 [hydra] use easier-to-reach bindings for line display 2021-02-22 04:30:59 +05:30
contrapunctus ca88612ee0 [comint] make history bindings Boon-like 2021-02-22 04:21:51 +05:30
contrapunctus 7f58526967 [hydra] fix incorrect target 2021-02-22 04:20:52 +05:30
contrapunctus 64563bef4f [hydra] create info hydra 2021-02-22 04:20:08 +05:30
contrapunctus 8c443fc44d [keyswap] ensure order of code 2021-02-22 04:14:09 +05:30
contrapunctus 3de833ab8c [org] bind M-h to default-indent-new-line 2021-02-22 04:07:31 +05:30
contrapunctus 2f9ddc4e04 [ivy] bind C-h to ivy-backward-delete-char 2021-02-22 04:06:31 +05:30
contrapunctus 58a17a6bab [unicode] add keys for £ and é 2021-02-20 19:14:56 +05:30
contrapunctus 33ac5cb6d0 Use emacsshot 2021-02-20 19:14:12 +05:30
contrapunctus f76e5ed1c7 Bind C-h to backward-delete-char 2021-02-20 19:11:46 +05:30
contrapunctus d2d03adaff [hydra] correct "up" target 2021-02-20 17:31:40 +05:30
contrapunctus 0adf1e26bc [dvorak] remove C-g, C-w, C-u, and C-h rebindings 2021-02-20 12:25:20 +05:30
contrapunctus 613253aff0 [dvorak] define more global bindings 2021-02-20 11:49:14 +05:30
contrapunctus 05611814d2 [org] make metaup/metadown bindings Boon-like 2021-02-20 11:49:08 +05:30
contrapunctus 0a3472c885 [smartparens] move configuration to init.org 2021-02-20 11:49:08 +05:30
contrapunctus d7b2f88c54 [magit] fix magit-commit binding 2021-02-20 10:47:59 +05:30
contrapunctus 707454dd0b [multiple cursors] fix edit-lines hint 2021-02-20 10:44:13 +05:30
contrapunctus f78c66cc71 [keyswap] try to swap parens and brackets in the minibuffer 2021-02-20 10:42:11 +05:30
contrapunctus b2d431d17e [hydra] create multiple cursors hydra 2021-02-20 04:55:55 +05:30
contrapunctus 4f314d8e2b [hydra] make a heading for each hydra 2021-02-20 02:10:34 +05:30
contrapunctus 6e2e5ad0b9 [lisp] move configuration to init.org; move hydras to hydra section 2021-02-20 01:36:37 +05:30
contrapunctus 08dc18aef0 [unicode] fix prefix error 2021-02-19 22:03:24 +05:30
contrapunctus 0ee81a4b78 [dvorak] add comments and TODOs 2021-02-19 21:28:27 +05:30
contrapunctus dd17e95b00 [hydra] change find-file binding to "u" 2021-02-19 21:04:06 +05:30
contrapunctus bfe8eda872 [hydra] move all hydras in one spot 2021-02-19 13:43:53 +05:30
contrapunctus f11e94eada [boon] keep old QWERTY keys for repeat, undo, and redo 2021-02-19 13:05:10 +05:30
contrapunctus 36a3a0e2b7 [dvorak] define some Boon-like keys 2021-02-19 12:56:09 +05:30
contrapunctus b44e750e19 [hydra] change "s" for save to QWERTY "s"/Dvorak "o" 2021-02-19 12:11:08 +05:30
contrapunctus 71dea8ca97 Merge branch 'production' into dvorak-rebinding 2021-02-19 09:04:49 +05:30
contrapunctus 3d96157b72 [hydra] make heads consistent 2021-02-19 09:04:02 +05:30
contrapunctus 275ac0d6db [dvorak] initial key rebindings 2021-02-19 04:04:51 +05:30
contrapunctus 56e1920b72 [emms] rename hydra, add to general hydra 2021-02-19 03:01:06 +05:30
contrapunctus 71482262f9 [keyswap] disable swapping of numbers and symbols everywhere 2021-02-19 02:58:20 +05:30
contrapunctus 2ef56ee0d1 [common lisp] add generally-useful commands to hydra 2021-02-19 02:55:40 +05:30
contrapunctus f017b173a6 Reinstate keyswap-mode 2021-02-19 02:09:40 +05:30
contrapunctus c60c0a544a [emacs-lisp] create unit test Hydra 2021-02-18 17:47:24 +05:30
contrapunctus 3f25c80773 [projectile] move configuration to init.org 2021-02-18 17:45:17 +05:30
contrapunctus 74a95a8207 Try to use keyswap-mode 2021-02-18 17:33:42 +05:30
contrapunctus 9e9d07e7a0 Move applications into one heading 2021-02-18 15:04:54 +05:30
contrapunctus 08fad863e1 [hydra] add TODO items 2021-02-18 13:55:14 +05:30
contrapunctus b3989c495f [org] create navigation hydra 2021-02-18 12:23:40 +05:30
contrapunctus 1d37f1e853 [org] move configuration to init.org 2021-02-18 10:56:52 +05:30
contrapunctus dad20b4938 [literate] fix init errors, reinstate literate-elisp 2021-02-18 10:49:05 +05:30
contrapunctus 359b524228 [magit] define boon-like keys everywhere 2021-02-18 10:02:08 +05:30
contrapunctus 9179e7e765 [hydra] define line display hydra 2021-02-18 10:00:03 +05:30
contrapunctus 2c2d9a4dc0 [hydra] make window hydra color red 2021-02-17 23:43:22 +05:30
contrapunctus 35afcc1320 [hydra] add window resizing commands to window hydra 2021-02-17 22:28:53 +05:30
contrapunctus 48cc0bc0fe [hydra] add window hydra, rename cp/prog-hydra 2021-02-17 22:10:54 +05:30
contrapunctus 487c829e89 [unicode] easier insertion of em dash and Rupee sign 2021-02-17 19:54:49 +05:30
contrapunctus 4e8150ac87 [magit] add Boon-like keys for magit-diff-mode-map 2021-02-17 19:40:28 +05:30
contrapunctus 5a8b148716 [hydra] add commands for init, launch, dired-jump, save 2021-02-17 19:37:53 +05:30
contrapunctus 5caab2fd5e [boon/ido] fix "failed to define function ido-mini" error 2021-02-17 19:04:55 +05:30
contrapunctus 8b7f07a993 [programming] absorb config in init.org, create general hydra 2021-02-17 19:04:27 +05:30
contrapunctus 71e989bd82 [boon/ido] fix keybinding errors 2021-02-17 16:23:38 +05:30
contrapunctus 5c7d2ee9c9 [literate] add/remove newlines in output 2021-02-17 16:21:33 +05:30
contrapunctus 3835a3e300 [ido] move config to init.org 2021-02-17 15:42:43 +05:30
contrapunctus f1a22bc836 [literate] use sed to tangle the file instead of literate-elisp 2021-02-17 15:36:17 +05:30
contrapunctus 5f23271b6e [boon] remove error-creating (un)binding 2021-02-17 15:04:11 +05:30
contrapunctus 3ab054b204 [literate] add sed snippet 2021-02-17 15:03:54 +05:30
contrapunctus 140216084a [literate] cleanup syntax gore 2021-02-17 14:53:39 +05:30
contrapunctus f9c258960a [boon] bind J and M to ido-mini
I now have ido-mini (buffer-switching + recentf files) on "J" and "M",
and my 'superhydra' on "m". Nearly all commonly-used controls, with
scarcely any movement away from the home row.
2021-02-17 01:31:26 +05:30
contrapunctus 59479e0ec7 [org] add keybinding to evaluate literate Elisp buffer 2021-02-17 01:30:14 +05:30
contrapunctus 626968a27a [literate] improve structure, define TODO keywords 2021-02-16 23:24:41 +05:30
contrapunctus b133ed1f74 [literate] exclude Org files from .gitignore 2021-02-16 20:26:36 +05:30
contrapunctus c6fcec9b81 [literate] absorb 4 files into init.org 2021-02-16 20:25:24 +05:30
contrapunctus bcd8d2aabe [literate] convert init.el to literate Org program 2021-02-16 19:06:47 +05:30
contrapunctus 59746777a0 [prog] remove = and M-= as prog-hydra bindings
I vastly prefer the closeness of m and " - indeed, switching to the
new keys took nearly no time.
2021-02-16 17:59:20 +05:30
contrapunctus 8cdd40e47a [elisp] disable explain-pause-mode 2021-02-16 17:52:15 +05:30
contrapunctus 1987c26155 [elisp] bind macrostep 2021-02-16 17:47:19 +05:30
contrapunctus 0f038b4d41 [org] don't auto-export literate files 2021-02-16 17:45:15 +05:30
contrapunctus a8f1ec8f1b [feather] reactivate package, now that we are running Emacs 27 2021-02-16 17:42:52 +05:30
contrapunctus fe3f531fdf [browse-url] automatically copy URLs 2021-02-16 17:40:48 +05:30
contrapunctus b6ec8c3cfe [magit] define boon-like keys for magit-revision-mode-map 2021-02-16 17:32:40 +05:30
contrapunctus cdc5a65cc8 [counsel] don't use standard completion for find-file
Didn't work too well.
2021-02-16 17:31:34 +05:30
contrapunctus 0f112d8b70 [org] fix type error 2021-02-16 14:26:43 +05:30
contrapunctus 382b5afb62 [ediff] use IO for previous-next diff 2021-02-16 13:22:47 +05:30
contrapunctus c8fe4b5880 [cp-chronometrist] make code denser, make function a command 2021-02-15 16:48:37 +05:30
contrapunctus 498af2eec4 [cp-chronometrist] generate new buffer name for each process 2021-02-15 16:48:00 +05:30
contrapunctus 1399161e20 [cp-chronometrist] add tangling functions 2021-02-15 16:46:34 +05:30
contrapunctus 27673a62e5 [cp-chronometrist] update to reflect refactoring 2021-02-15 16:41:13 +05:30
contrapunctus 38973d6892 [cp-prog] try new bindings for prog-hydra 2021-02-15 16:39:58 +05:30
contrapunctus 65d9b22cf6 [cp-prog] remove Cask condition for Emacs Lisp hydra 2021-02-15 16:25:56 +05:30
contrapunctus 5119a791f4 [cp-org] indent cursor at the end of cp-org-insert-src 2021-02-15 06:16:08 +05:30
contrapunctus 3b10f4c876 [cp-org] jump to heading in cp-org-set-tags 2021-02-15 06:13:34 +05:30
contrapunctus bc7ceca83e [cp-org] indent closing element of cp-org-insert-src 2021-02-15 06:12:33 +05:30
contrapunctus 78c6df891c [cp-org] fix completion in cp-org-set-tags 2021-02-15 06:01:30 +05:30
contrapunctus e145d26111 [cp-org] insert current tags in cp-org-set-tags 2021-02-14 20:31:37 +05:30
contrapunctus 1d734204de [cp-org] use completing-read-multiple for org-set-tags 2021-02-14 20:16:35 +05:30
contrapunctus 20fb4ce44a [cp-org] add tree-modification commands to Org Hydra 2021-02-14 20:15:03 +05:30
contrapunctus c1e368f6de [cp-org] add tree-movement commands to Org Hydra 2021-02-14 19:41:01 +05:30
contrapunctus fe110460f4 [cp-org] add magit and elpher to Org Hydra 2021-02-14 17:29:55 +05:30
contrapunctus 82accd9f24 [cp-org] create Org Hydra 2021-02-14 17:26:56 +05:30
contrapunctus 239b0863f9 [compile] always kill existing compilation processes 2021-02-11 22:45:41 +05:30
contrapunctus 25f09793fb [cp-lisp] configure remote Lisp path translation 2021-02-11 22:43:05 +05:30
contrapunctus c492cce26a Switch to new theme 2021-02-11 20:17:04 +05:30
contrapunctus b5b1611432 Prefix cl-lib symbols 2021-02-11 19:27:11 +05:30
contrapunctus 7ce3f523df Suppress warning for list-timers 2021-02-11 19:18:49 +05:30
contrapunctus d532f3fede cp-prog - add CL documentation Hydra 2021-02-10 13:23:11 +05:30
contrapunctus 4c3e6bc989 cp-prog - improve language detection 2021-02-10 13:19:54 +05:30
contrapunctus dc8a0b8a01 Org - fix cp/org-open 2021-02-02 23:39:25 +05:30
contrapunctus a5b2eec153 chronometrist - add auto-revert-mode to chronometrist-sexp-mode-hook 2021-02-02 23:38:50 +05:30
contrapunctus 2a692004e5 org - simplify and correct cp/org-open 2021-01-31 16:42:13 +05:30
contrapunctus bf736679f7 Define command to insert date 2021-01-30 20:19:20 +05:30
contrapunctus 2bca55b1f0 Org - add gemini:// link support 2021-01-30 20:18:57 +05:30
contrapunctus 4038acb2b1 Disable ivy for find-file 2021-01-30 20:18:28 +05:30
contrapunctus c8016a52ea Move elisp-related packages to cp-prog-elisp 2021-01-09 12:32:24 +05:30
contrapunctus 9d8adbe095 Update Video editing actions 2021-01-08 00:34:31 +05:30
contrapunctus ba046e7ef1 prog hydra - fix language detection 2020-12-25 18:51:41 +05:30
contrapunctus 7619322ee5 chronometrist - update contrapunctus-start-project 2020-12-21 20:27:28 +05:30
contrapunctus e835da7679 Make code denser 2020-12-21 20:24:51 +05:30
contrapunctus c8bb07edbc cp-prog - make language detection more accurate 2020-12-21 20:23:55 +05:30
contrapunctus 5caadc7c32 Use new Lilypond build script 2020-12-21 20:23:16 +05:30
contrapunctus 09bf8e10c3 Add workarounds for TLS issues; disable Feather till they are fixed
feather (probably via async.el) runs external Emacs processes with -Q,
so no user/site Elisp workarounds help - all package operations fail
with "bad request".
2020-12-21 20:21:40 +05:30
contrapunctus b56e602b44 Use avy 2020-12-21 20:19:55 +05:30
contrapunctus 73524d6add chronometrist now has its own plist pretty printer 2020-12-21 20:19:15 +05:30
contrapunctus 5106026cb3 Add Hydra for Prolog 2020-12-13 17:40:29 +05:30
contrapunctus bcc08a6009 Add bindings for Elpher 2020-11-30 12:35:07 +05:30
contrapunctus b132f37560 Programming Hydra - add "other language", Guile Hydra 2020-11-28 20:26:33 +05:30
contrapunctus 746f3808e3 Use man instead of woman (latter breaks in some cases, like tables) 2020-11-11 13:39:35 +05:30
contrapunctus 36efbe1c32 Use ox-texinfo 2020-10-20 12:46:55 +05:30
contrapunctus 945f95484a cp/prog-hydra - add consistent key for dired-mode 2020-09-14 22:26:19 +05:30
contrapunctus ce5cac93f4 chronometrist - use ppp.el 2020-09-14 22:26:00 +05:30
contrapunctus d029095c17 run-transformers - update library name 2020-09-14 22:25:20 +05:30
contrapunctus c33d015718 chronometrist-goal - rename source directory 2020-09-14 22:23:52 +05:30
contrapunctus 257ac0ce19 Chronometrist - add case for video editing 2020-09-14 22:23:26 +05:30
contrapunctus fece1e2c02 Boon - add view-mode to special modes 2020-09-14 22:04:03 +05:30
contrapunctus 3c5ac34924 Magit - add some Boon-like keys 2020-09-14 22:01:29 +05:30
contrapunctus 310e932257 chronometrist-goal - remove hooks
No longer needed - they're added automatically by chronometrist-goal-minor-mode.
2020-09-07 16:21:16 +05:30
contrapunctus 0012d63282 chronometrist - clean up config 2020-09-07 11:43:47 +05:30
contrapunctus 29ca170aaf chronometrist - reflect switch to transformers + minor-mode 2020-09-07 11:40:38 +05:30
contrapunctus 5c2e2939db Make commit-prompt shorter (thanks pjb), add docstring 2020-08-29 23:46:49 +05:30
contrapunctus 364bdb91c6 chronometrist - add skip query functions 2020-08-29 23:46:06 +05:30
contrapunctus 471c800444 Run markdown-cleanup-list-numbers only in Markdown buffers 2020-08-29 10:46:05 +05:30
contrapunctus 3e05a12a93 Move iedit configuration to cp-editing.el 2020-08-28 13:31:48 +05:30
contrapunctus 263ca28214 Add key for abort-recursive-edit 2020-08-27 18:27:30 +05:30
contrapunctus 3b0a2fda2e chronometrist-goal-list - rename "Music theory" -> "Theory" 2020-08-24 18:27:32 +05:30
contrapunctus d810ee8829 Disable nodejs-repl, keyfreq 2020-08-24 18:20:40 +05:30
contrapunctus c40e595963 Don't delete trailing whitespace in markdown-mode 2020-08-19 21:55:03 +05:30
contrapunctus f8f91e898f Require confirmation for storing cookies
Trying to find out what caused them to be stored. I was just editing
some Markdown files! :\
2020-08-16 13:12:20 +05:30
contrapunctus 2e5b35bb18 CL - add keybinding for slime-documentation 2020-08-16 13:08:57 +05:30
contrapunctus eec465bd9c Mail - don't hard wrap email I write 2020-08-16 13:08:38 +05:30
contrapunctus 76a001d5c4 Markdown - fix list numbers automatically 2020-08-16 13:07:29 +05:30
contrapunctus 9048840ba5 Add binding for package-autoremove 2020-08-16 13:06:52 +05:30
contrapunctus e23b388a86 Performance - set lower gc limit when init completes 2020-08-06 20:50:16 +05:30
contrapunctus eea6f28dfc Boon - add more modes to boon-special-mode-list 2020-08-05 09:14:58 +05:30
contrapunctus deb636fdbc cp-emms - fix hydra warning, try to set up nicer playlist display 2020-08-05 09:13:37 +05:30
contrapunctus 496d4c9f95 Fix company-emoji loading
It used to work before 🤔
2020-08-05 09:09:55 +05:30
contrapunctus 88ed14e903 Remove :ensure declarations
init time 38s -> 24s
2020-08-05 09:09:55 +05:30
contrapunctus 8e141e7d50 cp-lisp - use :hook for Nameless hooks 2020-08-05 09:01:07 +05:30
contrapunctus 1c3a20d981 cp-fm - remove unused packages 2020-08-05 08:59:32 +05:30
contrapunctus 35ec536ab9 Add irony-eldoc, rtags 2020-08-05 08:59:07 +05:30
contrapunctus 3a3b055ba1 exec-path-from-shell - don't initialize at startup 2020-08-05 00:06:01 +05:30
contrapunctus 500f662e6a cp-lisp - remove unnecessary :defer, try to reduce init time 2020-08-04 19:59:00 +05:30
contrapunctus 862a35eeb1 Remove redundant keybinding definition
It's already defined in (use-package ag ...)
2020-08-04 17:09:05 +05:30
contrapunctus 6d86dba673 Comment out incorrect heuristics from cp-prog hydra 2020-08-04 17:08:21 +05:30
contrapunctus 55c5972a56 cp-cl - add hydra for evaluation commands 2020-08-04 17:06:11 +05:30
contrapunctus 28364bcaf5 Configure feather-mode correctly 2020-08-04 16:56:30 +05:30
contrapunctus 45ba38a017 Use local Git version of sxiv 2020-08-04 16:52:25 +05:30
contrapunctus 4f19cf5418 cp-lisp - convert auto-mode forms to use-package 2020-08-04 16:51:44 +05:30
contrapunctus 08c9857489 Use esup 2020-08-04 16:50:30 +05:30
contrapunctus 0315397647 Formally start using cp-mail 2020-07-30 21:41:39 +05:30
contrapunctus 44bae71c91 chronometrist-goal - moved config to separate form 2020-07-30 21:41:05 +05:30
contrapunctus de9e0a1951 init - reindent setq values 2020-07-24 16:45:52 +05:30
contrapunctus fe10739658 Configure ediff separately 2020-07-24 16:45:26 +05:30
contrapunctus a2f353e6bc cp-ui - reindent setq values 2020-07-24 16:45:15 +05:30
contrapunctus 6feaf2b212 cp-ui - don't lazy load 2020-07-24 16:44:54 +05:30
contrapunctus 29ced6d946 Change --map to cl-loop to address "mapcar for effect" warning 2020-07-24 16:16:35 +05:30
contrapunctus 726c8f7644 Move Emacs Lisp configuration to its own file 2020-07-24 16:16:35 +05:30
contrapunctus 3575fce0bf Remove load-path loop and unused packages; add provide calls 2020-07-24 16:16:35 +05:30
contrapunctus 1473eb35c0 clean-buffer-list - clean up more aggressively
Another attempt to keep RAM usage down.
2020-07-24 16:16:35 +05:30
contrapunctus 6f9477fee9 Prevent more Boon navigation keys from being shadowed in eww mode 2020-07-24 16:16:35 +05:30
contrapunctus 1c7ccce6ee C mode - add keys for Company 2020-07-24 16:16:35 +05:30
contrapunctus 8148a6cfe0 dired - add binding for dired-omit-mode 2020-07-24 16:16:35 +05:30
contrapunctus e5c044b132 desktop - rewrite using cl-loop; disable restoring buffers
An attempt at reducing RAM use and startup time.
2020-07-24 16:16:35 +05:30
contrapunctus 8c2667ff9c Org/Boon - promote/demote with c ,/c . 2020-07-24 16:16:35 +05:30
contrapunctus 541a5ed49a cp/org-open - fix arity error 2020-07-24 16:16:35 +05:30
contrapunctus 6581adfb5b prog-hydra - use Elisp hydra in ielm-mode 2020-07-24 16:16:35 +05:30
contrapunctus af875d35c3 Create cp-prog-c for C config; move Company config to cp-prog 2020-07-24 16:16:35 +05:30
contrapunctus 7eb1db6a00 line truncation - rewrite using cl-loop 2020-07-24 16:16:35 +05:30
contrapunctus c306008d8b cp/org-open - rewrite to work with visual lines 2020-07-24 16:16:35 +05:30
contrapunctus bb6aa9c5f1 Use prefix for personal function - re-search-line -> cp/re-search-line 2020-07-24 16:16:35 +05:30
contrapunctus 924701987d chronometrist - remove grep from Programming hook
I hadn't used that for anything since I added it...not once.
2020-07-20 15:04:41 +05:30
contrapunctus 104a072b5e EMMS - don't use emms-cache (RAM hog); refactor playlist config 2020-07-20 15:04:41 +05:30
contrapunctus 0f403744a1 elisp - stop running tests on save
It was irritating as hell, a lot of the time - simply because they
were passing. I'd rather use my prog-mode hydra for it.
2020-07-20 00:52:49 +05:30
contrapunctus 99d0040b7a Disable peep-dired and explain-pause-mode
I don't need them too often; peep-dired makes a big mess of my buffer
list; explain-pause-mode's log takes up precious memory.
2020-07-18 19:19:23 +05:30
contrapunctus 80f285fab3 Add better binding for chronometrist
I'm a little surprised - how is it not already there?! I was using
this whole time! 🤔
2020-07-15 10:34:23 +05:30
contrapunctus b6bd3fb53a contrasync - update to suit new configuration format 2020-07-15 10:31:31 +05:30
contrapunctus e15cf7722b Stop using visual-fill-column-mode for programming 2020-07-15 10:30:51 +05:30
contrapunctus 712629e882 Add peep-dired, better keys for marked file navigation 2020-07-15 10:29:30 +05:30
contrapunctus 8b21495d01 chronometrist - use my local repo, not the packaged version!
So that I can test my changes through my everyday use.
2020-07-08 23:31:21 +05:30
contrapunctus ce2d8d64d7 chronometrist - change to reflect package and function renames 2020-07-07 13:23:59 +05:30
contrapunctus e8166212b9 Use Elpher 2020-07-07 13:23:37 +05:30
contrapunctus c9c4b438e8 Add config to try visual-fill-column-mode in prog-mode 2020-07-07 13:20:50 +05:30
contrapunctus 11ec549da5 Move hook setup for visual-fill-column-mode to its own use-package body 2020-07-04 16:20:12 +05:30
contrapunctus aea3cee8c1 midnight - clean buffers more aggressively
Emacs becomes the mot memory-heavy program on my computer, after a
while. Let's see if this helps.
2020-07-03 19:23:56 +05:30
contrapunctus 3372af7b34 chronometrist - refine expression counting code 2020-06-29 16:58:26 +05:30
contrapunctus 99a336c44b Try using visual-fill-column mode for Magit 2020-06-29 12:17:17 +05:30
contrapunctus 42c51fde54 chronometrist - write a function to count expressions in the file
Counting chronometrist-events is not accurate, since the s-expressions
in it are split. And I've needed - and rewritten - this enough times
that it's finally time to write it for good.
2020-06-29 12:15:50 +05:30
contrapunctus 831f5645df rsync -> contrasync - update to reflect name change of package 2020-06-25 18:36:54 +05:30
contrapunctus b3c642f12d dired - don't need to hide owners and groups anymore
...now that I have dired-hide-details-mode
2020-06-22 15:54:06 +05:30
contrapunctus 5db52d78ab cp-fm - re-enable dired-hide-dotfiles
I noticed that dotfiles were still hidden; then realized I had
modified dired-listing-switches; let's see how it performs now.
2020-06-20 10:46:39 +05:30
contrapunctus 445a51a38f rsync - add directories, reduce duplication 2020-06-19 21:12:27 +05:30
contrapunctus d446a65b4e cp-prog - use locate-dominating-file instead of file-exists-p
This way, it even works if you're in a file in a subdirectory.
2020-06-19 21:11:27 +05:30
contrapunctus bbf989c594 Use require/provide for cp-md 2020-06-19 13:02:17 +05:30
contrapunctus bdb603cddd Add rudimentary rsync.el configuration, use require/provide for cp-fm 2020-06-17 23:49:21 +05:30
contrapunctus 3c7f1ffbcd Merge branch 'test' of Dell-Vostro-15-3000:/home/anon/.emacs.d into test 2020-06-16 18:28:45 +05:30
contrapunctus 33c93db6ef Stop using dired-hide-dotfiles-mode
It slowed down loading of Dired buffers more than I like.
2020-06-16 18:25:38 +05:30
contrapunctus 3710274303 Org - add drag line commands to autoload 2020-06-16 18:25:35 +05:30
contrapunctus 3d4fb66c6d Boon - add sldb-mode to special-mode-list 2020-06-16 18:25:35 +05:30
contrapunctus 178adb4087 prog-hydra - add Common Lisp hydra 2020-06-16 18:25:35 +05:30
contrapunctus 04305ef006 Move slime configuration to use-package 2020-06-16 18:25:35 +05:30
contrapunctus 92a7a0f37f Diminish feather and explain-pause-mode 2020-06-16 18:25:05 +05:30
contrapunctus f4d34f9120 Migrate help-mode and Unicode keys to use-package/general 2020-06-16 18:25:05 +05:30
contrapunctus c3031c69af Org - add drag line commands to autoload 2020-06-15 20:20:24 +05:30
contrapunctus 5ef600fa17 Boon - add sldb-mode to special-mode-list 2020-06-15 20:18:23 +05:30
contrapunctus 0d3f4f6d5b prog-hydra - add Common Lisp hydra 2020-06-15 20:18:06 +05:30
contrapunctus 39ee037abd Move slime configuration to use-package 2020-06-15 20:17:30 +05:30
contrapunctus 52e922ac86 Diminish feather and explain-pause-mode 2020-06-12 21:46:07 +05:30
contrapunctus 83c6ca2362 Migrate help-mode and Unicode keys to use-package/general 2020-06-12 20:02:04 +05:30
contrapunctus 9b0aba7dc3 wgrep is not immediately essential, change it to use-package 2020-06-12 19:42:22 +05:30
contrapunctus 30436e3e53 Convert load calls to require 2020-06-12 19:42:15 +05:30
contrapunctus 843d250189 Setting the coding system to utf-8 is still necessary on some systems 2020-06-10 12:02:50 +05:30
contrapunctus 36d24dfc56 Use visual-fill-column in Org documents 2020-06-10 12:02:32 +05:30
contrapunctus 71c2e55cb2 use-package/sxiv - define keys correctly 2020-06-10 12:02:03 +05:30
contrapunctus 41d383eaa8 Fix keybinding nuisance 2020-06-10 12:00:11 +05:30
contrapunctus a84d005c10 prog-hydra - add Magit to Lilypond Hydra 2020-06-08 02:01:26 +05:30
contrapunctus da7496cfdc boon - change keybindings to suit layout with swapped () and [] 2020-06-08 02:00:25 +05:30
contrapunctus 53b02a7ad4 Add explain-pause-mode, exec-path-from-shell 2020-06-07 15:05:51 +05:30
contrapunctus 8878cf5555 Remove dot-mode
It never quite worked as well as I would like.
2020-06-04 20:22:10 +05:30
contrapunctus dc29614d36 Use adaptive-wrap for Markdown, org-indent for Org 2020-06-04 20:21:35 +05:30
contrapunctus fbceb51e55 Elisp - use defun indentation style for cl-loop 2020-06-01 17:58:40 +05:30
contrapunctus 6f61909e84 Use shackle-mode; show info docs in the same window
I often open info docs from the Helpful buffer, which tends to open
them in the other window (hiding my source code!)
2020-06-01 15:55:27 +05:30
contrapunctus 79aa35b052 prog hydra - add Lilypond hydra, dired-mode keybind
We make cp/compile-elisp-project more general, so it's now called cp/compile-project.
2020-05-29 12:23:32 +05:30
contrapunctus e3bfabd743 chronometrist - update file name 2020-05-29 12:11:55 +05:30
contrapunctus 0a99b92bbd prog hydra - add help and xref bindings 2020-05-29 09:08:49 +05:30
contrapunctus 95761f034c programming hydra - fix clean command 2020-05-29 09:05:53 +05:30
contrapunctus b48197aaf8 programming hydra - add magit to sub-hydras 2020-05-28 17:22:51 +05:30
contrapunctus 42a0383049 programming hydra - use a better key for defun
"ee" feels easier than "ed"
2020-05-28 17:17:59 +05:30
contrapunctus 4ea48dff71 programming hydra - add Cask build/clean, buttercup tests 2020-05-28 17:16:08 +05:30
contrapunctus bd7483a3b1 programming hydra - detect modes, add Elisp eval and debug 2020-05-28 16:51:11 +05:30
contrapunctus 1199f32145 Make hydras for programming-related bindings 2020-05-28 15:57:37 +05:30
contrapunctus 05f7c2e6d1 Be smarter about compile commands
Don't reuse the last command in the history (it can be anything, even
something not related to the current mode) - use M-x recompile for
that, or press g in the compilation buffer.
2020-05-28 12:17:37 +05:30
contrapunctus d86bbd1a58 Add binding for list-packages, settle on Feather over Paradox 2020-05-28 12:11:59 +05:30
contrapunctus cb36d638a1 Use feature-mode for .feature files 2020-05-27 15:21:11 +05:30
contrapunctus 1fa7d1b617 Try feather-mode
It doesn't seem to work if paradox is loaded.
2020-05-27 15:20:01 +05:30
contrapunctus 28bebfff06 Chronometrist activity indicator - move to named function 2020-05-23 23:13:40 +05:30
contrapunctus c8e2173150 cp-fm - remove unused code 2020-05-23 23:08:36 +05:30
contrapunctus e70e1e6d5f Projectile/Boon - permit \ to be inserted, too 2020-05-23 23:05:54 +05:30
contrapunctus 25bbd4bd45 Use projectile 2020-05-21 19:45:52 +05:30
contrapunctus dfa375b2a1 ivy - ignore search term order 2020-05-21 19:41:00 +05:30
contrapunctus 17c3cc12d8 Move emr config to cp-lisp 2020-05-21 19:40:47 +05:30
contrapunctus c22116d92d Remove seconds-to-hms
It is called within chronometrist-format-time now
2020-05-21 19:31:13 +05:30
contrapunctus e99193846d swiper - enable recentering after selection 2020-05-18 00:39:29 +05:30
contrapunctus 1d5c976e48 Run chronometrist-query-stop when exiting
For some reason, this wasn't being added to the hook.
2020-05-18 00:38:25 +05:30
contrapunctus 0ba21c76aa Replace personal hack with dired-hide-dotfiles-mode 2020-05-15 21:29:57 +05:30
contrapunctus 8bdf9d242b Add bindings to try outline-mode in Elisp buffers 2020-05-15 19:59:28 +05:30
contrapunctus 9d039c4eb9 elisp - use company for completion 2020-05-14 17:54:16 +05:30
contrapunctus 98d9a350ed Update to reflect function rename 2020-05-14 17:53:09 +05:30
contrapunctus ed49fbff4d Use lilypond-mode from Git 2020-05-14 06:53:46 +05:30
contrapunctus b85eb33b42 swiper - fix config error 2020-05-14 06:53:42 +05:30
48 changed files with 6362 additions and 3197 deletions

4
.gitignore vendored
View File

@ -1,4 +1,8 @@
*
!*.org
!*.el
!contrapunctus
!snippets
!snippets/*
!snippets/*/*
.*

34
Makefile Normal file
View File

@ -0,0 +1,34 @@
.phony: all setup tangle lint clean
all: setup tangle lint
setup:
emacs --batch --eval="(package-initialize)" \
--eval="(mapcar #'package-install '(indent-lint package-lint relint))"
# No -q or -Q, in case the user has a newer version of Org.
init-org.el:
emacs --batch \
--eval="(require 'ob-tangle)" \
--eval='(org-babel-tangle-file "init.org")'
tangle: init-org.el
lint-check-declare: tangle
emacs -q -Q --batch --eval='(check-declare-file "init.el")'
lint-checkdoc: tangle
emacs -q -Q --batch --eval='(checkdoc-file "init.el")'
lint-package-lint: setup tangle
emacs -Q --batch --eval='(package-initialize)' \
--eval="(require 'package-lint)" \
-f 'package-lint-batch-and-exit' "init.el"
lint-relint: setup tangle
emacs -q -Q --batch --eval='(relint-file "init.el")'
lint: lint-check-declare lint-checkdoc lint-package-lint lint-relint
clean-tangle:
-rm init.el

24
UNLICENSE Normal file
View File

@ -0,0 +1,24 @@
This is free and unencumbered software released into the public domain.
Anyone is free to copy, modify, publish, use, compile, sell, or
distribute this software, either in source code form or as a compiled
binary, for any purpose, commercial or non-commercial, and by any
means.
In jurisdictions that recognize copyright laws, the author or authors
of this software dedicate any and all copyright interest in the
software to the public domain. We make this dedication for the benefit
of the public at large and to the detriment of our heirs and
successors. We intend this dedication to be an overt act of
relinquishment in perpetuity of all present and future rights to this
software under copyright law.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
IN NO EVENT SHALL THE AUTHORS BE LIABLE FOR ANY CLAIM, DAMAGES OR
OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
OTHER DEALINGS IN THE SOFTWARE.
For more information, please refer to <https://unlicense.org>

15
bookmarks Normal file
View File

@ -0,0 +1,15 @@
;;;; Emacs Bookmark Format Version 1 ;;;; -*- coding: utf-8-emacs -*-
;;; This format is meant to be slightly human-readable;
;;; nevertheless, you probably don't want to edit it.
;;; -*- End Of Bookmark File Format Version Stamp -*-
(("rec"
(filename . "/media/data/phone/contrapunctus/Nokia 6.1/Android/data/net.osmand.plus/files/tracks/rec/")
(front-context-string . " /media/data/ph")
(rear-context-string)
(position . 1))
("screenshots"
(filename . "/media/data/contrapunctus/Pictures/screenshots/")
(front-context-string . " /media/data/co")
(rear-context-string)
(position . 1))
)

View File

@ -1,195 +0,0 @@
(use-package chronometrist
:ensure t
:load-path "~/.emacs.d/contrapunctus/chronometrist"
:hook
(chronometrist-kv-read-mode . visual-line-mode)
(kill-emacs-query-functions . chronometrist-query-stop)
:bind ("<f9>" . #'chronometrist)
;; (:map chronometrist-mode-map
;; ("RET" . #'chronometrist-toggle-project-no-reason)
;; ("M-RET" . #'chronometrist-toggle-project)
;; ([mouse-1] . #'chronometrist-toggle-project-no-reason)
;; ([mouse-3] . #'chronometrist-toggle-project))
:config
(require 'chronometrist-goals)
(setq chronometrist-goals-list
'((15 "Arrangement/new edition")
(15 "Aural exercises")
(15 "Transcription"
"Music theory")
(30 "Composing"
"Writing"
"Recording")
(15 "Data organization"
"Physical organization"
"Khilona archiving")
(60 "Exercise")
(120 "Guitar")
(90 "Reading")
(60 "Singing")
(20 "Subtitles")
(15 "Acting")
(30 "Keyboard")
(15 "Wikisource"))
alert-default-style 'libnotify
chronometrist-before-in-functions '()
chronometrist-after-in-functions '(;; chronometrist-tags-add
;; chronometrist-kv-add
contrapunctus-start-project
chronometrist-goals-run-alert-timers)
chronometrist-before-out-functions '(contrapunctus-before-project-stop
chronometrist-tags-add
chronometrist-kv-add)
chronometrist-after-out-functions '(contrapunctus-after-project-stop
chronometrist-goals-stop-alert-timers)
chronometrist-activity-indicator
(lambda ()
(thread-first (chronometrist-last-expr)
(plist-put :stop (chronometrist-format-time-iso8601))
chronometrist-interval
cadr
chronometrist-seconds-to-hms
(chronometrist-format-time "")))))
(defun contrapunctus-find-two-files-other-window (file-1 file-2)
"Open FILE-1 and FILE-2 in new windows.
FILE-1 will appear above FILE-2."
(find-file-other-window file-2)
(split-window-below)
(find-file file-1))
(defun cp-outline-open-heading (n)
(goto-char (point-min))
(outline-next-visible-heading n)
(outline-show-subtree))
(defun contrapunctus-start-project (project)
(delete-other-windows)
(pcase project
("Arrangement/new edition"
(find-file-other-window "~/Documents/Text Files/music_stuff/arrange.org"))
("Composing"
(find-file-other-window "~/1-music-notation/2-my-compositions/2019/2019-03 Kahe Natak Karte Ho Ji/Kahe Natak Karte Ho Ji?.org")
(cp-outline-open-heading 1))
("Data organization"
(find-dired "~/" "-name \'dl\' -size +0c"))
("Exercise"
(let* ((path-1 "~/Documents/Text Files/ma/practice.org")
(path-2 "~/Documents/Text Files/ma/0shoto-syllabus.org")
(file-1 (file-name-nondirectory path-1))
(file-2 (file-name-nondirectory path-2)))
(contrapunctus-find-two-files-other-window path-1 path-2)
(select-window (get-buffer-window file-1))))
("Guitar"
(let* ((path-1 "~/Sync/Scores/guitar-solo/repertoire.org")
(path-2 "~/Sync/Scores/guitar-duo/repertoire.org")
(weekday (elt (decode-time) 6))
(week (string-to-number (format-time-string "%U"))))
(contrapunctus-find-two-files-other-window path-1 path-2)
(select-window (get-buffer-window (get-file-buffer path-1)))
(org-match-sparse-tree nil "perform")))
("Keyboard"
(find-file-other-window "~/Documents/Text Files/music_stuff/piano.org")
(outline-show-subtree))
("Khilona archiving"
(find-file-other-window "/home/anon/Documents/sync/Khilona/")
(split-window-below)
(other-window 1)
(find-file "/home/anon/Khilona/Videos/Me?/")
(other-window 1)
(find-file "/home/anon/Documents/Text Files/khilona/2011 Me?/script/script.tex"))
("OSM"
;; (async-shell-command "java -jar ~/josm-tested.jar" " *JOSM*" " *JOSM errors*")
;; (delete-window (get-buffer-window " *JOSM*"))
(contrapunctus-find-two-files-other-window "~/phone/Nokia 6.1/Android/data/net.osmand.plus/files/"
;; "~/phone/Nokia 6.1/external/DCIM/OpenCamera/osm/"
"~/phone/Nokia 6.1/Documents/Markor/OSM/TODO.md"))
;; https://github.com/bbatsov/emacs-lisp-style-guide#comment-annotations
("Programming"
(grep (->> '("grep" "--color" "-EnHiIR" "-e '(TODO|FIXME|OPTIMIZE|HACK|REVIEW)'"
"--exclude=\"*.html\""
"--exclude-dir=\".git\""
"~/.emacs.d/contrapunctus/"
"~/Documents/Text\\ Files/programming/")
(-interpose " ")
(apply #'concat)))
(switch-to-buffer "*grep*")
(split-window-below)
(other-window 1)
(find-file "~/phone/Nokia 6.1/Documents/Markor/Computers/todo.md")
(delete-other-windows))
("Singing"
(find-file-other-window "~/Sync/Scores/voice/repertoire.org"))
("Subtitles"
(find-file-other-window "~/Music/0-classical/vocal/musical/Company/"))
("Theatre rehearsal"
(contrapunctus-find-two-files-other-window
"~/Documents/Text Files/khilona/voices.org"
"~/1-music-notation/2-my-compositions/2019/2019-03 Kahe Natak Karte Ho Ji/Kahe Natak Karte Ho Ji.org"))
("Transcription"
(find-file-other-window "~/phone/Nokia 6.1/Documents/Markor/Music/transcriptions.md"))
("Wiktionary"
(find-file-other-window "~/phone/Nokia 6.1/Documents/Markor/Languages/hindi.md"))
("Writing"
(find-file-other-window "/home/anon/phone/Nokia 6.1/Documents/Markor/Songs or Poems/"))))
(autoload 'magit-anything-modified-p "magit")
(defun contrapunctus-commit-prompt ()
(if (magit-anything-modified-p)
(if (yes-or-no-p
(concat "You have uncommitted changes in "
default-directory
". Really clock out? "))
t
(magit-status)
nil)
t))
(defun contrapunctus-before-project-stop (project)
(if (member project '("Composing"
"Khilona archiving"
"Programming"))
(contrapunctus-commit-prompt)
;; all functions in `chronometrist-before-project-stop-functions'
;; must return t for successful clock-out
t))
(require 'request)
(require 'esxml-query)
(defun contrapunctus-after-project-stop (project)
(pcase project
("OSM"
(delete-other-windows)
;; What should we do when there's no network connectivity?
;; Ideally - note the clock-out time, and retry every five
;; minutes. When connected, request the changesets, look for the
;; first changeset with a "created_at" which is less than the
;; clock-out time.
(request
"https://api.openstreetmap.org/api/0.6/changesets"
:params '(("display_name" . "contrapunctus"))
:parser (lambda () (libxml-parse-xml-region (point) (point-max)))
:success
(cl-function
(lambda (&key data &allow-other-keys)
(let* ((latest-changeset (-> data
(esxml-node-children)
(car)))
(comment (->> latest-changeset
(esxml-query "[k=comment]")
(esxml-node-attributes)
(cdr)
(car)
(cdr)))
(id (-> latest-changeset
(esxml-node-attributes)
(car)
(cdr))))
(chronometrist-append-to-last-expr nil
`(:osm-url ,(concat "https://www.openstreetmap.org/changeset/" id)
:osm-comment ,comment)))))))
(_ (delete-other-windows))))
(provide 'cp-chronometrist)

View File

@ -1,47 +0,0 @@
(use-package desktop
:init (desktop-save-mode t)
:config
(setq desktop-dirname "~/.emacs.d/desktop-save/"
desktop-save 'ask-if-new)
(-map (lambda (element)
(add-to-list 'desktop-globals-to-save element))
'(grep-history
grep-find-history
find-args-history
extended-command-history
read-expression-history
default-input-method
input-method-history
query-replace-history
compile-history
string-rectangle-history
regexp-history
dired-shell-command-history
dired-regexp-history
shell-command-history
org-tags-history
minibuffer-history
erc-server-history-list
cp/activity-history
LaTeX-environment-history)))
(desktop-save-mode t)
;; (add-to-list 'desktop-locals-to-save 'comint-input-ring)
(desktop-auto-save-enable)
(defun cp/backup-desktop-file ()
(let ((new-filename (->> (shell-command-to-string "date -Is")
(replace-regexp-in-string "\n" "")
(concat "~/.emacs.d/.emacs.desktop."))))
(copy-file "~/.emacs.d/.emacs.desktop" new-filename)))
(defun cp/cleanup-desktop-backups ()
(let ((desktop-file-backups (-> (concat "find ~/.emacs.d/ -maxdepth 1 -type f |"
" grep -E \"\.emacs\.desktop\.[0-9]{4}-[0-9]{2}-[0-9]{2}T[0-9]{2}:[0-9]{2}:[0-9]{2}[-+]?[0-9]{2}:?[0-9]{2}\"")
(shell-command-to-string )) )))
(if (> 10 )))
;; ;; this one created loads and loads of backups
;; (add-hook 'desktop-save-hook 'cp/backup-desktop-file)
;; ;; not enough space for this - wasteful
;; (add-hook 'kill-emacs-hook 'cp/backup-desktop-file)
(provide 'cp-desktop)

View File

@ -1,283 +0,0 @@
;;;; Editing improvements
;; fix Emacs' definition of a sentence
(setq sentence-end-double-space nil)
;; the utter basics
(general-define-key
"C-h" 'backward-delete-char
"C-w" 'backward-kill-word
"C-u" 'cp-kill-line-0
;; A better solution would be to hack kill-line/kill-visual-line to
;; kill the region if a region is active. The flexibility of those
;; functions is very desirable - you can delete from point to line
;; end, clear a line to enter some other text on it (C-a C-k/"a k"),
;; or delete one or more whole lines (C-1 C-k/"1 k" or C-<num>
;; C-k/"<num> k").
"C-y" 'whole-line-or-region-yank
"C-S-k" 'whole-line-or-region-kill-region
"C-," 'backward-paragraph
"C-." 'forward-paragraph
"C-<" 'beginning-of-buffer
"C->" 'end-of-buffer)
(define-key isearch-mode-map (kbd "C-h") 'isearch-delete-char)
(defun cp-kill-line-0 ()
(interactive)
(kill-line 0))
(global-unset-key (kbd "C-x C-r"))
(general-define-key
:prefix "C-x C-r"
"C-i" 'string-insert-rectangle
"C-r" 'replace-rectangle
"C-k" 'kill-rectangle)
(defun cp/downcase-dwim (arg)
"Like `downcase-word', but if region is active, run
`downcase-region' instead. Unlike `downcase-region', rectangular
regions are handled correctly as well.")
;; open-line should always move to the beginning of the current line
;; first, so one can run it anywhere. I also want it to indent it to
;; the next or the previous line...
;; These affect org-meta-return and org-insert-heading-respect-content
;;
;; (defadvice open-line
;; (before open-line-bol activate)
;; (beginning-of-visual-line))
;; (defadvice open-line
;; (after open-line-indent activate)
;; (if (not (looking-at "\\** "))
;; (indent-for-tab-command)))
;; (global-set-key (kbd "C-o") 'open-line)
(defun cp/open-line ()
"The opposite of `cp/open-line-before'. Start a new line below
the current line, regardless of where point is in the current
line. Will not affect the content of the current line. Applies
the correct indentation according to the mode."
(interactive)
(progn
(end-of-line)
(electric-indent-just-newline t)
(indent-according-to-mode)))
(defun cp/open-line-before (arg)
"Like `open-line' but a bit more sane.
In org-mode, run org-open-line.
In other modes, insert a newline above the current line,
regardless of where point is in current line. Will not affect
content of current line. Applies the correct indentation
according to the mode."
(interactive "p")
(if (and (equal major-mode 'org-mode)
(org-at-table-p))
(org-open-line arg)
(progn
(beginning-of-line)
(electric-indent-just-newline t)
(forward-char -1)
(indent-according-to-mode))))
(global-set-key (kbd "C-o") 'cp/open-line-before)
;; I wish you could press e.g. S-o in god-mode to get C-S-o.
;; 10/10 would make life better.
(global-set-key (kbd "C-S-o") 'cp/open-line)
(setq dired-bind-jump nil)
(global-set-key (kbd "C-x C-j") 'join-line)
;; C-z (suspend-frame) is utterly useless and disruptive - good place to put universal-argument
(global-unset-key (kbd "C-z"))
(global-set-key (kbd "C-z") 'universal-argument)
(global-set-key (kbd "C-x C-z") 'repeat)
(global-set-key (kbd "C-x C-;") 'repeat-complex-command)
;; (defun cp-kill-line (&optional arg)
;; (interactive)
;; (if arg
;; (if mark-active
;; (kill-region arg)
;; (kill-line arg))
;; (if mark-active
;; (kill-region)
;; (kill-line))))
;; (global-set-key (kbd "C-k") 'cp-kill-line)
;; Chris Done (god-mode) recommends this, but Emacs' repeat command is almost useless...
;; (global-set-key (kbd "C-.") 'repeat)
;;;; I like the transpose commands
(global-unset-key (kbd "C-t"))
(general-define-key
:prefix "C-t"
"C-t C-c" 'transpose-chars
"C-t C-w" 'transpose-words
"C-t C-l" 'transpose-lines
"C-t C-s" 'transpose-sentences
"C-t C-e" 'transpose-sexps
"C-t C-p" 'transpose-paragraphs)
(global-set-key (kbd "C-M-h") 'er/expand-region)
(use-package dot-mode
:disabled
:hook (text-mode prog-mode LilyPond-mode)
:bind (:map dot-mode-map
("C-." . nil)
("M-." . dot-mode-execute)
("C-M-." . nil)))
(add-hook 'before-save-hook 'delete-trailing-whitespace)
(require 'flex-isearch)
(flex-isearch-mode 1)
(general-define-key
"C-M-s" 'flex-isearch-forward
"C-M-r" 'flex-isearch-backward)
(with-eval-after-load 'iedit
(define-key iedit-mode-keymap (kbd "C-h") 'backward-delete-char))
(with-eval-after-load 'markdown-mode
(defun cp/copy-md-link (prefix-arg)
"Copy address of Markdown link after point in the current line.
If there is no link in the current line, or if the region is
active, or with a prefix arg - call
whole-line-or-region-kill-ring-save instead."
(interactive "P")
(save-excursion
(if (or (use-region-p)
prefix-arg
(not (re-search-line
;; 2018-03-21T22:47:55+0530 - fix bug where a line with parenthesized text would not be copied
;; "\("
;; 2018-07-22T10:20:03+0530
;; "\\[.*?\\](.*?)"
"\\[.*?\\]("
)))
(whole-line-or-region-kill-ring-save prefix-arg)
(let ((point-a (point)))
(forward-char -1)
(forward-sexp)
(copy-region-as-kill point-a (- (point) 1))))))
(cp-set-keys
:keymap markdown-mode-map
:bindings
`((,(kbd "M-w") cp/copy-md-link)
(,(kbd "TAB") markdown-cycle)
(,(kbd "C-c C-.") markdown-demote)
(,(kbd "C-c C-,") markdown-promote)
(,(kbd "C-c C-l") markdown-insert-link))))
(defun cp/copy-bus-entry ()
"For personal use, when working between Markdown and the OSM wiki."
(interactive)
(let ((point-a (region-beginning))
(point-b (region-end))
(point-b-line (line-number-at-pos)))
(query-replace "[ ]" "" nil point-a point-b)
(query-replace "[x]" "" nil point-a point-b)
(query-replace-regexp "^- " "" nil point-a point-b)
(goto-char (point-min))
(forward-line (- point-b-line 1))
(copy-region-as-kill point-a (point-at-bol))))
;; 2018-08-21T03:41:47+0530
(defun cp/copy-md-link (prefix-arg)
"Copy address of Markdown link after point in the current line.
If there is no link in the current line, or if the region is
active, or with a prefix arg - call
whole-line-or-region-kill-ring-save instead."
(interactive "P")
(save-excursion
(cond
((or (use-region-p) prefix-arg)
(whole-line-or-region-kill-ring-save prefix-arg))
((re-search-line "\\[.*?\\](")
(let ((point-a (point)))
(forward-char -1)
(forward-sexp)
(copy-region-as-kill point-a (- (point) 1))))
((re-search-line "http")
(kill-new (thing-at-point 'url)))
(t (whole-line-or-region-kill-ring-save prefix-arg)))))
;; 2018-08-28T22:50:43+0530
(defun cp/copy-buffer ()
(interactive)
(copy-region-as-kill (point-min) (point-max)))
(use-package multiple-cursors
:bind (("C-M-l" . #'mc/mark-previous-like-this-symbol)
("C-M-;" . #'mc/mark-next-like-this-symbol)
("C-M-'" . #'mc/mark-all-symbols-like-this)
("C-M-," . #'mc/mark-previous-word-like-this)
("C-M-." . #'mc/mark-next-word-like-this)
("C-M-/" . #'mc/mark-all-words-like-this)
("C-M-<" . #'mc/unmark-previous-like-this)
("C-M->" . #'mc/unmark-next-like-this)
("C-M-]" . #'mc-hide-unmatched-lines-mode)))
(defun cp/marked-files->markup-links-org (filenames)
(mapcar (lambda (filename)
(let ((link-pre "[[file:")
(link-post "][]]\n"))
(concat link-pre filename link-post)))
filenames))
(defun cp/marked-files->markup-links-md (filenames)
(mapcar (lambda (filename)
(if (member (downcase
(file-name-extension filename))
image-file-name-extensions)
(let ((link-pre "![](")
(link-post ")\n"))
(concat link-pre filename link-post))
(let ((link-pre "[](")
(link-post ")\n"))
(concat link-pre filename link-post))))
filenames))
;; BUG - (dired-get-marked-files) returns file name at point if none are marked
;; BUG - (dired-get-marked-files) always returns an alphabetically-sorted list, even when the Dired buffer is sorted by date
(defun cp/marked-files->markup-links ()
"From a Dired buffer, insert the file at point or marked files
as links into an Org or Markdown document."
(interactive)
(if (derived-mode-p 'dired-mode)
(let* ((filenames (dired-get-marked-files 'no-dir))
(other-buffer (->> (window-list)
(cadr)
(window-buffer)))
(other-buffer-mode (with-current-buffer other-buffer major-mode))
(two-window-op (and (= (length (window-list)) 2)
(member other-buffer-mode
'(org-mode markdown-mode))))
(output-buffer (if two-window-op
other-buffer
(read-buffer "Insert links in buffer: ")))
(output-mode (with-current-buffer output-buffer major-mode))
(output-text (case output-mode
('org-mode
(cp/marked-files->markup-links-org filenames))
('markdown-mode
(cp/marked-files->markup-links-md filenames))
(t (error "Only Markdown and Org are currently supported.")))))
(if two-window-op
(other-window 1)
(switch-to-buffer output-buffer))
(mapc #'insert output-text))
(user-error "Run this command from a Dired buffer with some marked files."))
(when markdown-inline-image-overlays
(markdown-display-inline-images)))

View File

@ -1,79 +0,0 @@
;; TODO - make toggle command for emms-start/emms-stop
;; TODO - change mode line display - don't show the whole file path, just the name
(use-package emms
:ensure t
:bind
("<f2> e" . #'hydra-emms/body)
("<f2> E" . #'emms)
(:map emms-playlist-mode-map
("0" . #'emms-volume-raise)
("9" . #'emms-volume-lower)
("<up>" . #'emms-volume-raise)
("<down>" . #'emms-volume-lower)
("<left>" . #'emms-seek-backward)
("<right>" . #'emms-seek-forward)
("n" . #'next-line)
("p" . #'previous-line)
("N" . #'emms-next)
("P" . #'emms-previous)
("R" . #'emms-toggle-random-playlist)
("M-n" . #'emms-cue-next)
("M-p" . #'emms-cue-previous)
("SPC" . #'emms-pause))
(:map dired-mode-map
("E" . #'hydra-emms/body))
:commands (emms-all
emms
emms-play-dired
emms-add-dired)
:config (emms-all)
(emms-default-players)
(setq emms-player-mpv-parameters
(lambda ()
(append
'("--fs"
"--quiet"
"--really-quiet"
"--force-window=yes"
"-ao=jack,alsa"
;; "--loop-file=inf"
)
(let* ((dir (->> (emms-playlist-current-selected-track)
(alist-get 'name)
(file-name-directory)))
(subs-in-dir (f-glob "*.srt" dir))
(subs-in-subdir (f-glob "*/*.srt" dir)))
(->> (append subs-in-dir subs-in-subdir)
(-interpose ":")
(append '("--sub-files="))
(apply #'concat)
(list))))))
;; This won't work for `emms-random', because it runs in a `save-excursion'
;; (add-to-list 'emms-playlist-selection-changed-hook 'emms-playlist-mode-center-current)
;; (--map (add-to-list 'emms-player-mpv-parameters it)
;; '("--fs"))
(defun contrapunctus-emms-toggle-player ()
(interactive)
(if emms-player-stopped-p
(emms-start)
(emms-stop)))
(setq emms-playlist-buffer-name "EMMS Playlist")
:init (defhydra hydra-emms ()
("e" #'emms "EMMS")
("n" #'emms-next "Next")
("p" #'emms-previous "Previous")
("SPC" #'emms-pause "Pause")
("s" #'contrapunctus-emms-toggle-player "Start/Stop")
("0" #'emms-volume-raise)
("9" #'emms-volume-lower)
("<up>" #'emms-volume-raise)
("<down>" #'emms-volume-lower)
("<left>" #'emms-seek-backward)
("<right>" #'emms-seek-forward)
("l" #'emms-play-dired "Play file (dired)")
("a" #'emms-add-dired "Add file (dired)")
("A" #'emms-add-directory-tree "Add directory")
("u" #'emms-play-url)))
(provide 'cp-emms)

View File

@ -1,87 +0,0 @@
(use-package evil
:disabled
:init (evil-mode 1)
;; Want something to switch between evil and god-mode, instead of this.
;; They say there's a plugin for it...
:bind
(("C-x e" evil-mode)
;;(global-set-key (kbd "g C-g") 'count-words-region)
(:map evil-normal-state-map
&allow-other-keys(;; ("<tab>" forward-button)
("zR" . 'yafolding-show-all)
("zM" . 'yafolding-hide-all)
("zo" . 'yafolding-show-element)
("zc" . 'yafolding-hide-element)
;; The story so far - in evil-normal-state-map, I set 'i' to
;; evil-previous-visual-line, 'k' to evil-next-visual-line,
;; 'j' to evil-backward-char. Note that I forgot to set 'h'
;; to insert at first...but that's not all - later I realized
;; this didn't affect Visual mode :p 4 more lines for that.
;; Next...d/c didn't work with ijkl. 4 more lines for
;; evil-operator-state-map. After that - you usually want
;; visual-line up/down movement, but _not_ when you hit d-j/k
;; (or d-i/k)! So, in evil-operator-state-map, i and k are
;; now vanilla evil-previous/next-line. Set gi/gk to
;; evil-previous/next-line in normal and visual states, and
;; to evil-previous/next-visual-line in operator state - 2
;; new lines to each group of 4.
("gi" . evil-previous-visual-line)
("gk" . evil-next-visual-line)
( "i" . evil-previous-line)
( "k" . evil-next-line)
( "j" . evil-backward-char)
( "h" . evil-insert)))
:map evil-visual-state-map
("gi" evil-previous-visual-line)
("gk" evil-next-visual-line)
("i" evil-previous-line)
("k" evil-next-line)
("j" evil-backward-char)
("h" evil-insert)
:map evil-operator-state-map
("gi" evil-previous-visual-line)
("gk" evil-next-visual-line)
("i" evil-previous-line)
("k" evil-next-line)
("j" evil-backward-char)
("h" evil-insert)
;; evil-inner-tag ?
("hW" evil-inner-WORD)
("hw" evil-inner-word)
("h\(" evil-inner-paren)
("h\)" evil-inner-paren)
("h\{" evil-inner-curly)
("h\}" evil-inner-curly)
("h<" evil-inner-angle)
("h>" evil-inner-angle)
("h\[" evil-inner-bracket)
("h\]" evil-inner-bracket)
("hs" evil-inner-sentence)
("hp" evil-inner-paragraph)
("h`" evil-inner-back-quote)
("h\"" evil-inner-double-quote)
("h'" evil-inner-single-quote)
:map evil-motion-state-map
("gi" evil-previous-visual-line)
("gk" evil-next-visual-line)))
;;;; set C-h to backspace when editing commands and searching
(defun kill-start-of-line ()
"Kill from point to start of line."
(interactive)
(kill-line 0))
(define-key evil-insert-state-map (kbd "C-u") 'kill-start-of-line))
;;;; evil-snipe
(with-eval-after-load 'evil-snipe
(setq evil-snipe-count-scope 'letters)
;; This doesn't take two chars by default, which combined with
;; unimplemented evil-snipe-count-scope 'vertical makes it nearly
;; useless as a replacement for fFtT;
(evil-snipe-replace-evil)
(global-evil-snipe-mode 1))
(evil-mode)

View File

@ -1,423 +0,0 @@
;; -*- lexical-bindiing: t; -*-
;; TODO - function which deletes buffers (esp. files and dired buffers) above a certain size. Then, set that to a timer.
;;;; File management
(add-to-list 'load-path "~/.emacs.d/elisp-git/dired-toggle-sudo/")
(add-to-list 'load-path "~/.emacs.d/elisp-git/project-explorer/")
(use-package dired
:init (add-hook 'dired-mode-hook 'turn-on-launch-mode)
:config
(setq dired-listing-switches
;; by date
;; "-cgGhlt --group-directories-first --time-style=long-iso"
;; by name
"-cgGhl --group-directories-first --time-style=long-iso"
;; no -h
;; "-cgGl --group-directories-first --time-style=long-iso"
;; by date, no --group-directories-first
;; "-cgGhlt --time-style=long-iso"
)
:bind (("<f2> s" . sxiv)
:map dired-mode-map
("W" . wdired-change-to-wdired-mode)
("e" . #'cp/dired-do-ediff)
;; after learning that this copies whole paths with null
;; argument, this became a whole lot more useful
("C-w" . dired-copy-filename-as-kill)
("C-c C-f" . cp/corresponding-text-file)
("h" . cp/dired-toggle-hidden)
([mouse-2] . cp/dired-launch-or-open)
("C-j" . launch-files-dired)
("j" . launch-files-dired)
("M-s r" . dired-do-query-replace-regexp)
("M-s s" . dired-do-isearch-regexp)
("P" . emms-play-dired)
("I" . 'sxiv)
("X" . 'dired-do-flagged-delete))
:hook (dired-mode . (lambda () (dired-hide-details-mode t))))
(use-package dired-async
:init (dired-async-mode 1))
(use-package dired-x
:commands dired-jump
:bind ("C-x C-d" . dired-jump))
;; TODO - make launch-file suggest the path at point by default
(use-package launch
:commands turn-on-launch-mode launch-files-dired
:bind ("s-l" . launch-file))
(defun cp/open-random-file (&optional find-args dir cmd)
"Open a random file in DIR, prompting the user for it if not supplied."
(interactive)
(let* ((find-args (if find-args find-args " -type f "))
(dir (if dir dir
(read-directory-name "Directory: "
(if file-name-history
(car file-name-history)
default-directory)
nil t)))
(file-name (--> (expand-file-name dir)
(concat "find " "\"" it "\" "
find-args " | shuf | sed 1q")
(shell-command-to-string it)
(replace-regexp-in-string "\n" "" it))))
(if cmd
(async-shell-command (concat cmd " \"" file-name "\""))
(find-file file-name))))
(with-eval-after-load 'project-explorer
(global-set-key (kbd "<f5> e") 'project-explorer-toggle))
;; (require 'sudo-edit)
(defun cp/dired-ffmpeg (&optional format)
(interactive)
(let ((files (-map #'shell-quote-argument (dired-get-marked-files t)))
(format (if format format "mp3")))
(--map (let* ((fbasename (file-name-base it))
(new-name (concat fbasename "." format)))
(call-process "ffmpeg" nil "*dired-ffmpeg*" t
"-i" it "-ac" "2" "-f" format new-name))
files)))
(defvar cp/ffmpeg-max-processes 1
"Maximum number of simultaneous ffmpeg processes run by
`cp/dired-do-ffmpeg'. See also
`cp/ffmpeg-process-recount-interval'.")
(defvar cp/ffmpeg-process-recount-interval 10
"Time interval to check number of processes after, and maybe
start new processes. See TIME argument of `run-at-time' for
possible values.")
(defun cp/ffmpeg-process-count ()
(->>
(-map 'process-name (process-list))
(--count (string-match-p "^dired-ffmpeg" it))))
(defun cp/maybe-call-ffmpeg (shell-args)
(if (< (cp/ffmpeg-process-count) cp/ffmpeg-max-processes)
(apply 'start-process "dired-ffmpeg"
(generate-new-buffer-name "*dired-ffmpeg*")
"ffmpeg"
(split-string-and-unquote shell-args))
(run-at-time cp/ffmpeg-process-recount-interval
nil
(cp/maybe-call-ffmpeg shell-args))))
;; TODO - 1. process buffer does not update like ffmpeg run in the
;; terminal.
;; 2. don't make FORMAT arg compulsory - if omitted, create
;; unique file name based on original, with same extension
;; (`make-temp-name')
(defun cp/dired-do-ffmpeg (input-args output-args format)
"In Dired buffers, runs `ffmpeg' on each marked file, or, if no
marks are present, on the file at point.
Each input file will result in one output file. The output file
will have the same file name but FORMAT as the extension.
This command thus uses barely a fraction of what ffmpeg can do,
but hopefully it covers any and every one-file-in-one-file out
usage, which is most common for the author.
INPUT-ARGS and OUTPUT-ARGS can be left blank (\"\"). FORMAT is
presently necessary, and must not be the same as the input file.
ffmpeg must be installed on your system, of course."
(interactive "sInput arguments (optional) : \nsOutput arguments (optional) : \nsOutput format : ")
(let ((files (-map #'shell-quote-argument
(dired-get-marked-files t))))
(--map
(let* ((fbasename (file-name-base it))
(new-name (concat fbasename "." format))
(args (concat input-args " "
"-i " it " "
output-args " "
new-name)))
;; (with-output-to-temp-buffer "cp/dired-do-ffmpeg"
(cp/maybe-call-ffmpeg args)
;; )
)
files)))
;; (with-current-buffer "log"
;; (goto-char (point-max))
;; (insert
;; (concat
;; (propertize (format-time-string "%FT%T%z") 'face 'bold)
;; "\n"))
;; (start-file-process-shell-command "ls" "log" "ls -g ~/Urecord*")
;; (insert
;; (concat
;; "\n(cp/ffmpeg-process-count) - "
;; (number-to-string (cp/ffmpeg-process-count))
;; "\n(process-list) - \n"
;; (apply 'concat " " (-interpose "\n " (-map 'process-name (process-list))))
;; "\ntimer-list - \n"
;; (apply 'concat " " (-interpose "\n " (-map 'prin1-to-string timer-list)))
;; "\n\n"))
;; (set-window-point
;; (get-buffer-window "log")
;; (point-max))
;; (recenter))
;; (temp-buffer-window-show "*dired-ffmpeg*")
(defun cp/dired-do-ediff (&optional format)
"Ediff (first two or three) marked files."
(interactive)
(let* ((files (dired-get-marked-files t))
(file-1 (car files))
(files-dir default-directory))
;; 2018-04-08T11:31:20+0530 TODO - if there is only one marked
;; file, check the other window for a marked file and ediff with
;; that.
(case (length files)
(1 (progn
(other-window 1)
(let ((files2 (dired-get-marked-files t))
(files2-dir default-directory))
(if files2
(ediff (expand-file-name
(concat files-dir (car files)))
(expand-file-name
(concat files2-dir (car files2))))))))
(2 (ediff file-1
(cadr files)))
(t (ediff3 file-1
(cadr files)
(elt files 2))))))
;; (defvar count 0)
;; (defun timer-test (count)
;; (if (= count 5)
;; (progn
;; (message "count %s - finito" count)
;; (cancel-timer test-timer))
;; (progn
;; (message "incrementing count - %s" count)
;; (setq count (1+ count)))))
;; ;; works! -
;; (let ((a 1) (b 2))
;; (setq test-timer
;; (run-at-time 1 nil `(lambda () (message "%d" (+ ,a ,b))))))
;; ;; works
;; (let ((a 1))
;; (setq my-timer
;; (run-with-timer 5 5 (lambda ()
;; (message "I cancelled my-timer")
;; (cancel-timer my-timer)))))
;; ;; works
;; (setq my-timer
;; (run-with-timer 5 5 (lambda ()
;; (message "I cancelled my-timer")
;; (cancel-timer my-timer))))
;; ;; works
;; (defvar test t)
;; (defun process-queue ()
;; (if test
;; (progn
;; (message "process-queue says hi")
;; (run-with-timer 5 nil 'process-queue))
;; (message "process-queue says bye")))
;; (let ((a 1) (b 2) (time 5))
;; (setq test-timer
;; (run-at-time 5 5
;; `(lambda ()
;; (message "test-timer - %d" ,a)
;; (setq a (1+ ,a))))))
;; (progn
;; (run-at-time "2 sec" nil (lambda () (message "bye!")))
;; (message "hi!"))
(defun cp/nth-filename-this-line (&optional count)
(let ((file (buffer-substring-no-properties
(progn
(beginning-of-line)
(search-forward "/" nil t count)
(forward-char -1)
(point))
(or (progn
(re-search-forward " und /" (point-at-eol) t)
(re-search-backward " " nil t 2))
(progn
(re-search-forward " sind verschieden." (point-at-eol) t)
(re-search-backward " " nil t 2))
(- (point-at-eol) 1)))))
(if (file-exists-p file)
file
(replace-regexp-in-string ": " "/" file))))
(defun cp/copy-to-ehdd ()
"Copy files using file names from diff(1) output."
(interactive)
(re-search-forward "^Nur in /media/alpha/")
(let* ((file (cp/nth-filename-this-line))
(dest (replace-regexp-in-string "^/media/alpha/"
"/media/kashish-wd-1tb/alpha/"
file)))
(forward-line)
(if (file-directory-p file)
(copy-directory file dest t t t)
(copy-file file dest nil t t t))))
(defun cp/diff-ediff ()
(interactive)
(beginning-of-line)
(let ((file1 (cp/nth-filename-this-line))
(file2 (cp/nth-filename-this-line 2)))))
(defun cp/diff-show-file ()
(interactive)
(let ((file (cp/nth-filename-this-line)))
(dired-jump t file)
(message file)))
(with-eval-after-load 'diff-mode
(define-key diff-mode-map (kbd "C-o") 'cp/diff-show-file))
(defun cp/dired-update-all ()
(mapc (lambda (b)
(with-current-buffer b
(if (equal major-mode 'dired-mode)
(find-alternate-file (dired-current-directory)))))
(buffer-list)))
(defun cp/done-matches (&optional count)
(interactive "P")
(let ((case-fold-search nil)
(count (if count count 1)))
(flet ((done-matches-op
()
(when (re-search-forward "^/media/kashish-wd-1tb/alpha/kashish/new-stuff/7-music/playerdump/")
(let* ((para-start (progn
(re-search-backward "^[0-9]+ bytes each:$")
(point)))
(matches (progn (forward-line 1)
(count-lines (point)
(progn
(forward-paragraph)
(point))))))
(when (= matches 2)
(delete-region (point)
(progn
(forward-paragraph -1)
(point))))))))
(if (= count 0)
(while (not (eobp))
(done-matches-op))
(dotimes (i count)
(done-matches-op))))))
(defun cp/change-all-units ()
"for fdupes output"
(interactive)
(while (re-search-forward "^[0-9]+" nil t)
(shell-command-on-region (point-at-bol) (point) "numfmt --to=iec-i --suffix=B" nil t)
(forward-word)
(delete-region (point) (progn (forward-word) (point)))))
(defun cp/launch-file-archive ()
(interactive)
(launch-file
(concat
default-directory
(aref (archive-get-descr) 0))))
;; (define-key archive-mode-map (kbd "j") 'cp/launch-file-archive)
;; 2018-02-28T21:00:57+0530
(defun cp/corresponding-text-file ()
(interactive)
(save-excursion
(end-of-line)
(if (derived-mode-p 'dired-mode)
;; 2018-08-05T02:01:26+0530 - support directories too
(let* ((file-or-dir (dired-file-name-at-point))
(file (if (file-directory-p file-or-dir)
(replace-regexp-in-string "/$" "" file-or-dir)
file-or-dir)))
(find-file (concat file ".txt"))))))
;; 2018-06-23T09:57:34+0530
;; FIXME - probably very fragile, assumes a lot about dired-actual-switches
;; BUG - viewing hidden files is okay, but hiding them again never
;; seems to work without a find-alternate-file, which in turn
;; never seems to work non-interactively. Parts of dired-revert
;; seem relevant to this.
(defun cp/dired-toggle-hidden ()
"Toggle visibility of hidden files."
(interactive)
(if (string-match-p "-A" dired-listing-switches)
(setq dired-actual-switches
(replace-regexp-in-string "\\(-A\\).*\\'"
"-"
dired-listing-switches
nil nil 1))
(setq dired-actual-switches
(replace-regexp-in-string "\\(-\\).*\\'"
"-A"
dired-listing-switches
nil nil 1)))
;; (revert-buffer)
(dired-revert)
;; (find-alternate-file (dired-current-directory)) ;; no good at all
;; no good either
;; (let ((directory (dired-current-directory)))
;; (kill-this-buffer)
;; (dired directory))
)
;; 2018-07-09T23:22:17+0530
;; a little buggy wrt clicks
(defun cp/dired-launch-or-open (event)
(interactive "e")
;; if point is on a folder, open it with dired
;; otherwise, call launch-files-dired
(if (directory-name-p (dired-file-name-at-point))
(dired-find-file)
(launch-files-dired nil (dired-get-marked-files))))
(defun contrapunctus-delete-file-at-point (&optional prefix)
(interactive "P")
(let ((file (buffer-substring (point-at-bol)
(point-at-eol))))
(if (file-exists-p file)
(progn
(delete-file file)
(if prefix
;; delete current line
(delete-region (point-at-bol)
(1+ (point-at-eol)))
;; delete current paragraph
(mark-paragraph)
(delete-active-region)
(forward-line 2))
(message "Deleted %s" file))
(error "File %s does not exist!" file))))
(defun contrapunctus-file-at-point-exists-p ()
(interactive)
(let ((file (buffer-substring (point-at-bol)
(point-at-eol))))
(if (and (not (string-empty-p file))
(file-exists-p file))
(message "%s" t)
(error "File %S does not exist!" file))))

View File

@ -1,36 +0,0 @@
;; TODO - make mode-line indicator prominent by placing it first, like in Evil
(use-package god-mode
:disabled
:bind ("<escape>" . god-mode-all)
:init (god-mode-all)
:config
;; from https://github.com/chrisdone/god-mode#change-modeline-color
(defun c/god-mode-update-cursor ()
(cond (god-local-mode
(progn
(setq cursor-type 'box)
(set-face-background 'mode-line "black")
(set-face-background 'mode-line-inactive "black")))
(t
(progn
(setq cursor-type 'bar)
(set-face-background 'mode-line "dark red")
(set-face-background 'mode-line-inactive "dark red")))))
(add-hook 'god-mode-enabled-hook #'c/god-mode-update-cursor)
(add-hook 'god-mode-disabled-hook #'c/god-mode-update-cursor)
:custom
(god-exempt-major-modes nil)
(god-exempt-predicates nil))
;; for helm
;; (define-key helm-map (kbd "<escape>") 'god-local-mode)
(use-package god-mode-isearch
:bind
((:map isearch-mode-map
("<escape>" . god-mode-isearch-activate))
(:map god-mode-isearch-map
("<escape>" . god-mode-isearch-disable))))
(provide 'cp-god)

View File

@ -82,3 +82,5 @@
;; (gethash "ऩ्" (car indian-dev-itrans-v5-hash))
;; (gethash "न्ह" (car indian-dev-itrans-v5-hash))
;; (gethash "nh" (cdr indian-dev-itrans-v5-hash))
(provide 'cp-hindi)

View File

@ -31,13 +31,6 @@
:disabled
:bind ("M-x" . smex))
(use-package ido-mini
:bind (("C-x C-l" . ido-mini)
:map boon-x-map
("l" . ido-mini))
:config
(ivy-mode))
;; This creates a bug with shell completion if you're using ivy mode.
(unless (bound-and-true-p ivy-mode)
(setq completion-styles

View File

@ -1,165 +0,0 @@
;;;; Hacks for Lilypond work
(use-package lilypond-mode
:bind
(("C-c C-i" . LilyPond-info)
("M-]" . set-selective-display)
:map LilyPond-mode-map
("M-p" . cp-backward-def)
("M-n" . cp-forward-def)
("M-P" . cp-upper-level)
("M-N" . cp-lower-level)
("C-c C-w" . cp-ly-wrap-para))
:commands LilyPond-mode
:config
(--map (add-hook 'LilyPond-mode-hook it)
'(subword-mode
(lambda () (turn-on-font-lock))))
(defalias 'string-to-int #'string-to-number)
:load-path "../user/"
:mode (("\\.ly$" . LilyPond-mode)
("\\.ily$" . LilyPond-mode)))
(defvar cp/ly-definition-rx
'(and bol
(1+ (any "a-z" "A-Z" "\\\\"))
(1+ (any "a-z" "A-Z" "\\\\" " "))
(any "{" "=" "#")))
(defun cp-backward-def ()
(interactive)
(unless (region-active-p)
(push-mark))
(re-search-backward (rx-to-string cp/ly-definition-rx)
nil t)
(beginning-of-line)
(recenter))
(defun cp-forward-def ()
(interactive)
(let* ((regex (rx-to-string cp/ly-definition-rx))
(count (if (looking-at-p regex) 2 1)))
(unless (region-active-p)
(push-mark))
;; (forward-char)
(if (not (re-search-forward regex nil t count))
(re-search-forward "^}" nil t))
;; (re-search-forward "^[\\a-zA-Z]" nil t)
(beginning-of-line)
(recenter)))
;; (defun cp-backward-def ()
;; (interactive)
;; (re-search-backward "\(^\\\\?[a-zA-Z]\|^ *\\[a-zA-Z]\)")
;; (beginning-of-line))
;; (defun cp-forward-def ()
;; (interactive)
;; (forward-char)
;; (re-search-forward "\(^\\\\?[a-zA-Z]\|^ *\\[a-zA-Z]\)")
;; (beginning-of-line))
(defun cp-upper-level ()
(interactive)
(re-search-backward "{"))
(defun cp-lower-level ()
(interactive)
(if (equal (string (char-after)) "{")
(forward-char))
(if (not (re-search-forward "{"))
(message "At deepest level."))
(backward-char))
;; (defun cp-lilypond-enclose-<< ()
;; (interactive)
;; (if (equal (string (char-after)) "\\")
;; (progn (insert "<< ")
;; (search-forward "{")
;; (backward-char)
;; (forward-sexp))))
;; if at a \new ... block - enclose expression
;; otherwise, enclose current position and after the first bar check
;; found
;; if region is active, enclose beginning and end
;; (defun cp-lilypond-enclose-<< ()
;; (interactive)
;; (if (equal (thing-at-point 'sexp)
;; "\\new")
;; (progn ;; (insert "<< ")
;; (newline-and-indent)
;; (search-forward "{")
;; (backward-char)
;; (forward-list)
;; ;; (forward-sexp))
;; )
;; ;; (let ((point1 (point)))
;; ;; (next-line)
;; ;; (goto-char point1))
;; ))
;; (define-key LilyPond-mode-map (kbd "<<")
;; 'cp-lilypond-enclose-<<)
;; If I change files, it's still main.ly that gets compiled; this is
;; good most of the time, but many times I want to compile a part-*
;; file instead. If we compile both main.ly and the respective part-*
;; file every time, it's wasteful. Having to select means giving up
;; the 'effortless-compilation' behaviour.
;; 2017-03-14T00:52:07+0530 - commented out, see cp/after-save
;; (defadvice LilyPond-save-buffer
;; (after lysb activate)
;; ;; (compile "make")
;; (cd (locate-dominating-file (buffer-file-name)
;; "main.ly"))
;; (compile (car compile-history)))
;;
;; (defadvice compile
;; (before compile activate)
;; (if (equal major-mode 'LilyPond-mode)
;; (cd (locate-dominating-file (buffer-file-name)
;; "main.ly"))))
;; TODO - refactor into one COND, with one case per operation.
;; TODO - operate on region as well.
(defun cp-ly-wrap-para (arg)
"Wrap current paragraph with -
\\relative c { ... } with no args,
\\repeat { ... } with universal argument,
and only braces - { ... } - with null argument.
Numeric arg wraps that many paragraphs.
TODO - wrap region if region active"
(interactive "P")
(let ((point-a (point)))
(beginning-of-line)
(unless (looking-at "[[:blank:]]*$")
;; go to start of paragraph or block, or previous blank line
(re-search-backward (rx (or (and bol (0+ blank) eol)
(and "{" eol))))
(end-of-line))
(newline-and-indent)
(insert (pcase arg
(`(,x) "\\repeat {")
(0 "{")
;; nil
(_ "\\relative c {")))
(let ((indent-start (point)))
(forward-paragraph (pcase arg
(`(,x) 1)
(_ (if (and arg (<= arg 0))
1 arg))))
(indent-region indent-start (point))
(insert "}")
(indent-for-tab-command)
(newline)
;; FIXME
(goto-char (pcase arg
(0 point-a)
(_ (- indent-start 2)))))))
;; TODO - cp-ly-new-var, bind to M-RET.
;; Exits current variable body, if in any, and inserts "| = \relative
;; c {\n\n \n}", where | is the cursor

View File

@ -1,97 +0,0 @@
;; (require 'chicken)
(setq print-length nil
eval-expression-print-length nil)
;; (require 'slime)
(require 'slime-autoloads)
(global-set-key (kbd "<f5> s") 'slime)
(with-eval-after-load 'slime
(slime-setup)
(setq inferior-lisp-program
;; "/usr/bin/sbcl"
"/usr/bin/ecl"
)
(cp-set-keys
:keymap slime-mode-map
:bindings
`((,(kbd "M-n") next-line)
(,(kbd "M-p") previous-line)
(,(kbd "SPC") self-insert-command))))
(defun set-cl-repl-keys ()
(if (or (cp-buffer-name-match-p "^\*inferior-lisp\*\\(<[0-9]*>\\)?")
(eq major-mode 'lisp-mode))
(progn
(local-set-key (kbd "TAB") 'completion-at-point)
(local-set-key (kbd "M-q") 'sp-indent-defun))))
(add-hook 'slime-connected-hook 'set-cl-repl-keys)
(add-hook 'comint-mode-hook 'set-cl-repl-keys)
(add-hook 'lisp-mode-hook 'set-cl-repl-keys)
(setq scheme-program-name "csi -:c")
(setq comint-prompt-read-only t)
(add-to-list 'auto-mode-alist '("\\.scm\\'" . scheme-mode))
;; (add-to-list 'auto-mode-alist '("\\.scm\\'" . geiser-mode))
;; (require 'geiser)
(use-package geiser
:commands (run-chicken run-guile geiser-mode))
;; (with-eval-after-load 'geiser-mode
;; (setq geiser-mode-smart-tab-p t)
;; (define-key geiser-mode-map (kbd "C-.") nil)
;; ;; (cp-set-keys
;; ;; :unset t
;; ;; :keymap geiser-mode-map
;; ;; :bindings
;; ;; `((,(kbd "C-."))))
;; )
(use-package scheme-mode
:defer t
:interpreter "csi")
(defun contrapunctus-lisp-copy (arg)
"Run `whole-line-or-region-copy-region-as-kill' if region is
active, else `sp-copy-sexp'."
(interactive "P")
(if (region-active-p)
(whole-line-or-region-copy-region-as-kill arg)
(sp-copy-sexp arg)))
(use-package elisp-mode
:diminish
:bind (:map emacs-lisp-mode-map
("<tab>" . completion-at-point)))
(use-package eldoc
:diminish
:if (featurep 'elisp-mode)
:init (add-hook 'emacs-lisp-mode-hook 'eldoc-mode)
:config (setq eldoc-idle-delay 0))
(defun colorize-compilation-buffer ()
(ansi-color-apply-on-region compilation-filter-start
(point)))
(add-hook 'compilation-filter-hook 'colorize-compilation-buffer)
(update-file-autoloads "~/.emacs.d/elisp-git/clojure-mode/clojure-mode.el"
t
"~/.emacs.d/elisp-git/clojure-mode/clojure-autoloads.el")
(load "clojure-autoloads")
;; (autoload 'clojure-mode "clojure-mode" nil t)
(with-eval-after-load "clojure-mode"
(require 'cider))
(use-package nameless
:ensure t
:commands nameless-mode
:init
(add-hook 'emacs-lisp-mode-hook 'nameless-mode)
(add-hook 'ert-results-mode-hook 'nameless-mode)
:bind (:map emacs-lisp-mode-map
("C-c C-n" . nameless-mode)))
(provide 'cp-lisp)

View File

@ -1,52 +0,0 @@
;; 2018-05-16T17:22:36+0530
(add-hook 'markdown-mode-hook '(lambda () (visual-fill-column-mode t)))
(add-hook 'markdown-mode-hook '(lambda () (visual-line-mode t)))
;; (add-hook 'markdown-mode-hook '(lambda () (turn-off-smartparens-mode)))
(use-package markdown-mode
:mode "\\.md\\'"
:init (add-hook 'markdown-mode-hook 'markdown-display-inline-images)
:config (setq markdown-command "cmark"
markdown-css-paths '("style.css")
markdown-display-remote-images t
markdown-max-image-size '(500 . 500)
;; reflows text to suit different screens
markdown-xhtml-header-content
(concat "<meta name=\"viewport\" "
"content=\"width=device-width, "
"initial-scale=1.0, "
"user-scalable=yes\" />"))
(when (featurep 'boon)
(general-def markdown-mode-map
"C-c ," 'markdown-promote
"C-c ." 'markdown-demote
"C-c C-e" 'markdown-export))
(setq-default ;; markdown-hide-markup t ;; has a bug with heading cycling
markdown-hide-urls t)
:bind
(:map markdown-mode-map
;; ("M-n" . org-drag-element-forward)
;; ("M-p" . org-drag-element-backward)
;; ("C-c C-o" . markdown-follow-link-at-point)
("M-n" . markdown-move-down)
("M-p" . markdown-move-up)
("C-c C--" . org-cycle-list-bullet)
([mouse-1] . markdown-cycle)
("C-c C-c C-n" . markdown-cleanup-list-numbers)
("C-c C-x C-n" . markdown-next-link)
("C-c C-x C-p" . markdown-previous-link)
("C-c C-h C-u" . #'markdown-toggle-url-hiding)
("C-c C-h C-m" . #'markdown-toggle-markup-hiding)
("C-c C-h C-i" . #'markdown-toggle-inline-images)
("C-c C-r" . #'reverse-region)))
(defun cp/copy-line-or-md-link (prefix-arg)
(interactive "P")
(save-excursion
(beginning-of-line)
(if (looking-at-p ".*http")
(progn
(re-search-line "http")
(forward-char -4)
(kill-new (thing-at-point 'url))))))

View File

@ -1,133 +0,0 @@
;; modal editing configurations
;; normal boon config
(use-package boon
:ensure t
:commands (boon-mode)
:bind
(:map boon-command-map
("C-l" . recenter-top-bottom)
("r" . swiper)
("/" . undo-tree-undo)
("?" . undo-tree-redo)
("G" . join-line) ;; mnemonic - Glue (I'd like to bind J and
;; : to sentence movement once I extend
;; Boon to select by sentence movement)
;; ("TAB" . 'company-indent-or-complete-common)
("C" . 'boon-toggle-comment)
("t" . nil)
("t w" . 'transpose-words)
("t e" . 'transpose-sexps)
("t l" . 'transpose-lines)
("t p" . 'transpose-paragraphs)
("t c" . 'transpose-chars))
(:map boon-x-map
("w" . 'write-file)
("s" . 'save-buffer)
("d" . 'dired-jump)
("e" . 'eval-last-sexp)
("f" . 'find-file)
("l" . 'ido-mini)
("c" . 'kill-emacs)
("v" . 'find-alternate-file)
("b" . 'ibuffer)
("=" . text-scale-adjust)
("-" . text-scale-adjust))
:config
(use-package boon-qwerty)
(add-to-list 'boon-enclosures `(40 "(" ")")) ;; 40 = (
(use-package boon-powerline)
(boon-powerline-theme)
(mapc (lambda (mode)
(add-to-list 'boon-special-mode-list mode))
'(emms-playlist-mode
emms-browser-mode
edebug-mode))
(add-to-list 'boon-special-conditions '(bound-and-true-p edebug-mode))
;; :hook
;; ((text-mode . turn-on-boon-mode)
;; (prog-mode . turn-on-boon-mode)
;; (shell-mode . turn-on-boon-mode)
;; (helpful-mode . turn-on-boon-mode)
;; (fundamental-mode . turn-on-boon-mode))
:init
(boon-mode))
;; experimental boon+modalka config
(use-package boon
:ensure t
:disabled
:bind
("C-d" . 'boon-take-region)
("C-a" . 'boon-beginning-of-line)
("C-e" . 'boon-end-of-line)
("M-f" . 'boon-smarter-forward)
("M-b" . 'boon-smarter-backward))
;; experimental Emacs-flavored-Boon config
(use-package boon
:ensure t
:disabled
:bind
(:map boon-command-map
("n" . next-line)
("p" . previous-line)
("f" . 'forward-char)
("b" . 'backward-char)
("a" . 'boon-beginning-of-line)
("e" . 'boon-end-of-line)
("y" . 'boon-splice)
("r" . swiper)
("x l" . ido-mini)
("/" . undo-tree-undo)
("?" . undo-tree-redo))
(:map boon-x-map
("s" . #'save-buffer)
("d" . #'dired-jump))
:config
(use-package boon-qwerty)
(boon-mode))
(use-package modalka
:ensure t
:disabled
:bind
(("<escape>" . #'modalka-mode)
:map modalka-mode-map
("J" . #'join-line)
("P" . #'backward-paragraph)
("N" . #'forward-paragraph)
("M" . mark-sexp))
;; (2019-11-03) I'm pretty much using this to emulate `god-mode',
;; which was great, but is no longer actively developed and had no
;; support for non-Latin input methods.
:config
(let ((keybind-re (rx-to-string '(group-n 1 (or (and bow (1+ (char graph)) eow)
(and (1+ (char graph))))))))
(mapc
(lambda (actual)
(let ((target (replace-regexp-in-string keybind-re "C-\\1" actual)))
(modalka-define-kbd actual target)))
;; no "t", "x", or "c", because they are prefix keys used later
'("`" "1" "2" "3" "4" "5" "6" "7" "8" "9" "0" "-" "="
"q" "w" "e" "r" "y" "u" "i" "o" "p" "[" "]" "\\"
"a" "s" "d" "f" "h" "j" "k" "l" ";" "'"
"z" "v" "b" "n" "m" "," "." "/"
"<" ">" "?"
"SPC"
;; (2019-11-03) It's a little unfortunate that these cannot be
;; elided by entering ("x" "C-x") ("t" "C-t") ("c" "C-c") just
;; once :\ (I did try)
"x =" "x -" "x e" "x s" "x d"
"x f" "x l" "x x" "x c" "x v" "x b"
"t w" "t e" "t l"
"c n" "c ," "c ." "c p"
"c c n" "c h u" "c h m")))
(modalka-define-kbd "O" "C-S-o")
(setq-default cursor-type '(bar . 1))
(setq modalka-cursor-type 'box)
:hook
((text-mode . modalka-mode)
(prog-mode . modalka-mode)))
(provide 'cp-modal)

View File

@ -1,168 +0,0 @@
(require 'cp)
;;;; Navigation improvements
(add-to-list 'load-path "~/.emacs.d/elisp-git/window-numbering/")
;; Vim-style prompt-less tag jumping
;; http://stackoverflow.com/questions/12074897/automatically-jump-to-tag-in-emacs
(global-unset-key (kbd "M-t"))
(defun find-tag-no-prompt-other-window ()
"Jump to the tag at point in the other window without prompting."
(interactive)
(find-tag-other-window (find-tag-default)))
(defun find-tag-no-prompt ()
"Jump to the tag at point without prompting."
(interactive)
(find-tag (find-tag-default)))
(cp-set-keys
:bindings
`((,(kbd "M-t M-t") find-tag-no-prompt-other-window)
(,(kbd "M-t M-g") find-tag-no-prompt)
(,(kbd "M-t M-p") pop-tag-mark)
(,(kbd "M-t M-f") find-tag)
(,(kbd "M-t M-s") tags-search)
(,(kbd "M-t M-c") tags-loop-continue)))
;; (require 'view)
;; (cp-set-keys
;; :bindings
;; `((,(kbd "C-v") View-scroll-half-page-forward)
;; (,(kbd "M-v") View-scroll-half-page-backward)))
;; ;; (cp-set-keys
;; ;; :bindings
;; ;; `((,(kbd "C-v") scroll-up)
;; ;; (,(kbd "M-v") scroll-down)))
;;;; Need to make maps for
;;;; mark-* commands (-sexp, -page, -word, etc)
;;;; mark ring
;;;; Other custom keys
(cp-set-keys
:bindings
`((,(kbd "C-x C-1") delete-other-windows)
(,(kbd "C-x C-2") split-window-below)
(,(kbd "C-x C-3") split-window-right)
(,(kbd "C-x C-0") delete-window)
(,(kbd "C-x C-4 C-f") find-file-other-window)
;; (,(kbd "C-`") point-to-register)
;; (,(kbd "C-'") jump-to-register)
(,(kbd "C-x C-d") dired-jump)
;; I usually keep Super for the window manager and global hotkeys...
(,(kbd "s-i") imenu)
;; keypad
;; set this to run whatever command is bound to C-c C-c, or maybe just C-c
;; see (info "(elisp)Translation Keymaps")
(,(kbd "<kp-divide>"))
(,(kbd "<kp-multiply>") cp/copy-buffer)
(,(kbd "<kp-subtract>") erc-track-switch-buffer)
(,(kbd "S-<kp-subtract>") cp-kill-buffer)
(,(kbd "<kp-home>") delete-other-windows)
(,(kbd "<kp-up>") split-window-below)
(,(kbd "<kp-prior>") split-window-right)
(,(kbd "<kp-begin>") ido-mini)
(,(kbd "<kp-add>") save-buffer)
(,(kbd "S-<kp-add>") (lambda () (interactive) (call-interactively (ert-run-tests-interactively t))))
(,(kbd "<kp-enter>") eval-defun)
(,(kbd "S-<kp-enter>") eval-buffer)
(,(kbd "C-S-<kp-enter>") toggle-debug-on-error)
(,(kbd "<kp-end>") select-window-1)
(,(kbd "<kp-down>") select-window-2)
(,(kbd "<kp-next>") select-window-3)
(,(kbd "<kp-insert>") chronometrist)
(,(kbd "C-<kp-insert>") chronometrist-report)
(,(kbd "<kp-delete>") abort-recursive-edit)))
(with-eval-after-load 'dired
(define-key dired-mode-map (kbd "b") 'dired-up-directory)
;; (add-hook 'dired-mode-hook 'visual-line-mode)
;(global-set-key (kbd "C-,") 'string-rectangle 'TAB)
)
(global-unset-key (kbd "C-x d"))
;; (require 'dired-toggle-sudo)
;; (define-key dired-mode-map (kbd "C-c C-s") 'dired-toggle-sudo)
;; (eval-after-load 'tramp
;; '(progn
;; ;; Allow to use: /sudo:user@host:/path/to/file
;; (add-to-list 'tramp-default-proxies-alist
;; '(".*" "\\`.+\\'" "/ssh:%h:"))))
(global-set-key (kbd "C-x df") 'delete-frame)
;;;; make-frame key is after Helm's config
;(setq compilation-read-command nil)
(defun cp-open-init ()
"Open the init.el file."
(interactive)
(find-file "~/.emacs.d/init.el"))
;; todo - store current file name → kill the buffer →
;; find-file-literally with the stored filename. also, find out if you
;; can open it without modes but with the proper encoding.
(defun cp-fcf-literally ()
"Find the current file literally. Like find-file-literally but
does not prompt for a file name."
(interactive)
(find-file-literally (buffer-file-name)))
(defun cp-kill-buffer ()
"Kill the current buffer without prompting."
(interactive)
(kill-buffer nil))
(autoload 'ibuffer "ibuffer" "ibuffer" t)
(global-set-key (kbd "C-x C-b") 'ibuffer)
(with-eval-after-load 'ibuffer
(cp-set-keys
:unset t
:keymap ibuffer-mode-map
:bindings
`((,(kbd "m"))
(,(kbd "U"))))
(cp-set-keys
:keymap ibuffer-mode-map
:bindings
`((,(kbd "m f") ibuffer-mark-by-file-name-regexp)
(,(kbd "m m") ibuffer-mark-by-mode-regexp)
(,(kbd "m n") ibuffer-mark-by-name-regexp)
(,(kbd "M") ibuffer-mark-forward)
(,(kbd "r") ibuffer-do-replace-regexp)
(,(kbd "U") ibuffer-unmark-all)))
(add-hook 'ibuffer-mode-hook 'ibuffer-set-filter-groups-by-mode))
;; (require 'win-switch)
;; (global-set-key "\C-xo" 'win-switch-dispatch)
;; (win-switch-setup-keys-ijkl)
;; (setq win-switch-idle-time 0.5)
;; (setq win-switch-other-window-first nil)
;; ;(setq win-switch-other-window-first nil)
(require 'window-numbering)
(window-numbering-mode 1)
(defun cp-maximize-window ()
"Run maximize-window if more than one window is present."
(interactive)
(if (> (length (window-list)) 1)
(maximize-window)))
(defun cp-minimize-window ()
"Run minimize-window if more than one window is present."
(interactive)
(if (> (length (window-list)) 1)
(minimize-window)))
(with-eval-after-load 'doc-view
(define-key doc-view-mode-map (kbd "=") 'doc-view-fit-height-to-window))
(with-eval-after-load 'view-mode
(define-key view-mode-map (kbd "x") nil)
(define-key view-mode-map (kbd "<backspace>") 'scroll-down-command))
(provide 'cp-nav)

View File

@ -1,210 +0,0 @@
(use-package org
:config
(general-def "<f5> o" 'org-mode)
(general-def org-mode-map
"C-," 'nil
"M-n" 'org-metadown
"M-p" 'org-metaup
"C-c C--" 'org-ctrl-c-minus
"C-c C-," 'org-metaleft
"C-c C-." 'org-metaright
;; "C-j" 'org-return
;; "C-m" 'org-return-indent
"C-c C-9" 'org-mark-ring-goto
"C-c C-/" 'org-sparse-tree
"M-w" 'cp-copy-line-or-link
"C-c C-]" 'org-set-tags
"C-M-x" 'cp/eval-sexp
"C-c C-o" 'cp/org-open
;; boon
"C-c C--" 'org-ctrl-c-minus
"C-c ]" 'org-set-tags)
(mapc (lambda (pair)
(add-to-list 'org-file-apps pair))
'(("txt" . emacs)
("org" . emacs)
;; ("pdf" . zathura)
("\\(?:gif\\|jpe?g\\|png\\)" . "sxiv -f %s")
;; (t . "xdg-open %s")
("pdf" . system)
;; ("pdf" . "zathura %s")
;; (auto-mode . emacs)
;; (system . "xdg-open %s")
(system . "zathura %s")
;; (t . system)
))
(setq org-todo-keywords '((sequence "TODO" "RESEARCH" "STARTED" "DONE"))
org-image-actual-width 400
org-cycle-include-plain-lists 'integrate
org-link-search-must-match-exact-headline nil
org-html-head
;; made to resemble Firefox's reader mode, dark setting
"<style type=text/css>
body {
margin: 40px auto;
max-width: 650px;
line-height: 1.6;
font-size: 18px;
color: #eeeeee !important;
padding: 0 10px;
background-color: #333333;
font-family: sans-serif;
}
h1,h2,h3 {
line-height: 1.2;
}
a,a:visited {
color: #07a;
}
img {
max-width: 80%;
height: auto;
width: auto\9; /* ie8 */
}
</style>"
;; ;; mix of motherfuckingwebsite.com + bettermotherfuckingwebsite.com + thebestmotherfucking.website
;; "<style type=text/css>
;; body {
;; margin: 40px auto;
;; max-width: 650px;
;; line-height: 1.6;
;; font-size: 18px;
;; color: #444;
;; padding: 0 10px;
;; background-color: #eeeeee;
;; font-family: sans-serif;
;; }
;; h1,h2,h3 {
;; line-height: 1.2;
;; }
;; a,a:visited {
;; color: #07a;
;; }
;; img {
;; max-width: 80%;
;; height: auto;
;; width: auto\9; /* ie8 */
;; }
;; </style>"
org-export-default-inline-image-rule
`(("https" .
,(format "\\.%s\\'"
(regexp-opt
'("png" "jpeg" "jpg" "gif" "tiff" "tif" "xbm"
"xpm" "pbm" "pgm" "ppm" "webp") t)))
("file" .
,(format "\\.%s\\'"
(regexp-opt
'("png" "jpeg" "jpg" "gif" "tiff" "tif" "xbm"
"xpm" "pbm" "pgm" "ppm" "webp") t))))))
;; (defun cp-org-expand-all ()
;; (interactive)
;; ;; todo - define inner recursive function
;; (beginning-of-buffer)
;; ;; todo - check if we are on a heading
;; (org-forward-heading-same-level)
;; ())
(defvar cp/org-heading-or-list-rx
'(and
;; headings
(zero-or-more "*")
(zero-or-more blank)
;; list items
(zero-or-one
(or "- " "+ " "* "
(and (one-or-more (char "0-9"))
(or ". " ") "))))
(zero-or-one (and "[" nonl "] "))))
(defun org-link-ahead-p (&optional link-type)
"Returns t if point is before an org-mode link, ignoring
whitespace and org-mode header and list syntax, else nil.
If LINK-TYPE is 'implicit, checks for an implicit link (one not
inside single or double brackets); otherwise, checks for links in
the form [[address][description]] and [[address]]."
(looking-at
(rx-to-string
(append cp/org-heading-or-list-rx
(if (eq link-type 'implicit)
'("http")
'("["))))))
(defun cp/org-open (&optional arg reference-buffer)
(interactive "P")
(save-excursion
(re-search-line
(rx-to-string
(append cp/org-heading-or-list-rx
'((or "[" "[[" "http")))))
(org-open-at-point arg reference-buffer)))
(defun cp-copy-line-or-link (prefix-arg)
"Copy address of org-mode link after point, ignoring whitespace,
link description (if any) and org-mode header and list syntax. If
not before a link, or with a prefix arg, call
`whole-line-or-region-kill-ring-save' instead.
BUG - improper behaviour with checkboxes.
2018-03-17T21:15:17+0530 - hopefully fixed now."
(interactive "P")
(let ((point-a (point)))
(cl-flet ((copy-to-closing-bracket
()
(let ((point-b (point)))
(re-search-forward "\\]")
(copy-region-as-kill point-b
(- (point) 1)))))
(if (save-excursion
(or (use-region-p)
prefix-arg
(re-search-line "\\[[-X ]\\]")))
(whole-line-or-region-kill-ring-save prefix-arg)
(cond ( ;; (org-link-ahead-p)
(re-search-line "\\[")
;; (if (looking-at "\\[")
;; (forward-char))
(forward-char)
(copy-to-closing-bracket)
(goto-char point-a))
( ;; (org-link-ahead-p 'implicit)
(re-search-line "http")
(backward-word)
(let ((point-b (point)))
(re-search-forward (rx (or eol (and printing " "))))
(copy-region-as-kill point-b
(point)))
(goto-char point-a))
;; TODO - org-previous-link will land you at the start
;; of the DESCRIPTION of the previous link, if it has
;; one, but to the user it will look like they are at
;; the start of the link. Add a case to handle this.
;; Does not work if there is an org TODO marker in a
;; header.
(t (whole-line-or-region-kill-ring-save prefix-arg)))))))
(defun cp/org-table-convert-tsv ()
(interactive)
(with-output-to-temp-buffer "cp/org-table-convert-tsv"
(->> (buffer-substring-no-properties (region-beginning) (region-end))
(replace-regexp-in-string "^| *" "")
(replace-regexp-in-string " *| *" " ")
(replace-regexp-in-string "^-.*$" "")))
(with-current-buffer "cp/org-table-convert-tsv"
(remove-hook 'before-save-hook 'delete-trailing-whitespace)
(write-file (read-from-minibuffer "Output filename: "))))
(provide 'cp-org)

View File

@ -1,264 +0,0 @@
;; (require 'paredit)
;; (add-hook 'emacs-lisp-mode-hook 'paredit-mode)
;; (add-hook 'lisp-mode-hook 'paredit-mode)
;; (add-hook 'scheme-mode-hook 'paredit-mode)
;; (add-hook 'inferior-scheme-mode-hook 'paredit-mode)
;; (add-hook 'inferior-lisp-mode-hook 'paredit-mode)
;; (add-hook 'ielm-mode-hook 'paredit-mode)
;; (global-set-key (kbd "C-x C-p") 'paredit-mode)
;; (cp-set-keys
;; :keymap paredit-mode-map
;; :bindings
;; `((,(kbd "C-p") paredit-backward-down)
;; (,(kbd "C-n") paredit-forward-up)
;; (,(kbd "C-b") paredit-backward)
;; (,(kbd "C-f") paredit-forward)
;; (,(kbd "C-u") paredit-backward-up)
;; (,(kbd "C-d") paredit-forward-down)
;; (,(kbd "M-b") backward-char)
;; (,(kbd "M-f") forward-char)
;; (,(kbd "M-p") previous-line)
;; (,(kbd "M-n") next-line)
;; (,(kbd "M-u") paredit-kill-0)
;; (,(kbd "M-d") paredit-forward-delete)
;; (,(kbd "C-M-b") backward-word)
;; (,(kbd "C-M-f") forward-word)
;; (,(kbd "C-M-u") upcase-word)
;; (,(kbd "C-M-d") paredit-forward-kill-word)
;; (,(kbd "C-M-p") nil)
;; (,(kbd "C-M-n") nil)
;; (,(kbd "M-w") paredit-copy-as-kill)
;; (,(kbd "C-h") paredit-backward-delete)
;; (,(kbd "C-w") paredit-backward-kill-word)))
;; (cp-set-keys
;; :keymap comint-mode-map
;; :bindings
;; `((,(kbd "C-d") paredit-forward-down)
;; (,(kbd "C-M-p") comint-previous-input)
;; (,(kbd "C-M-n") comint-next-input)))
(defun cp/sp-after-colon-p (id action context)
(save-excursion
(forward-char -1)
(looking-at-p ":")))
(use-package smartparens
:load-path "~/.emacs.d/elisp-git/smartparens/"
:init
(smartparens-global-mode)
:config
(add-to-list 'sp-no-reindent-after-kill-modes 'markdown-mode)
:bind
(("M-<up>" . sp-splice-sexp-killing-backward)
:map smartparens-mode-map
("C-)" . sp-forward-slurp-sexp)
("C-(" . sp-backward-slurp-sexp)
("C-}" . sp-forward-barf-sexp)
("C-{" . sp-backward-barf-sexp)
("C-j" . sp-newline)
("C-|" . sp-join-sexp)
("C-k" . sp-kill-hybrid-sexp)
("C-h" . sp-backward-delete-char)
("<backspace>" . sp-backward-delete-char)
("C-w" . sp-backward-kill-word)
("<C-backspace>" . sp-backward-kill-word)
("M-DEL" . sp-backward-kill-word)
("M-d" . sp-kill-word)
("C-M-p" . sp-backward-down-sexp)
("C-M-n" . sp-backward-up-sexp)
("C-M-b" . sp-backward-sexp)
("C-M-f" . sp-forward-sexp)
("C-M-u" . sp-up-sexp)
("C-M-d" . sp-down-sexp)
("C-M-a" . sp-beginning-of-sexp)
("C-M-e" . sp-end-of-sexp)
("C-M-k" . sp-kill-sexp)
("C-M-w" . sp-copy-sexp)
:map emacs-lisp-mode-map
(";" . sp-comment))
:hook
(eval-expression-minibuffer-setup . smartparens-mode))
(require 'smartparens)
(require 'smartparens-config)
(smartparens-global-mode)
(add-hook 'paredit-mode-hook 'turn-off-smartparens-mode)
;; (sp-pair "(" ")" :trigger-wrap (kbd "M-(") :actions '(insert wrap autoskip navigate escape))
(sp-pair "(" ")" :wrap "M-(")
(sp-pair "[" "]" :wrap "M-[")
(sp-pair "\"" "\"" :wrap "M-\"")
;; (global-unset-key (kbd "M-\'"))
;; (sp-pair "\'" "\'" :wrap "M-\'") ;; buggy
(sp-pair "<" ">" :wrap "M-<")
(sp-pair "{" "}" :wrap "M-{")
;; (sp-pair "\\\\*" "\\\\*" :actions '(wrap))
;; (sp-pair "\\\\*" :wrap)
;; (sp-pair "\\\\/" :wrap)
;; commented out on 2017-06-06T19:25:13+0530 -
(add-hook 'erc-mode-hook 'smartparens-mode)
;; Disable inserting pair if preceded by : (e.g. in IRC smileys)
(defun cp-point-after-colon-p ()
(equal (string (char-before)) ":"))
;; (sp-pair "(" nil :unless '(cp-point-after-colon-p))
;;;; sp-backward-kill-word and subword-backward-kill conflict
;; (define-key emacs-lisp-mode-map (kbd "C-p") 'sp-previous-sexp)
;; (define-key emacs-lisp-mode-map (kbd "C-n") 'sp-next-sexp)
;; 2016-11-12 - trying something different, hopefully more consistent
(defun cp-setup-lisp-keys ()
;; (cp-set-keys
;; :keymap smartparens-mode-map
;; :bindings
;; `((,(kbd "C-M-b") nil)
;; (,(kbd "C-M-f") nil)
;; (,(kbd "C-M-u") nil)
;; (,(kbd "C-M-d") nil)
;; (,(kbd "C-M-p") nil)
;; (,(kbd "C-M-n") nil)))
;; (cp-set-keys
;; :keymap 'local
;; :bindings
;; `((,(kbd ";") sp-comment)
;; (,(kbd "C-p") sp-backward-down-sexp)
;; (,(kbd "C-n") sp-backward-up-sexp)
;; (,(kbd "C-b") sp-backward-sexp)
;; (,(kbd "C-f") sp-forward-sexp)
;; (,(kbd "C-u") sp-up-sexp)
;; (,(kbd "C-d") sp-down-sexp)
;; (,(kbd "C-a") sp-beginning-of-sexp)
;; (,(kbd "C-e") sp-end-of-sexp)
;; (,(kbd "C-k") sp-kill-sexp)
;; (,(kbd "M-w") sp-copy-sexp)
;; (,(kbd "C-h") sp-backward-delete-char)
;; (,(kbd "C-w") sp-backward-kill-word)
;; (,(kbd "M-q") sp-indent-defun)
;; (,(kbd "M-b") backward-char)
;; (,(kbd "M-f") forward-char)
;; (,(kbd "M-p") previous-line)
;; (,(kbd "M-n") next-line)
;; (,(kbd "M-u") cp-kill-line-0)
;; (,(kbd "M-d") sp-delete-char)
;; (,(kbd "M-a") beginning-of-line)
;; (,(kbd "M-e") end-of-line)
;; (,(kbd "C-M-b") backward-word)
;; (,(kbd "C-M-f") forward-word)
;; (,(kbd "C-M-u") upcase-word)
;; (,(kbd "C-M-d") sp-kill-word)))
;; (cp-set-keys
;; :keymap comint-mode-map
;; :bindings
;; `((,(kbd "C-d") sp-down-sexp)
;; (,(kbd "C-M-p") comint-previous-input)
;; (,(kbd "C-M-n") comint-next-input)))
(cp-set-keys
:keymap 'local
:bindings
`((,(kbd "M-q") sp-indent-defun)
(,(kbd "M-w") contrapunctus-lisp-copy)))
)
;; experiment
(defun cp/erc-sp-keys ()
(cp-set-keys
:keymap smartparens-mode-map
:unset t
:bindings
`((,(kbd "C-h"))
(,(kbd "C-w")))
;; `((,(kbd "C-h") backward-delete-char)
;; (,(kbd "C-w") backward-kill-word))
))
;; ;; 2016-11-06 - commented out to try a different, hopefully more consistent setup -
(add-hook 'emacs-lisp-mode-hook 'cp-setup-lisp-keys)
(add-hook 'lisp-mode-hook 'cp-setup-lisp-keys)
(add-hook 'scheme-mode-hook 'cp-setup-lisp-keys)
(add-hook 'inferior-scheme-mode-hook 'cp-setup-lisp-keys)
(add-hook 'ielm-mode-hook 'cp-setup-lisp-keys)
(add-hook 'eval-expression-minibuffer-setup-hook 'smartparens-mode)
(add-hook 'erc-mode 'cp/erc-sp-keys)
;; (add-hook 'eval-expression-minibuffer-setup-hook 'cp-setup-lisp-keys)
;; ielm
;; (require 'ielm)
;; (define-key ielm-map (kbd "C-p") 'sp-backward-down-sexp)
;; (define-key ielm-map (kbd "C-n") 'sp-backward-up-sexp)
;; (define-key ielm-map (kbd "C-b") 'sp-backward-sexp)
;; (define-key ielm-map (kbd "C-f") 'sp-forward-sexp)
;; (define-key ielm-map (kbd "C-u") 'sp-up-sexp)
;; (define-key ielm-map (kbd "C-d") 'sp-down-sexp)
;; (define-key comint-mode-map (kbd "C-d") 'sp-down-sexp)
;; (define-key ielm-map (kbd "C-a") 'sp-beginning-of-sexp)
;; (define-key ielm-map (kbd "C-e") 'sp-end-of-sexp)
;; (define-key ielm-map (kbd "C-k") 'sp-kill-sexp)
;; (define-key ielm-map (kbd "M-w") 'sp-copy-sexp)
;; (define-key ielm-map (kbd "C-h") 'sp-backward-delete-char)
;; (define-key ielm-map (kbd "C-w") 'sp-backward-kill-word)
;; (define-key ielm-map (kbd "M-b") 'backward-char)
;; (define-key ielm-map (kbd "M-f") 'forward-char)
;; (define-key ielm-map (kbd "M-p") 'previous-line)
;; (define-key ielm-map (kbd "M-n") 'next-line)
;; (define-key ielm-map (kbd "M-u") 'cp-kill-line-0)
;; (define-key ielm-map (kbd "C-k") 'sp-kill-sexp)
;; (define-key ielm-map (kbd "M-d") 'sp-delete-char)
;; (define-key ielm-map (kbd "C-M-b") 'backward-word)
;; (define-key ielm-map (kbd "C-M-f") 'forward-word)
;; (define-key ielm-map (kbd "C-M-u") 'upcase-word)
;; (define-key ielm-map (kbd "C-M-d") 'sp-kill-word)
;; (define-key ielm-map (kbd "C-M-p") nil)
;; (define-key ielm-map (kbd "C-M-n") nil)
;; (define-key comint-mode-map (kbd "C-M-p") 'comint-previous-input)
;; (define-key comint-mode-map (kbd "C-M-n") 'comint-next-input)
;; (define-key scheme-mode-map (kbd "C-p") 'sp-backward-down-sexp)
;; (define-key scheme-mode-map (kbd "C-n") 'paredit-forward-up)
;; (define-key scheme-mode-map (kbd "C-b") 'paredit-backward)
;; (define-key scheme-mode-map (kbd "C-f") 'sp-forward-sexp)
;; (define-key scheme-mode-map (kbd "C-u") 'paredit-backward-up)
;; (define-key scheme-mode-map (kbd "C-d") 'paredit-forward-down)
;; (define-key comint-mode-map (kbd "C-d") 'paredit-forward-down)
;; (define-key scheme-mode-map (kbd "M-b") 'backward-char)
;; (define-key scheme-mode-map (kbd "M-f") 'forward-char)
;; (define-key scheme-mode-map (kbd "M-p") 'previous-line)
;; (define-key scheme-mode-map (kbd "M-n") 'next-line)
;; ;; (define-key scheme-mode-map (kbd "M-u") 'paredit-kill-0)
;; (define-key scheme-mode-map (kbd "C-k") 'sp-kill-sexp)
;; (define-key scheme-mode-map (kbd "M-d") 'sp-delete-char)
;; (define-key scheme-mode-map (kbd "C-M-b") 'backward-word)
;; (define-key scheme-mode-map (kbd "C-M-f") 'forward-word)
;; (define-key scheme-mode-map (kbd "C-M-u") 'upcase-word)
;; (define-key scheme-mode-map (kbd "C-M-d") 'sp-kill-word)
;; (define-key scheme-mode-map (kbd "C-M-p") nil)
;; (define-key scheme-mode-map (kbd "C-M-n") nil)
;; (define-key comint-mode-map (kbd "C-M-p") 'comint-previous-input)
;; (define-key comint-mode-map (kbd "C-M-n") 'comint-next-input)
;; (define-key scheme-mode-map (kbd "M-w") 'paredit-copy-as-kill)
;; (define-key scheme-mode-map (kbd "C-h") 'paredit-backward-delete)
;; (define-key scheme-mode-map (kbd "C-w") 'paredit-backward-kill-word)

View File

@ -24,3 +24,5 @@
(define-key sfz-mode-map (kbd "M-p") 'sfz-prev-group)
(define-key sfz-mode-map (kbd "M-n") 'sfz-next-group)
(provide 'cp-sfz)

View File

@ -1,35 +0,0 @@
(setq TeX-auto-save t
TeX-parse-self t
TeX-engine 'xetex
;; 2017-10-14T18:55:05+0530
TeX-view-program-selection '(((output-dvi has-no-display-manager)
"dvi2tty")
((output-dvi style-pstricks)
"dvips and gv")
(output-dvi "xdvi")
(output-pdf "Zathura")
(output-html "xdg-open")))
(add-hook 'tex-mode-hook 'TeX-source-correlate-mode)
;; 2017-10-19T09:19:34+0530 - these should be merged with
;; cp-forward-def/cp-backward-def in cp-lily...
(defun cp-backward-def ()
(interactive)
(push-mark)
(re-search-backward "\\\\scene" nil t)
(beginning-of-line)
(recenter))
(defun cp-forward-def ()
(interactive)
(push-mark)
(if (not (re-search-forward "\\\\scene" nil t 2))
(re-search-forward "\\end{document}" nil t))
(beginning-of-line)
(recenter))
(cp-set-keys
:keymap LaTeX-mode-map
:bindings
`((,(kbd "M-p") cp-backward-def)
(,(kbd "M-n") cp-forward-def)))

View File

@ -1,55 +0,0 @@
;; Simplify the GUI, thanks
;; http://www.masteringemacs.org/articles/2010/10/04/beginners-guide-to-emacs/
(menu-bar-mode -1)
(tool-bar-mode -1)
(scroll-bar-mode -1)
(horizontal-scroll-bar-mode -1)
(display-time-mode t)
(setq focus-follows-mouse t
mouse-autoselect-window t
display-time-format "%a, %d %h %Y %T"
display-time-interval 1
use-dialog-box nil)
;; Highlight current line
(global-hl-line-mode 1)
(defalias 'yes-or-no-p 'y-or-n-p)
(setq ediff-window-setup-function 'ediff-setup-windows-plain)
;;;; Set theme
;(load-theme 'distinguished t)
;(require 'github-theme)
;(require 'heroku-theme)
;;;; Good theme but uses different font sizes in org-mode, and (I think) some weird non-monospace font
;; (require 'monokai-theme)
(require 'molokai-theme)
(enable-theme 'molokai)
;; (require 'fullscreen-mode)
;; (fullscreen-mode 1)
;; (require 'relative-line-numbers)
;; ;; old
;; ;; (setq relative-line-numbers-motion-function 'vertical-motion)
;; ;; new
;; (setq relative-line-numbers-motion-function 'forward-visible-line)
;; (global-relative-line-numbers-mode 1)
;; (add-hook 'shell-mode-hook 'previous-buffer)
;; ;; is this what deletes windows when you run a shell command?
;; (add-hook 'shell-mode-hook 'delete-other-windows)
;; 2018-08-26T22:39:09+0530
(defun cp/change-split ()
"Switch between two windows in horizontal layout and vice-versa."
(interactive)
(let (()))
;; if height of window > width, we're in a vertical split
;; otherwise we're in a horizontal split
)

View File

@ -1,144 +0,0 @@
(defun cp-global-set-many-keys (bindings)
"A clean way to define many keys using `global-set-key'.
BINDINGS must be in the form `((,(kbd \"...\") FN) ...)"
(mapc (lambda (b)
(global-set-key (car b) (cadr b)))
bindings))
(defun cp-define-many-keys (keymap bindings)
"A clean way to define many keys using `define-key'.
KEYMAP must be a valid keymap.
BINDINGS must be in the form `((,(kbd \"...\") FN) ...)"
(mapc (lambda (b)
(define-key keymap (car b) (cadr b)))
bindings))
(defun cp-local-set-many-keys (bindings)
"A clean way to define many keys using `local-set-key'.
BINDINGS must be in the form `((,(kbd \"...\") FN) ...)"
(mapc (lambda (b)
(local-set-key (car b) (cadr b)))
bindings))
(require 'cl-lib)
(cl-defun cp-set-keys (&key keymap unset bindings)
"A clean way to set/unset many keybindings.
BINDINGS specifies the functions and the keys they are to be
bound to. It must be an alist in the form -
`((,(kbd \"...\") FN)
...)
If KEYMAP is a symbol `global' or not supplied, the binding is
created by `global-set-key'.
If it is a symbol `local', the binding is created by
`local-set-key'.
Otherwise, it is assumed to be a keymap and the binding is
created with `define-key'.
If UNSET is non-nil, unset keybinds as specified by KEYMAP
instead of setting them. If a keymap is specified, the key is unset
by using define-key to set it to nil in the given keymap -
otherwise, global-unset-key or local-unset-key are used as
applicable."
(let ((key-function (if (not unset)
(pcase keymap
((or `global `nil) #'global-set-key)
(`local #'local-set-key)
(x #'define-key))
(pcase keymap
((or `global `nil) #'global-unset-key)
(`local #'local-unset-key)
(x #'define-key)))))
(if (eq key-function 'define-key)
(if unset
(mapc (lambda (b)
(funcall key-function keymap (car b) nil))
bindings)
(mapc (lambda (b)
(funcall key-function keymap (car b) (cadr b)))
bindings))
(if unset
(mapc (lambda (b)
(funcall key-function (car b)))
bindings)
(mapc (lambda (b)
(funcall key-function (car b) (cadr b)))
bindings)))))
;; ;; tests
;; (progn (cp-set-keys :keymap 'global ; not actually needed, e.g. see next call
;; :bindings `((,(kbd "<f6>") erc) (,(kbd "<f7>") eww)))
;; (and (equal 'erc (lookup-key (current-global-map) (kbd "<f6>")))
;; (equal 'eww (lookup-key (current-global-map) (kbd "<f7>")))))
;; (progn (cp-set-keys :unset t
;; :bindings `((,(kbd "<f6>") erc) (,(kbd "<f7>") eww)))
;; (and (equal nil (lookup-key (current-global-map) (kbd "<f6>")))
;; (equal nil (lookup-key (current-global-map) (kbd "<f7>")))))
;; (progn (cp-set-keys :keymap emacs-lisp-mode-map
;; :bindings `((,(kbd "<f6>") erc) (,(kbd "<f7>") eww)))
;; (and (equal 'erc (lookup-key emacs-lisp-mode-map (kbd "<f6>")))
;; (equal 'eww (lookup-key emacs-lisp-mode-map (kbd "<f7>")))))
;; (progn (cp-set-keys :keymap emacs-lisp-mode-map
;; :unset t
;; :bindings `((,(kbd "<f6>") erc) (,(kbd "<f7>") eww)))
;; (and (equal nil (lookup-key emacs-lisp-mode-map (kbd "<f6>")))
;; (equal nil (lookup-key emacs-lisp-mode-map (kbd "<f7>")))))
;; (progn (cp-set-keys :keymap 'local
;; :bindings `((,(kbd "<f6>") erc) (,(kbd "<f7>") eww)))
;; (and (equal 'erc (lookup-key emacs-lisp-mode-map (kbd "<f6>")))
;; (equal 'eww (lookup-key emacs-lisp-mode-map (kbd "<f7>")))))
;; (progn (cp-set-keys :keymap 'local
;; :unset t
;; :bindings `((,(kbd "<f6>") erc) (,(kbd "<f7>") eww)))
;; (and (equal nil (lookup-key emacs-lisp-mode-map (kbd "<f6>")))
;; (equal nil (lookup-key emacs-lisp-mode-map (kbd "<f7>")))))
(defun cp-get-buffer-regexp (regexp &optional all)
"Returns the name of the first buffer in the buffer list which matches REGEXP.
If ALL is non-nil, multiple matches will be returned as a list."
(let ((results (cl-remove-if-not (lambda (a)
(string-match regexp a))
(mapcar #'buffer-name (buffer-list)))))
(if all results (car results))))
(cl-defun cp-buffer-name-match-p (regexp &optional (string (buffer-name)))
"Checks if STRING matches REGEXP.
If STRING is not provided, uses the current buffer name."
(if (string-match regexp string) t nil))
(defun cp/random-elt (list)
"Retun a random element from LIST."
(nth (random (length list)) list))
(defun cp/map-two (fn list)
"Apply FN to the first two elements of LIST, then the second two, and so on."
(let ((newlist '()))
(while (not (= 0 (- (length list) 1)))
(setq newlist
(append
newlist (list
(funcall fn (car list) (cadr list)))))
(pop list))
newlist))
(defun cp/average (numbers)
(/ (-reduce '+ numbers)
(length numbers)))
(defun cp/pastebinit ()
(interactive)
(-> (shell-command-on-region
(if (region-active-p) (region-beginning) (point-min))
(if (region-active-p) (region-end) (point-max))
"pastebinit")
(kill-new)))
(defun ^ (base pwr)
(while (not (zerop pwr))
(setq base (* base base)
pwr (- pwr 1)))
base)
(provide 'cp)

Binary file not shown.

50
contrapunctus/org.css Normal file
View File

@ -0,0 +1,50 @@
/* made to resemble Firefox's reader mode, dark setting */
<style type=text/css>
body {
margin: 40px auto;
max-width: 650px;
line-height: 1.6;
font-size: 18px;
color: #eeeeee !important;
padding: 0 10px;
background-color: #333333;
font-family: sans-serif;
}
h1,h2,h3 {
line-height: 1.2;
}
a,a:visited {
color: #07a;
}
img {
max-width: 80%;
height: auto;
width: auto\9; /* ie8 */
}
</style>
/* mix of motherfuckingwebsite.com + bettermotherfuckingwebsite.com + thebestmotherfucking.website */
/* <style type=text/css> */
/* body { */
/* margin: 40px auto; */
/* max-width: 650px; */
/* line-height: 1.6; */
/* font-size: 18px; */
/* color: #444; */
/* padding: 0 10px; */
/* background-color: #eeeeee; */
/* font-family: sans-serif; */
/* } */
/* h1,h2,h3 { */
/* line-height: 1.2; */
/* } */
/* a,a:visited { */
/* color: #07a; */
/* } */
/* img { */
/* max-width: 80%; */
/* height: auto; */
/* width: auto\9; /\* ie8 *\/ */
/* } */
/* </style> */

717
init.el
View File

@ -1,717 +0,0 @@
;; -*- lexical-binding: t; -*-
;; TODO - convert to use-package
;; TODO - drop cp/ prefix, use contrapunctus-, set up nameless package
;; names
;; TODO - create wrapper for
;; xref-find-definitions/xref-find-definitions-other-window
;; TODO - make ag suggest my last isearch term
;; TODO - make a completing prompt for Info manuals instead of the
;; current approach of either opening info and searching for a manual
;; or binding calls to (info "(something)") to keys.
;; TODO - add idle timer for recentf-cleanup
;; TODO - write command to deduce actions for directory based on
;; contents. e.g. if a directory has only/mostly videos, run `vlc
;; --recursive expand <dir>', mostly images - `sxiv -for <dir>', etc.
;; With prefix arg or when confused, ask for command (with
;; completion).
;; TODO - lets write something quicker to find files. Don't ask for
;; directory * - just start in the current working directory. Update
;; results as we type (after a little delay). Don't make user input
;; arguments to find(1) * - by default, search the whole path, put
;; filename matches first, path matches later.
;;
;; * maybe only with prefix arg.
;; TODO - stop desktop-save from saving my buffers - just save history etc (persp-mode?)
;; TODO - make idle timer to find all local git repos with uncommited changes
;; Reorganize into subdirectories?
;; text - org, md, tex
;; prog - lisp, lilypond
;; non-text - doc-view, emms
;; applications - eww, chronometrist, fm, irc
;; input - modal, hindi
;;;; Code:
(eval-when-compile
(add-to-list 'load-path "~/.emacs.d/elisp-git/use-package/")
(require 'use-package))
(require 'package)
(let* ((no-ssl (and (memq system-type '(windows-nt ms-dos))
(not (gnutls-available-p))))
(proto (if no-ssl "http" "https")))
;; Comment/uncomment these two lines to enable/disable MELPA and MELPA Stable as desired
(add-to-list 'package-archives (cons "melpa" (concat proto "://melpa.org/packages/")) t)
;;(add-to-list 'package-archives (cons "melpa-stable" (concat proto "://stable.melpa.org/packages/")) t)
(when (< emacs-major-version 24)
;; For important compatibility libraries like cl-lib
(add-to-list 'package-archives '("gnu" . (concat proto "://elpa.gnu.org/packages/")))))
(package-initialize)
;; from https://github.com/jorgenschaefer/Config/blob/master/emacs.el#L796-L800
(mapc (lambda (path)
(when (file-directory-p path)
(add-to-list 'load-path path)
(dolist (dirname (directory-files path t "^[^.]"))
(when (file-directory-p dirname)
(let ((try1 (concat dirname "/elisp"))
(try2 (concat dirname "/lisp")))
(add-to-list 'load-path
(cond ((file-exists-p try1) try1)
((file-exists-p try2) try2)
(t dirname))))))))
'("~/.emacs.d/elisp-git/"
"~/.emacs.d/contrapunctus"
"~/.emacs.d/elpa/"
"~/.emacs.d/user"))
(load "cp-ui")
(require 'atomic-chrome)
(atomic-chrome-start-server)
(setq atomic-chrome-url-major-mode-alist
'(("wikisource" . mediawiki-mode)))
(use-package emacs
:config
(setq gc-cons-threshold 100000000
delete-by-moving-to-trash t
trash-directory "~/.trash/"
history-length 1000
use-file-dialog nil))
(use-package doc-view
:config
(setq doc-view-resolution 300))
(use-package gnutls
:config
;; https://debbugs.gnu.org/cgi/bugreport.cgi?bug=36749
(setq gnutls-algorithm-priority "NORMAL:-VERS-TLS1.3"))
(use-package ag
:ensure t
:bind
("<f2> p" . ag)
("<f2> P" . ag-project-regexp)
:config
(setq ag-highlight-search t))
(require 'cp-modal)
(require 'cp-god)
(require 'cp-chronometrist)
(use-package comint
:bind (:map comint-mode-map
("M-p" . #'comint-previous-matching-input-from-input)
("M-n" . #'comint-next-matching-input-from-input)))
(use-package company
:ensure t
:diminish company-mode
:commands global-company-mode
:init (global-company-mode)
:bind ;; ("TAB" . company-indent-or-complete-common)
(:map emacs-lisp-mode-map
("TAB" . company-indent-or-complete-common)
("C-i" . company-indent-or-complete-common)))
(use-package company-emoji
:ensure t
:if (featurep 'company)
:config (add-to-list 'company-backends 'company-emoji))
(use-package counsel
:ensure t
:bind ("M-x" . counsel-M-x)
:config
(setq counsel-find-file-ignore-regexp "\\`\\."))
;; (use-package elsa
;; :commands flycheck-elsa-setup)
(global-set-key (kbd "M-w") 'kill-ring-save)
(define-key emacs-lisp-mode-map (kbd "M-w") nil)
;; M-d is useful in the minibuffer
(define-key emacs-lisp-mode-map (kbd "M-d") nil)
(global-set-key (kbd "M-d") 'easy-kill-delete-region)
(use-package easy-kill
:disabled
:ensure t
:bind (("M-w" . easy-kill)
("M-d" . easy-kill-delete-region)))
(use-package elfeed
:bind (:map elfeed-show-mode-map
("v" . nil))
:config
(add-to-list 'boon-special-mode-list 'elfeed-show-mode)
(add-to-list 'boon-special-mode-list 'elfeed-search-mode))
(use-package hydra
:ensure t
:commands defhydra)
(require 'cp-emms)
(use-package emr
:ensure t
:bind (:map prog-mode-map
("M-S-<return>" . emr-show-refactor-menu)))
(use-package eshell
:ensure t
:config (setq eshell-history-size 999))
(use-package eww
:ensure t
:bind
(:map eww-mode-map
("b" . #'eww-back-url)
("f" . #'eww-forward-url)
("v" . nil)))
(use-package flx-ido
:disabled
:ensure t
:init (flx-ido-mode 1)
(setq ido-enable-flex-matching t
ido-use-faces nil))
(use-package flx-isearch
:disabled
:ensure t
:bind
("C-s" . #'flx-isearch-forward)
("C-r" . #'flx-isearch-backward))
;; (use-package flycheck
;; :ensure t
;; :init (global-flycheck-mode))
;; (use-package flycheck-elsa
;; :hook (emacs-lisp-mode . flycheck-elsa-setup))
(setenv "PATH" (concat "/home/anon/bin:" (getenv "PATH")))
(setenv "EDITOR" "emacsclient")
;; what on earth is this message after every init -
;; ad-handle-definition: `tramp-read-passwd' got redefined
;; ;; (profiler-start 'cpu)
;; (toggle-debug-on-error)
;; ;; (toggle-debug-on-quit)
(require 'dash)
(require 's)
(require 'visual-fill-column)
;; (add-to-list 'load-path "~/.emacs.d/elisp-git/yafolding.el/")
(add-to-list 'load-path "~/.emacs.d/user/")
(add-to-list 'load-path "~/.emacs.d/contrapunctus/")
(add-to-list 'load-path "~/.emacs.d/contrapunctus/fin/")
(add-to-list 'load-path "~/.emacs.d/contrapunctus/ido-mini/")
(load "cp")
;; (if (not (server-running-p)) (server-start))
(server-start)
(use-package general
:commands general-define-key)
;; 2017-06-09T00:24:36+0530
;; my laptop's X, W, and G keys gave up the ghost
;; temporary bindings, till my laptop keyboard is fixed
;; 2020-01-07T12:43:41+0530
;; update to use general, add M-f8 binding
(general-define-key
"<f8>" 'keyboard-quit
"M-<f8>" 'eval-defun
"M-<f9>" 'dired-jump
"<f10>" 'save-buffer
"M-<f10>" 'find-file
"<f11>" 'ido-mini
"M-<f11>" 'ibuffer
"<f12>" 'execute-extended-command
"M-<f12>" 'text-scale-adjust
"C-c C-j" 'join-line
"C-c C-r" (lambda () (interactive) (revert-buffer t t)))
;;;; UTF-8 magic
;; (setq locale-coding-system 'utf-8)
;; (set-terminal-coding-system 'utf-8)
;; (set-keyboard-coding-system 'utf-8)
;; (set-selection-coding-system 'utf-8)
;; (prefer-coding-system 'utf-8)
;;;; Linewrapping
(add-hook 'org-mode-hook 'visual-line-mode)
(add-hook 'erc-mode-hook 'visual-line-mode)
;(global-set-key (kbd "C-x t") 'toggle-truncate-lines)
(add-hook 'markdown-mode-hook 'visual-fill-column-mode)
(add-hook 'text-mode-hook 'visual-line-mode)
(load "cp-md")
(defun cp/turn-on-truncate-lines ()
;; (setq truncate-lines 1)
(toggle-truncate-lines 1))
(defun cp/add-to-hooks (function hooks)
(-map (lambda (hook)
(add-hook hook function))
hooks))
(defun cp/remove-from-hooks (function hooks)
(-map (lambda (hook)
(remove-hook hook function))
hooks))
(cp/add-to-hooks 'cp/turn-on-truncate-lines '(dired-mode-hook
prog-mode-hook
diff-mode-hook
message-mode-hook))
(global-visual-line-mode -1)
(setq truncate-partial-width-windows nil
truncate-lines t)
(add-hook 'erc-mode-hook 'visual-line-mode)
(add-hook 'comint-mode-hook 'visual-line-mode)
;; commented out on 2018-03-19T14:18:34+0530
;; (add-hook 'markdown-mode-hook 'auto-fill-mode)
;; (add-hook 'text-mode-hook 'auto-fill-mode)
;; (add-hook 'paredit-mode-hook 'auto-fill-mode)
;;;; Tab settings
;; (setq default-tab-width 4)
(setq tab-width 4)
;(define-key text-mode-map (kbd "TAB") 'self-insert-command)
(setq-default indent-tabs-mode nil)
;;;; Fix scrolling
(setq scroll-conservatively 10000
scroll-preserve-screen-position t)
(setq auto-window-vscroll nil)
;;; Recenter screen on isearch matches
(add-hook 'isearch-mode-hook 'recenter)
(add-hook 'isearch-update-post-hook 'recenter)
(defadvice isearch-repeat-forward
(after isearch-repeat-forward-recenter activate) (recenter))
(defadvice isearch-repeat-backward
(after isearch-repeat-backward-recenter activate) (recenter))
(ad-activate 'isearch-repeat-forward)
(ad-activate 'isearch-repeat-backward)
(global-set-key (kbd "C-s") 'isearch-forward-regexp)
(global-set-key (kbd "C-r") 'isearch-backward-regexp)
;;;; While we're at it, let's add that to next-error as well
;;;; (this affects jumping to match from M-x grep , too)
(add-hook 'next-error-hook 'recenter)
;;;; ...and to magit-toggle-section
;;; It'd be really cool to (recenter 3) when you /open/ a section,
;;; and (recenter) when you close a section
(defadvice magit-section-toggle
(after magit-section-toggle-recenter activate) (recenter 3))
(ad-activate 'magit-section-toggle)
(defadvice magit-unstage-item
(after magit-unstage-item-move) (next-line))
(ad-activate 'magit-unstage-item)
(defadvice magit-goto-next-section
(after magit-next-section-recenter activate) (recenter 3))
(ad-activate 'magit-goto-next-section)
(defadvice magit-goto-previous-section
(after magit-previous-section-recenter activate) (recenter 3))
(ad-activate 'magit-goto-previous-section)
(defun cp-insert-timestamp ()
(interactive)
(insert (format-time-string "%FT%T%z")))
(require 'fin)
(defun cp/eval-sexp (arg)
"In emacs-lisp-mode, just run eval-defun.
In other modes - jump to first Lisp expression in current line
and eval it."
(interactive "P")
(save-excursion
(cond ((or
(equal major-mode 'emacs-lisp-mode)
(equal major-mode 'lisp-interaction-mode))
(eval-defun arg))
((re-search-line "(")
(progn
(forward-char -1)
(forward-sexp)
(eval-last-sexp arg)))
(t nil))))
(use-package helpful
:ensure t
:bind (("<f1> <f1>" . #'helpful-at-point)
("<f1> f" . #'helpful-callable)
("<f1> c" . #'helpful-command)
("<f1> k" . #'helpful-key)
("<f1> v" . #'helpful-variable)))
(use-package ibuffer
:bind
(:map ibuffer-mode-map
("X" . 'ibuffer-do-kill-on-deletion-marks)))
(use-package info
:ensure t
:config
(info-initialize)
(--map (add-to-list #'Info-directory-list it)
'("~/.emacs.d/info/"
"~/.emacs.d/elisp-git/geiser/doc/"
"~/lilypond/usr/share/info/"))
:bind
(("<f1> i" . nil)
("<f1> i i" . info)
("<f1> i a" . info-apropos)
("<f1> i q" . (lambda () (interactive) (info "(emacs)")))
("<f1> i w" . (lambda () (interactive) (info "(elisp)")))
("<f1> i l" . (lambda () (interactive) (info "(lilypond-notation)")))
("<f1> i r" . (lambda () (interactive) (info "(lilypond-learning)")))
("<f1> i s" . (lambda () (interactive) (info "(stumpwm)")))
("<f1> i o" . (lambda () (interactive) (info "(org)")))
("<f1> i g" . (lambda () (interactive) (info "(guile)"))))
:bind
(:map Info-mode-map
("b" . Info-history-back)
("f" . Info-history-forward)))
(general-define-key
;; "s-k" 'cp-kill-buffer
"s-k" 'bury-buffer
"C-x k" 'cp-kill-buffer
"C-`" 'shell
"M-`" 'eshell
"M-<f2>" 'compile
"M-<f3>" 'run-chicken
"M-<f4>" 'run-lisp
"M-<f5>" 'ielm)
(general-define-key
:prefix "<f1>"
"M" 'describe-mode
"m" 'woman
"l" 'find-library)
(general-define-key
:prefix "<f2>"
;; "<f2>" 'imenu
"<f2>" 'xref-find-definitions
"r" 'xref-find-references
"m" 'imenu
;; "p" 'grep
"p" 'ag-regexp
"o" 'find-grep
"i" 'find-dired
"h" 'proced)
(general-define-key
:prefix "<f5>"
"<f5>" 'eval-buffer
"i" 'cp-open-init
"v" 'visual-line-mode
"f" 'cp-fcf-literally
"f" 'fundamental-mode
"t" 'text-mode
"T" 'cp-insert-timestamp
"c" 'calendar)
(general-define-key
;; [down-mouse-1] 'mouse-set-point
;; [up-mouse-1] 'er/expand-region
[s-mouse-3] 'bury-buffer
[mouse-8] 'delete-window
;; (kbd "<mouse-9>") 'keyboard-quit
;; [mouse-9] 'buffer-menu
[mouse-9] 'ibuffer
[C-mouse-9] 'recentf-open-files
[M-mouse-4] 'next-buffer
[M-mouse-5] 'previous-buffer
[M-mouse-8] 'split-window-right
[M-mouse-9] 'split-window-below
;; quitting from helm-mini - whether with keyboard-quit or
;; keyboard-escape-quit - "banishes" the mouse pointer to the
;; top-right corner!? wtf, helm.
;; (kbd "s-<mouse-9>") 'helm-mini
)
(with-eval-after-load 'help-mode
(cp-set-keys
:keymap help-mode-map
:bindings
`((,(kbd "b") help-go-back)
(,(kbd "f") help-go-forward))))
;; More convenient Unicode keys
(global-unset-key (kbd "M-["))
(cp-set-keys
:bindings
`((,(kbd "C-' r") ,(kbd ""))
(,(kbd "C-' C-r") ,(kbd ""))
(,(kbd "C-' e") ,(kbd ""))
(,(kbd "C-' b") ,(kbd ""))
(,(kbd "C-' f") ,(kbd ""))
(,(kbd "C-' p") ,(kbd ""))
(,(kbd "C-' n") ,(kbd ""))
(,(kbd "C-' l") ,(kbd "λ"))
(,(kbd "C-' F") ,(kbd "ƒ"))))
(setq default-input-method "devanagari-itrans")
(setq backup-by-copying t
backup-directory-alist '(("." . "~/.emacs.d/saves/"))
delete-old-versions t
kept-new-versions 2
kept-old-versions 2
version-control t)
(setq browse-url-browser-function 'browse-url-xdg-open)
(use-package iedit
:ensure t
:bind (("C-;" . #'iedit-mode)
("C-:" . #'iedit-mode-toggle-on-function)))
(use-package ivy
:ensure t
:commands ivy-mode
:init (ivy-mode))
(use-package jabber
:ensure t
:disabled
:commands jabber-connect
:config (global-unset-key (kbd "C-x C-j"))
(global-set-key (kbd "C-x C-j") 'join-line)
(setq jabber-history-enabled t
jabber-history-muc-enabled t
jabber-alert-presence-message-function nil))
(use-package magit
:ensure t
:bind (("<f5> m" . #'magit-status)
:map magit-status-mode-map
;; ([mouse-3] . 'magit-section-toggle)
([down-mouse-3] . 'mouse-set-point)
([up-mouse-3] . 'magit-section-toggle))
:commands magit-status
:hook
(magit-post-stage . (lambda () (recenter))))
(use-package mediawiki
:ensure t
:commands mediawiki-mode)
(use-package midnight
:ensure t
:init
(midnight-mode)
:config
(setq clean-buffer-list-kill-regexps '("")
clean-buffer-list-delay-general 7
clean-buffer-list-delay-special (* 60 60 24 7))
:hook
(midnight . clean-buffer-list))
(use-package nodejs-repl
:ensure t
:config (setq nodejs-repl-command "nodejs"))
(use-package nov
:mode ("\\.epub\\'" . nov-mode))
(use-package package
:config
(when (featurep 'boon)
(general-def package-menu-mode-map
"X" 'package-menu-execute)))
(use-package paradox
:ensure t
:bind
("<f5> p" . #'paradox-list-packages)
:config (setq paradox-execute-asynchronously t)
(when (featurep 'boon)
(general-def paradox-menu-mode-map
"X" 'package-menu-execute)))
(use-package powerline
:ensure t)
(use-package rainbow-delimiters
:ensure t
:hook (prog-mode . rainbow-delimiters-mode))
(use-package swiper
:ensure t
:bind (("C-s" . swiper)
("C-r" . swiper-backward))
:config (add-to-list 'desktop-globals-to-save 'swiper-history))
(use-package sxiv
:config (setq sxiv-exclude-strings '("meh" "\\.NEF$")))
(use-package time
:ensure t
:config
(setq display-time-next-load-average t)
(add-to-list 'zoneinfo-style-world-list '("Europe/Berlin" "Berlin")))
;; (load "cp-adb")
(load "cp-editing")
;; (load "cp-evil")
(load "cp-fm")
(load "cp-lily")
(load "cp-sfz")
(require 'cp-lisp)
(require 'cp-nav)
;; (ispell-change-dictionary "en")
(setq ispell-dictionary "en")
(use-package undo-tree
:commands global-undo-tree-mode
:ensure t
:if (not (featurep 'evil))
:diminish undo-tree-mode
:init (global-undo-tree-mode))
(with-eval-after-load 'text-mode
(define-key text-mode-map (kbd "M-p") 'org-drag-line-backward)
(define-key text-mode-map (kbd "M-n") 'org-drag-line-forward))
(autoload 'byte-recompile-file "bytecomp" "byte-recompile-file" t)
;; (2017-12-29T13:21:57+0530
;; TODO - watch Org and MD files and recompile it if they are newer
;; than their associated HTML files (e.g. I edited the source on a
;; phone and synced it back to the laptop)
;; see (info "(elisp) File Notifications")
;; and (describe-function 'file-newer-than-file-p)
;; )
(defun cp/after-save ()
(let* ((file-path (buffer-file-name))
(file-path-shell (shell-quote-argument file-path)))
(case major-mode
('org-mode (org-html-export-to-html))
('LilyPond-mode (let ((project-dir (locate-dominating-file file-path
"main.ly")))
(when project-dir
(cd project-dir))
(compile (car compile-history))))
('latex-mode (if (file-exists-p "Makefile")
(compile (car compile-history))
(compile (concat "xelatex " file-path-shell))))
;; ('markdown-mode (markdown-export))
('c-mode (compile (concat "gcc -static -o "
(shell-quote-argument
(file-name-base))
" "
file-path-shell))))))
(add-hook 'after-save-hook 'cp/after-save)
;; (load "cp-helm")
(load "cp-hindi")
;; (load "cp-irc")
(load "cp-parens")
(load "cp-playlist")
(require 'keyfreq)
(keyfreq-mode 1)
(keyfreq-autosave-mode 1)
;; ;; disabled on 2017-08-18T19:39:21+0530, no longer interested
;; (open-dribble-file (concat "~/.emacs.d/keylogs/"
;; (format-time-string "%Y%m%d-%H%M%S")
;; ".txt"))
;; 2017-10-14T15:22:56+0530 - I suspect devanagari-itrans tires the
;; left hand faster than the right - let's find out!
(add-hook
'input-method-activate-hook
(lambda ()
(open-dribble-file
(concat
"~/.emacs.d/keylogs/"
(format-time-string "%Y%m%d-%H%M%S")
"-"
current-input-method
".txt"))))
(add-hook
'input-method-deactivate-hook
(lambda () (open-dribble-file nil)))
(use-package recentf
:init (recentf-mode 1)
:bind ("C-x C-r C-o" . recentf-open-files)
:config
(setq recentf-auto-cleanup 'never
recentf-max-menu-items 500
recentf-max-saved-items 1000
recentf-save-file "/home/anon/.emacs.d/recentf"
recentf-exclude '("\\.html\\(\\.orig\\)?$"
"\\.jpe?g$"
"\\.png$"
"\\.mp4$"
"\\.etc"
"\\.umstuff"))
:hook
(kill-emacs . recentf-cleanup))
(require 'cp-ido)
;;;; text size change
;; nicked from wasamasa's init - https://github.com/wasamasa/dotemacs/blob/934d0b37692d62fe9af56b52accac5bcd4445ae3/init.org
(setq default-frame-alist '((font . "DejaVu Sans Mono-10.5")))
(defun my-fix-emojis (&optional frame)
(set-fontset-font "fontset-default" nil "Symbola" frame 'append))
(my-fix-emojis)
(add-hook 'after-make-frame-functions 'my-fix-emojis)
;; (set-face-attribute 'default nil :font "-outline-Bitstream Vera Sans Mono-normal-normal-normal-mono-12-*-*-*-c-*-iso8859-1")
(require 'wgrep)
(setq custom-file "~/.emacs.d/custom.el")
(load custom-file)
(mapc (lambda (command)
(put command 'disabled nil))
'(downcase-region
upcase-region
set-goal-column
scroll-left
erc-remove-text-properties-region))
(require 'cp-org)
(require 'cp-desktop)
;; (toggle-debug-on-quit)
;; (profiler-stop)
;; (emacs-init-time)
;; (profiler-report)
;; Local Variables:
;; nameless-current-name: "contrapunctus"
;; End:
(provide 'init)
;;; init.el ends here

6040
init.org Normal file

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1,8 @@
# -*- mode: snippet -*-
# contributor: contrapunctus (tilde.team/~contrapunctus)
# name: cl-defgeneric
# key: dg
# --
(cl-defgeneric ${1:name} (${2:args})
"${3:docstring}"
$0)

View File

@ -0,0 +1,7 @@
# -*- mode: snippet -*-
# contributor: contrapunctus (tilde.team/~contrapunctus)
# name: cl-defmethod
# key: dm
# --
(cl-defmethod ${1:name} (${2:args})
$0)

View File

@ -0,0 +1,8 @@
# -*- mode: snippet -*-
# contributor: contrapunctus (tilde.team/~contrapunctus)
# name: defclass
# key: dc
# --
(defclass ${1:name} (${2:superclasses})
(${3:slots})
:documentation "${0:docstring}")

View File

@ -0,0 +1,6 @@
# -*- mode: snippet -*-
# name: defcustom
# key: dc
# --
(defcustom ${1:symbol} ${2:standard}
"${3:doc}"$0)

View File

@ -0,0 +1,7 @@
# -*- mode: snippet -*-
# name: defhydra
# key: dh
# --
(defhydra ${1:name} (${2:args})
${3:"docstring"}
$0)

View File

@ -0,0 +1,5 @@
# -*- mode: snippet -*-
# name: find-file-noselect
# key: ffns
# --
(find-file-noselect ${1:file})$0

View File

@ -0,0 +1,5 @@
# -*- mode: snippet -*-
# name: get-file-buffer
# key: gfb
# --
(get-file-buffer ${1:file})$0

View File

@ -0,0 +1,5 @@
# -*- mode: snippet -*-
# name: goto-char-point-min
# key: gcpm
# --
(goto-char (point-min))

View File

@ -0,0 +1,5 @@
# -*- mode: snippet -*-
# name: lambda
# key: l
# --
(lambda (${1:arg}) $0)

View File

@ -0,0 +1,5 @@
# -*- mode: snippet -*-
# name: point-max
# key: pm
# --
(point-max)

View File

@ -0,0 +1,5 @@
# -*- mode: snippet -*-
# name: read-current-buffer
# key: rcb
# --
(read (current-buffer))

View File

@ -0,0 +1,5 @@
# -*- mode: snippet -*-
# name: with-slots
# key: ws
# --
(with-slots (${1:slots}) ${2:object})$0

View File

@ -0,0 +1,8 @@
# -*- mode: snippet -*-
# contributor: Mark Karpov
# name: my-defclass
# key: dc
# --
(defclass ${1:name} (${2:parents})
($0)${3:
(:documentation "${4:doc}")})

View File

@ -0,0 +1,8 @@
# -*- mode: snippet -*-
# contributor: contrapunctus (tilde.team/~contrapunctus)
# name: defgeneric
# key: dg
# --
(defgeneric ${1:name} (${2:args})
"${3:docstring}")
$0

View File

@ -0,0 +1,7 @@
# -*- mode: snippet -*-
# contributor: contrapunctus (tilde.team/~contrapunctus)
# name: my-defmethod
# key: dm
# --
(defmethod ${1:name} (${2:args})
$0)

View File

@ -0,0 +1,12 @@
# -*- mode: snippet -*-
# contributor: Mark Karpov
# name: my-defpackage
# key: dp
# --
(defpackage :${1:package}${2:
(:nicknames ${3:nicks})}${4:
(:use ${5:packages})}${6:
(:shadow ${7:packages})}${8:
(:export ${9:packages})}${10:
(:documentation "${11:doc}")})
$0

View File

@ -0,0 +1,7 @@
# -*- mode: snippet -*-
# contributor: Mark Karpov
# name: my-in-package
# key: ip
# --
(in-package :${1:package})
$0

View File

@ -0,0 +1,5 @@
# -*- mode: snippet -*-
# name: in-package
# key: ip
# --
(in-package :${0:package})

View File

@ -0,0 +1,5 @@
# -*- mode: snippet -*-
# name: quickload
# key: qq
# --
(ql:quickload :${1:system} $0)

68
templates Normal file
View File

@ -0,0 +1,68 @@
;;; -*- mode: emacs-lisp; -*-
emacs-lisp-mode
(dc "(defcustom " (s "symbol") " " (s "standard")
n> "\"" (s "docstring") "\""
n> ":type '" (s "type") ")")
(dg "(defgroup " p " nil\n \"" p "\"" n> ":group '" p n> ":prefix \"" p "-\")")
(cdg "(cl-defgeneric " p " (" ")" n> ")")
(cdm "(cl-defmethod " p " (" ")" n> ")")
(pm "(point-min)")
(pM "(point-max)")
(up "(use-package " (p "package") ")")
lisp-mode emacs-lisp-mode inferior-emacs-lisp-mode slime-repl-mode
(la "(lambda (" p ")" n> r> ")")
;; (l "(lambda (" (s "arguments") ") " (s "forms") ")")
(dv "(defvar " (p "symbol" symbol) " " (p "value")
n> "\"" (p "doc") "\"" ")")
(dm "(defmethod " (p "name") " (" (p "arguments") ")" n> q ")")
(df "(defun " (p "name") " (" (s "arguments") ")" n> r> ")")
(l "(let (" p ")" n> r> q ")")
(ls "(let* (" p ")" n> r> q ")")
(ws "(with-slots (" (p "slots") ") " (p "object") n> ")")
slime-repl-mode lisp-mode
(dc "(defclass " (p "symbol") " (" (s "superclasses") ")" n>
"(" p ")" q ")")
(s "(%" (s slot)
" :initarg :" (s slot) n>
" :accessor " (s slot) > ")")
(d ":documentation \"" (s "docstring") "\"")
(if ":initform " q)
(dg "(defgeneric " p " (" "))")
(qq "(ql:quickload '(" (p "packages") "))")
(dp "(defpackage :" (p "name")
n> "(:use :cl)" q ")")
(up "(use-package '(" (p "package") "))")
(ip "(in-package :" (p "package") ")")
(ln "(:local-nicknames (:" (p "nickname") " :" (p "package-name") ")" q ")")
(c "#+(or)")
;; print debugging
(pd "(format *debug-io* \"" q "~%\")")
(im "(:import-from :" (s "package") " #:" (s "symbol") ")")
(di "(:default-initargs " (s "initarg") ")")
(ii "(defmethod initialize-instance :after" n>
" ((" p ") &rest initargs &key &allow-other-keys)"
n> q ")")
(qu "(ql:update-all-dists)" n> "(ql:update-client)")
(dpmp
"(define-presentation-method present "
n> "(object (type " (p "t") ") (stream " (p "t") ") view &key acceptably for-context-type)"
n> q ")")
sql-mode
(ct "CREATE TABLE " (s "table") " ("
n " " (s "column") ","
n ");")
latex-mode
(be "\\begin{" (s env) "}" > n> r> "\\end{" (s env) "}")
(e "\\begin{enumerate}\n\\item " r> n> "\\end{enumerate}")
(i "\\begin{itemize}\n\\item " r> n> "\\end{itemize}")
texinfo-mode
(i "@include ")
org-mode
(b "[ ] ")