Comments (1)
I work around it by conditionally disabling save on idle if certain modes are enabled. Specifically those involved with formatting-on-save.
(use-package super-save :defer t
:init
(doom-load-packages-incrementally '(super-save))
:config
(defvar +super-save-disabled-major-modes '()
"Major modes in which super-save on idle is disabled.")
(defvar +super-save-disabled-minor-modes '(apheleia-mode format-all-mode)
"Modes when enabled cause super-save to be disabled.")
(defvar +super-save-auto-disable-idle 't
"Automatically disable idle based on major and minor modes.")
(defun +super-save-auto-disable-idle ()
"Automatically disable based on major and minor modes."
(not (or (member major-mode +super-save-disabled-major-modes)
;; bound-and-true-p takes a variable, not a symbol
(-some (lambda (elm) (and (boundp elm) elm))
+super-save-disabled-minor-modes))))
(when +super-save-auto-disable-idle
(add-to-list 'super-save-predicates #'+super-save-auto-disable-idle))
(setq auto-save-default nil
super-save-auto-save-when-idle t
super-save-idle-duration 30
super-save-remote-files nil
super-save-exclude '(".gpg"))
(super-save-mode +1))
from super-save.
Related Issues (20)
- mouse-leave-buffer-hook not working when clicking on a GUI application
- Possible to set this to `do-auto-save` of the current file instead of `save-buffer`
- [Feature Request] add super-save-exclude
- Can I have different values for "super-save-idle-duration" according to mode?
- Would it be possible to completely disable all modification notices? HOT 2
- How to exclude files from peep-dired ?
- Conflict with blacken mode HOT 2
- Evaluating "super-save-exclude" doesn't seem to work
- Impossible to disable `super-save-mode` HOT 2
- Changing "super-save-idle-duration" has no effect unless I reboot HOT 1
- How to stop saving on mouse left click HOT 2
- org-mode capture prevents saving when emacs looses focus HOT 1
- Any workarounds for using super-save along with lv-message? HOT 4
- Disabling super-save-max-buffer-size (confusing new behavior) HOT 5
- ow mode
- not working in org-mode (doom-emacs) HOT 2
- Usage of (save-excursion) SF interferes with format-on-save configuration in Clojure/Cider setups HOT 3
- How can I save buffers modified in the background?
- How can I save files changed in the background? HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from super-save.