On Fri, Nov 30, 2018 at 1:51 PM Ehsan Akhgari <ehsan.akhg...@gmail.com> wrote: > I think these are all great points. It seems like for Emacs, it is not > actually necessary to sprinkle modelines across all of the files in your > repository (per https://bugzilla.mozilla.org/show_bug.cgi?id=1023839#c7). > For Vim, Benjamin Bouvier just landed a patch in > https://bugzilla.mozilla.org/show_bug.cgi?id=1511383 to update the existing > modelines to have proper line width and tab width. > > It seems like for Emacs, we should probably do something similar also > relatively soon merely to address the newly introduced inconsistencies due > to the reformat. But I'd like to hear from Emacs users what they think, > and if they have a preference on updating existing modelines vs using a > .dir-locals.el file instead...
Using .dir-locals.el sounds great, at least for things like indent-tabs-mode and c-basic-offset. Emacs 23 is older than what comes with Ubuntu 14.04 (LTS), so I think we're in the clear using it as far as Emacs versions go. Google's style guide comes with a builtin style for emacs's cc-mode: https://raw.githubusercontent.com/google/styleguide/gh-pages/google-c-style.el which we could just import into .dir-locals.el. Unfortunately, it doesn't look like .dir-locals.el provides any way to set file modes, e.g. setting python-mode for moz.build file, as some modelines need to do, so we'd need to keep at least the mode bits around for those files. That doesn't seem too bad. -Nathan _______________________________________________ dev-platform mailing list dev-platform@lists.mozilla.org https://lists.mozilla.org/listinfo/dev-platform