sindresorhus / atom-editorconfig

Helps developers maintain consistent coding styles between different editors
https://atom.io/packages/editorconfig
MIT License
812 stars 80 forks source link

Not working since upgrade to Atom 1.3 #220

Closed Redsandro closed 5 years ago

Redsandro commented 6 years ago

Since Atom upgraded to 1.3, Atom is not setting the tab width to 4 spaces anymore.

Or it does, but then it switches back. When closing and re-opening Atom, you can clearly see every tab being 2 spaces wide, switching to 4 spaces for half a second, and switching back to 2 spaces again.

It looks like something else is overruling the atom-editorconfig package.

Anyone else experiencing this since Atom 1.3?

Involved .editorconfig-files

root = true

[*]
end_of_line = lf
charset = utf-8
trim_trailing_whitespace = true
insert_final_newline = true
indent_style = tab
indent_size = 4

Installed packages

Built-in Atom Packages (92)
├── atom-dark-syntax@0.29.0
├── atom-dark-ui@0.53.2
├── atom-light-syntax@0.29.0
├── atom-light-ui@0.46.2
├── base16-tomorrow-dark-theme@1.5.0
├── base16-tomorrow-light-theme@1.5.0
├── one-dark-ui@1.11.0
├── one-light-ui@1.11.0
├── one-dark-syntax@1.8.2
├── one-light-syntax@1.8.2
├── solarized-dark-syntax@1.1.4
├── solarized-light-syntax@1.1.4
├── about@1.8.0
├── archive-view@0.64.3
├── autocomplete-atom-api@0.10.7
├── autocomplete-css@0.17.5
├── autocomplete-html@0.8.4
├── autocomplete-plus@2.40.5
├── autocomplete-snippets@1.12.0
├── autoflow@0.29.3
├── autosave@0.24.6
├── background-tips@0.28.0
├── bookmarks@0.45.1
├── bracket-matcher@0.89.1
├── command-palette@0.43.5
├── dalek@0.2.2
├── deprecation-cop@0.56.9
├── dev-live-reload@0.48.1
├── encoding-selector@0.23.8
├── exception-reporting@0.43.1
├── find-and-replace@0.215.5
├── fuzzy-finder@1.8.1
├── github@0.12.0
├── git-diff@1.3.9
├── go-to-line@0.33.0
├── grammar-selector@0.50.0
├── image-view@0.62.4
├── incompatible-packages@0.27.3
├── keybinding-resolver@0.38.1
├── line-ending-selector@0.7.5
├── link@0.31.4
├── markdown-preview@0.159.20
├── metrics@1.2.6
├── notifications@0.70.5
├── open-on-github@1.3.1
├── package-generator@1.3.0
├── settings-view@0.254.2
├── snippets@1.3.3
├── spell-check@0.73.4
├── status-bar@1.8.15
├── styleguide@0.49.10
├── symbols-view@0.118.2
├── tabs@0.109.1
├── timecop@0.36.2
├── tree-view@0.221.3
├── update-package-dependencies@0.13.1
├── welcome@0.36.6
├── whitespace@0.37.5
├── wrap-guide@0.40.3
├── language-c@0.59.3
├── language-clojure@0.22.7
├── language-coffee-script@0.49.3
├── language-csharp@1.0.1
├── language-css@0.42.10
├── language-gfm@0.90.3
├── language-git@0.19.1
├── language-go@0.45.3
├── language-html@0.49.0
├── language-hyperlink@0.16.3
├── language-java@0.29.0
├── language-javascript@0.128.5
├── language-json@0.19.1
├── language-less@0.34.2
├── language-make@0.22.3
├── language-mustache@0.14.5
├── language-objective-c@0.15.1
├── language-perl@0.38.1
├── language-php@0.43.2
├── language-property-list@0.9.1
├── language-python@0.49.4
├── language-ruby@0.71.4
├── language-ruby-on-rails@0.25.3
├── language-sass@0.61.4
├── language-shellscript@0.26.3
├── language-source@0.9.0
├── language-sql@0.25.10
├── language-text@0.7.4
├── language-todo@0.29.4
├── language-toml@0.18.2
├── language-typescript@0.3.3
├── language-xml@0.35.2
└── language-yaml@0.32.0

