Open mensch opened 7 years ago
Hi @mensch
Can you press cmd + .
to toggle keybindings resolver and then press ctrl + enter
and share with us the screenshot?
Hmm, that's weird. Using the keyboard of my Macbook Pro I'm able to trigger the intentions list. I originally reported the bug while using my work setup, where I work on a wired Apple keyboard. I'll try that setup again and make a screenshot.
After triggering the intentions list I'm not able to select the "Fix linter issue". Is there another shortcut or should I be able to click or navigate with the arrow keys?
You should be able to press enter / click the items in list, if it doesn't, let me know so I can investigate and eventually fix
Ah yes, you're right. When I press enter the error is automatically fixed. The intention isn't highlighted in the One Light theme though, hence my presumption it couldn't be selected. Only when I switch to the Atom Dark theme the highlighting is visible.
Clicking the intention doesn't work for me, this resembles bug #28, I believe. When I click the intention it disappears, but doesn't apply the fix. Retriggering the list with ctrl+enter
shows the list in a flash and is dismissed automatically.
I'll try my external keyboard tonight to see if I can trigger the intention list.
Just a note, although fixing individual issues like that works, with ESLint you are much better off running the Linter Eslint: Fix issues
command as that invokes ESLint's own fix mechanism which has conflict resolution between conflicting fixes. Applying all ESLint fixes from linter
itself can lead to your file getting broken as each message is taken individually instead of as a whole.
Thanks for the tip @Arcanemagus!
Weird, the shortcut now works when using an external keyboard. The other issues (clicking and highlighting) remain, however.
@mensch: maybe you are using vim-mode-plus ? In my case that was the problem, see #28.
Hey, I seem to be having an issue where the intentions list is never triggered. The keybindings resolver is showing is definitely triggering correctly, but doesn't display anything. Do I have to install specific intentions-compatible packages? I'm currently looking for ESLint, Prettier, auto import, etc.
@dac09 Yes, you need something that provides intentions
first, linter
+ linter-ui-default
would do that for linter-eslint
, but as stated above that isn't the best way to apply fixes from ESLint.
I've been attempting to use the "Fix linter issue" intention, but I can't seem to trigger the list on macOS using the default command
ctrl+enter
. At first I thought the new Git commands were interfering (committing is also done usingctrl+enter
), but after setting a new shortcut in mykeymap.cson
(ctrl+alt+enter
) the list still isn't triggered.I've tried the behaviour in JavaScript (linter-eslint), PHP (linter-php) and SCSS files (linter-stylehint) containing errors, but the menu nevers shows. Not sure if every linter package has an autofix intention, but I was under the impression that eslint does. I'm using Atom 1.18.0 on macOS Sierra and the error console doesn't show any errors when attempting to trigger the intentions.