spacemacs/alternate-window was suggested to switch between the last selected
window, or the window-analog of SPC TAB (spacemacs/alternate-buffer). This is
part of a larger family of functions, such as spacemacs/jump-to-last-layout on
SPC l TAB and eyebrowse-last-window-config on SPC l w TAB.
Resolves#7845
Some directories were added twice.
Make it more explicit in the code which directories we look into and filter out
directories that don't exist. Emit a warning if an unknown directory is
provided.
Given the loading process of Spacemacs we have no choice but to set the
custom settings twice:
- once at the very beginning of startup
- once at the very end of loading
The first application of custom settings is to be sure that Emacs knows all the
defined settings before saving them to a file (otherwise we loose all the
settings that Emacs does not know of).
The second application is to override any settings set in dotfile functions
like `dotspacemacs/user-config`, users expect the custom settings to be the
effective ones.
This double loading issue is independent from the managment method used for
custom settings. Even with a separate custom-settings file explicitly loaded in
the dotfile we would have been forced to load this file twice to acheive the
expected result described here.
Note: Loading custom-settings twice is not ideal since they can have side
effects! Maybe an inhibit variable in Emacs can supress these side effects?
New function `dotspacmacs/emacs-custom-settings` wrapping Emacs
custom settings sexps.
`dotspacemacs/emacs-custom-settings` is called just after the user
configuration (`dotspacemacs/user-config`)
Customize cannot write its auto-generated sexps inside a function, to
accomplish this we trick Emacs by setting the custom file to a file
in `.cache` directory, the path to this file is defined by the variable
`spacemacs--custom-file`. At the startup of Emacs we read this file
to insert its content inside the function
`dotspacemacs/emacs-custom-settings` in the dotfile, this is done in the
function `spacemacs/write-custom-settings-to-dotfile`.
I don't think we need to write the custom settings to the dotfile when
exiting Emacs as well, since we do it at startup at the very beginning
(i.e. before actually loading the dotfile) we should be OK.
Fixes#5170
When upgrading packages, Spacemacs backs up the old versions of the
packages and then tells the user to restart Emacs using `SPC q r` so
that the new version will be auto-installed. But `SPC q r` doesn't
work if restart-emacs is one of the packages which is being upgraded,
and hence isn't currently installed.
enumeration lists of the form:
- lorem ipsum
* lorem ipsum
+ lorem ipsum
1. lorem ipsum
2) lorem ipsum
will be treated as separate paragraphes and not be squished by
fill-region anymore.
More flexible framed text generation:
- adjust frame width to content width
- define minimum and maximum width
- allow for inserting a caption at the bottom of the frame
Unless dotspacemacs-startup-buffer-respinsive is nil:
- framed notes are centered
- max width is adapted to the window width
Also add a note inviting the user to update his packages and dotfile on
every new release (fixes#7357).
With a nil value for dotspacemacs-switch-to-buffer-prefers-purpose,
switch-to-buffer prefers using the current window, same as vanilla
Emacs. With a non-nil value, switch-to-buffer prefers another window
with the same purpose as the buffer. This affects actions like
spacemacs/alternate-buffer, and opening buffers from Dired.
Cleaned up a warning that occurs when loading private layers
The layer discovery loop scans the private layer directory (
~/.spacemacs.d/layers) AND also ~/.spacemacs.d
The code then checks if a layer directory already exists
but the comparison fails due to trailing / in some paths.
The fix is to strip any trailing slash from both directories being
compared.