Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enable line numbers for conf-mode too #6947

Closed
valignatev opened this issue Aug 28, 2016 · 6 comments
Closed

Enable line numbers for conf-mode too #6947

valignatev opened this issue Aug 28, 2016 · 6 comments

Comments

@valignatev
Copy link
Contributor

valignatev commented Aug 28, 2016

Hi! For now dotspacemacs-line-numbers enables line numbers only for prog-mode and for text-mode. Why not activate it for conf-mode too by default? I think it's very common to have line numbers shown when editing configuration files. For now I use

(when dotspacemacs-line-numbers
  (add-hook 'conf-mode-hook 'linum-mode)

for this. I can make PR to config.el if you don't mind :)

@valignatev valignatev changed the title enable line numbers for conf-mode too Enable line numbers for conf-mode too Aug 28, 2016
@TheBB
Copy link
Contributor

TheBB commented Aug 28, 2016

Hold on a minute. The reason for this is not that it was forgotten, rather that conf-mode is implemented as a function and not a genuine major mode, a characteristic it shares with a number of others, e.g. matlab-mode, which is fixed like this. You can make the same tweak for conf-mode (deriving from text-mode seems reasonable).

@valignatev
Copy link
Contributor Author

Thanks for clearing things.
The main reason I created this issue is to know if it was made intentionally and why. Not gonna make PRs just because something is unclear to me, I think there are too many of them already.

@TheBB TheBB reopened this Aug 29, 2016
@TheBB
Copy link
Contributor

TheBB commented Aug 29, 2016

I'll do it then.

@valignatev
Copy link
Contributor Author

@TheBB Now I'm a little bit wrap my brains around code repo and I think I can do it. But where should I put such fix? For now I think that Edit section of spacemacs/layers/+distribution/spacemacs-base/config.el might be a good place. What do you think?

@TheBB
Copy link
Contributor

TheBB commented Sep 2, 2016

I would add another package in spacemacs-base/packages.el called conf or something. Make sure it's built-in like most of the others. Then make an init-function for that package, and you can put the add-hook in there.

@valignatev
Copy link
Contributor Author

Just did a PR to develop branch. Sorry in advance if anything bad with it, I'm always ready to improve :)

zv added a commit to zv/spacemacs that referenced this issue Nov 2, 2016
* checkversion/master: (82 commits)
  Bump version to 0.200.4
  Update changelog and bump version to 0.200.4
  go-guru on MELPA
  Delete changelog.develop file
  Update change logs and bump version to 0.200.3
  nim: fix key bindings in README
  Add Spacemacs Shop mention and badge in README
  Add achievements
  Add bmag collaborator to COMMUNITY.org
  Show warnings in home buffer
  Warn if layers changed outside dotspacemacs/layers
  Remove check for GOPATH when init go-guru
  Add hide/show comments on SPC c h
  New package insert-shebang
  Match entire path after -I for passing to expand-file-name.
  Add missing prefices for js2-mode
  elixir: flycheck on idle
  Describe scss-lint setup
  Fix syl20bnr#6947 by deriving conf-mode from text-mode
  Evil Nr TS, add 0..9 prefix and q quit
  ...
george-miller pushed a commit to george-miller/spacemacs that referenced this issue Nov 14, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants