Move swiftpm-project-settings.el
settings to .dir-locals.el
#7314
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Directory-local variables have been moved so that they are set directly
in
.dir-locals.el
.Motivation:
The variables set in
swiftpm-project-settings.el
can be set directlyin
dir-locals.el
. There is no reason to move them to a separate file,and in fact doing that will automatically make Emacs flag the dir-locals
as unsafe, since it will be being requested to evaluate a block of code,
instead of setting known-safe variables.
Modifications:
Utilities/Emacs/swiftpm-project-settings.el
has been removed. All variablesset in it have been moved to
.dir-locals.el
itself. This allows the evaluationof all directory locals to be considered safe.
Additionally,
swift-basic-offset
was changed toswift-mode:basic-offset
.That appears to be the proper variable for setting indent width for Swift in Emacs.
Result:
Emacs users can edit the project more peacefully.