Community Packages (58) /home/redsandro/.atom/packages
├── atom-autocomplete-php@0.25.6
├── atom-beautify@0.32.4
├── atom-debug-ui@1.0.4
├── atom-handlebars@1.3.0
├── atom-ide-ui@0.12.0
├── atom-node-v8-inspector@0.1.1 (disabled)
├── atom-symfony@1.2.0
├── atom-symfony2@0.3.0
├── atom-ternjs@0.18.3
├── atom-typescript@12.5.0
├── autoclose-html@0.23.0
├── busy-signal@1.4.3
├── docblockr@0.13.7
├── editorconfig@2.2.2
├── file-icons@2.1.21
├── git-history@3.3.0
├── git-time-machine@2.0.1
├── goto-definition@1.3.4
├── highlight-selected@0.13.1
├── ide-php@0.7.14
├── intentions@1.1.5
├── js-refactor@0.8.1
├── language-actionscript3@0.3.0
├── language-docker@1.1.8
├── linter@2.2.0 (disabled)
├── linter-eslint@8.4.1
├── linter-flexpmd@0.1.9
├── linter-jshint@3.1.8
├── linter-php@1.5.1
├── linter-phpcs@1.6.8
├── linter-pylint@2.1.1
├── linter-sass-lint@1.8.3
├── linter-ui-default@1.7.1
├── merge-conflicts@1.4.5
├── minimap@4.29.8
├── minimap-cursorline@0.2.0
├── minimap-find-and-replace@4.5.2
├── minimap-git-diff@4.3.1
├── minimap-highlight-selected@4.6.1
├── minimap-linter@2.1.3
├── minimap-split-diff@0.3.7
├── monokai-dark@1.5.0
├── monokai-seti@0.9.0
├── node-debugger@1.10.1 (disabled)
├── php-cs-fixer@4.1.1
├── php-debug@0.3.4 (disabled)
├── php-getters-setters@0.5.5
├── php-twig@4.0.0
├── pigments@0.40.2
├── pretty-json@2.0.0
├── refactor@0.11.5
├── seti-ui@1.10.0
├── split-diff@1.5.2
├── todo-show@2.3.0
├── toggle-quotes@1.1.0
├── xatom-debug@1.6.11 (disabled)
├── xatom-debug-nodejs@0.9.3 (disabled)
└── xml-formatter@0.11.0
mjlehrke commented 5 years ago

I too have noticed this is not working. Atom 1.30.0.

florianb commented 5 years ago

Hi @mjlehrke - thanks for reporting this.

lobsterdore commented 5 years ago

I am seeing this as well with 1.31.1 on Ubuntu Bionic, Editor config kicks in briefly for opened files but always reverts to the Atom defaults after a few seconds.

EdwinHuijsing commented 5 years ago

Have two project project A: php and it is a git repo project B: php and it is not git repo

In project A editorconfig works, in projectB it does not work. In the developers tools I noted a error about missing git repo in project B. That's the moment I run git init, reopen the current document. And all is working now.

So the workaround around is: make the project directory a git repo.

And yes I know, its not always possible to make a directory a git repo. Let's op the fix will be created soon.

HTH

mcandre commented 5 years ago

Yeah, atom-editorconfig is acting off on macOS as well.

Alhadis commented 5 years ago

So the workaround around is: make the project directory a git repo.

It's really odd this is happening only for non-Git projects. I'm guessing the activation of a Git-related core package triggered a refresh of open editors at startup.

Anyway, the fix I've applied in 304836a isn't perfect... the flickering is still visible, but at least it settles with the correct properties applied. If anybody's still experiencing this issue, please let me know.