check out my latest app: Doodle Draw
and my latest blog post
[DEPRECATED] Automagically fix JSHint lint warnings
Home Page: https://atom.io/packages/fixmyjs
License: MIT License
check out my latest app: Doodle Draw
and my latest blog post
[Enter steps to reproduce below:]
Atom Version: 0.188.0
System: Mac OS X 10.10.2
Thrown From: fixmyjs package, v1.3.0
Failed to activate the fixmyjs package
At Cannot find module 'fixmyjs'
Error: Cannot find module 'fixmyjs'
at Module._resolveFilename (module.js:351:15)
at Function.Module._resolveFilename (/Applications/Atom.app/Contents/Resources/app/src/module-cache.js:383:52)
at Function.Module._load (module.js:293:25)
at Module.require (module.js:380:17)
at require (module.js:399:17)
at Object.<anonymous> (/Users/felipebhz/.atom/packages/fixmyjs/index.js:2:15)
at Module._compile (module.js:475:26)
at Object.loadFile [as .js] (/Applications/Atom.app/Contents/Resources/app/src/babel.js:162:21)
at Module.load (module.js:370:32)
at Function.Module._load (module.js:325:12)
at Module.require (module.js:380:17)
at require (module.js:399:17)
at Package.module.exports.Package.requireMainModule (/Applications/Atom.app/Contents/Resources/app/src/package.js:678:34)
at Package.module.exports.Package.activateConfig (/Applications/Atom.app/Contents/Resources/app/src/package.js:257:12)
at Package.module.exports.Package.activateNow (/Applications/Atom.app/Contents/Resources/app/src/package.js:236:14)
at /Applications/Atom.app/Contents/Resources/app/src/package.js:741:25
at Emitter.module.exports.Emitter.emit (/Applications/Atom.app/Contents/Resources/app/node_modules/event-kit/lib/emitter.js:82:11)
at CommandRegistry.module.exports.CommandRegistry.handleCommandEvent (/Applications/Atom.app/Contents/Resources/app/src/command-registry.js:223:20)
at /Applications/Atom.app/Contents/Resources/app/src/command-registry.js:3:61
at CommandPaletteView.module.exports.CommandPaletteView.confirmed (/Applications/Atom.app/Contents/Resources/app/node_modules/command-palette/lib/command-palette-view.js:120:32)
at CommandPaletteView.module.exports.SelectListView.confirmSelection (/Applications/Atom.app/Contents/Resources/app/node_modules/atom-space-pen-views/lib/select-list-view.js:338:21)
at space-pen-div.atom.commands.add.core:confirm (/Applications/Atom.app/Contents/Resources/app/node_modules/atom-space-pen-views/lib/select-list-view.js:109:19)
at CommandRegistry.module.exports.CommandRegistry.handleCommandEvent (/Applications/Atom.app/Contents/Resources/app/src/command-registry.js:242:29)
at /Applications/Atom.app/Contents/Resources/app/src/command-registry.js:3:61
at KeymapManager.module.exports.KeymapManager.dispatchCommandEvent (/Applications/Atom.app/Contents/Resources/app/node_modules/atom-keymap/lib/keymap-manager.js:558:16)
at KeymapManager.module.exports.KeymapManager.handleKeyboardEvent (/Applications/Atom.app/Contents/Resources/app/node_modules/atom-keymap/lib/keymap-manager.js:396:22)
at HTMLDocument.module.exports.WindowEventHandler.onKeydown (/Applications/Atom.app/Contents/Resources/app/src/window-event-handler.js:180:20)
5x -0:30.5 core:backspace (atom-text-editor.editor.is-focused)
-0:02.7 command-palette:toggle (atom-text-editor.editor.is-focused)
-0:00.8 core:confirm (atom-text-editor.editor.mini)
-0:00.6 FixMyJS (atom-text-editor.editor.is-focused)
{
"core": {}
}
# User
autocomplete-plus, v2.7.1
editor-stats, v0.17.0
fixmyjs, v1.3.0
linter, v0.12.0
linter-jshint, v0.1.0
# Dev
No dev packages
I got an error if I run it on an unsaved file. I think it would be really nice to handle this as well.
Uncaught TypeError: Arguments to path.resolve must be strings
I installed npm install fixmyjs -g
but attempting to install fixmyjs in atom results in an Error.
Atom Version: 1.0.19
System: Microsoft Windows 7 Ultimate
Thrown From: fixmyjs package, v1.3.4
Uncaught Error: Cannot find module 'fixmyjs'
At module.js:336
Error: Cannot find module 'fixmyjs'
at Module._resolveFilename (module.js:334:15)
at Function.Module._resolveFilename (C:\Users\Rkhayat\AppData\Local\atom\app-1.0.19\resources\app.asar\src\module-cache.js:383:52)
at Function.Module._load (module.js:284:25)
at Module.require (module.js:363:17)
at require (module.js:382:17)
at Object.<anonymous> (C:\Users\Rkhayat\.atom\packages\fixmyjs\index.js:9:16)
at Module._compile (module.js:428:26)
at Object.defineProperty.value [as .js] (C:\Users\Rkhayat\AppData\Local\atom\app-1.0.19\resources\app.asar\src\compile-cache.js:169:21)
at Module.load (module.js:353:32)
at Function.Module._load (module.js:308:12)
at Module.require (module.js:363:17)
at require (module.js:382:17)
at Package.module.exports.Package.requireMainModule (C:\Users\Rkhayat\AppData\Local\atom\app-1.0.19\resources\app.asar\src\package.js:761:34)
at Package.module.exports.Package.activateConfig (C:\Users\Rkhayat\AppData\Local\atom\app-1.0.19\resources\app.asar\src\package.js:263:14)
at PackageDetailView.module.exports.PackageDetailView.activateConfig (C:\Users\Rkhayat\AppData\Local\atom\app-1.0.19\resources\app.asar\node_modules\settings-view\lib\package-detail-view.js:212:26)
at PackageDetailView.module.exports.PackageDetailView.completeInitialzation (C:\Users\Rkhayat\AppData\Local\atom\app-1.0.19\resources\app.asar\node_modules\settings-view\lib\package-detail-view.js:156:12)
at PackageDetailView.module.exports.PackageDetailView.loadPackage (C:\Users\Rkhayat\AppData\Local\atom\app-1.0.19\resources\app.asar\node_modules\settings-view\lib\package-detail-view.js:168:21)
at C:\Users\Rkhayat\AppData\Local\atom\app-1.0.19\resources\app.asar\node_modules\settings-view\lib\package-detail-view.js:298:17
at Emitter.module.exports.Emitter.emit (C:\Users\Rkhayat\AppData\Local\atom\app-1.0.19\resources\app.asar\node_modules\event-kit\lib\emitter.js:82:11)
at PackageManager.module.exports.PackageManager.emitPackageEvent (C:\Users\Rkhayat\AppData\Local\atom\app-1.0.19\resources\app.asar\node_modules\settings-view\lib\package-manager.js:588:27)
at C:\Users\Rkhayat\AppData\Local\atom\app-1.0.19\resources\app.asar\node_modules\settings-view\lib\package-manager.js:379:26
at exit (C:\Users\Rkhayat\AppData\Local\atom\app-1.0.19\resources\app.asar\node_modules\settings-view\lib\package-manager.js:60:16)
at triggerExitCallback (C:\Users\Rkhayat\AppData\Local\atom\app-1.0.19\resources\app.asar\src\buffered-process.js:213:47)
at ChildProcess.<anonymous> (C:\Users\Rkhayat\AppData\Local\atom\app-1.0.19\resources\app.asar\src\buffered-process.js:235:18)
at emitTwo (events.js:87:13)
at ChildProcess.emit (events.js:172:7)
at Process.ChildProcess._handle.onexit (internal/child_process.js:200:12)
-7:01.2.0 core:select-all (atom-text-editor.editor.mini.is-focused)
-6:58.1.0 core:confirm (atom-text-editor.editor.mini.is-focused)
-6:13.3.0 core:select-all (atom-text-editor.editor.mini.is-focused)
2x -6:11.9.0 core:backspace (atom-text-editor.editor.mini.is-focused)
-6:09.6.0 core:confirm (atom-text-editor.editor.mini.is-focused)
-5:49.4.0 core:select-all (atom-text-editor.editor.mini.is-focused)
-5:47.2.0 core:confirm (atom-text-editor.editor.mini.is-focused)
-4:48.8.0 core:select-all (atom-text-editor.editor.mini.is-focused)
-4:48.7.0 core:paste (atom-text-editor.editor.mini.is-focused)
-4:48.4.0 core:confirm (atom-text-editor.editor.mini.is-focused)
-0:46.6.0 core:select-all (atom-text-editor.editor.mini.is-focused)
-0:46.5.0 core:paste (atom-text-editor.editor.mini.is-focused)
-0:46.1.0 core:confirm (atom-text-editor.editor.mini.is-focused)
{
"core": {}
}
# User
angularjs, v0.3.3
angularjs-snippets, v0.10.18
Atom-Syntax-highlighting-for-Sass, v0.5.0
atom-ternjs, v0.8.4
autoclose-html, v0.19.0
autocomplete-html-entities, v0.1.0
autocomplete-modules, v1.3.0
autocomplete-paths, v1.0.2
autocomplete-sass, v0.1.0
color-picker, v2.0.13
css-comb, v2.4.0
css-snippets, v0.9.0
emmet, v2.3.13
es-identifier-highlight, v0.2.7
fancy-bracket-matcher, v0.4.1
file-icons, v1.6.10
file-type-icons, v0.7.3
formatter, v2.12.3
highlight-column, v0.5.0
highlight-line, v0.11.0
highlight-selected, v0.10.1
jsformat, v0.9.0
jshint, v1.8.1
language-babel, v0.15.7
language-javascript-jsx, v0.3.7
linter, v1.8.1
linter-jsxhint, v0.1.2
minimap, v4.13.4
minimap-bookmarks, v0.1.0
minimap-find-and-replace, v4.3.1
minimap-highlight-selected, v4.3.1
minimap-selection, v4.3.1
nodejs-snippets, v1.0.3
pane-info, v1.0.0
pigments, v0.18.0
project-manager, v2.6.4
react, v0.12.10
react-snippets, v0.2.0
redux-snippets, v0.2.1
Sass-Syntax-Highlight, v0.1.1
save-session, v0.15.7
set-syntax, v0.3.0
source-preview-babel, v0.1.1
source-preview-react, v0.2.0
Sublime-Style-Column-Selection, v1.3.0
swackets, v0.5.3
# Dev
No dev packages
eg.
var x = {
"foo": "bar",
"lorem": "ipsum"
"fizz": "bin"
};
x.par = "course";
Trying to run FixMyJS on the above produces:
var x = {
"foo": "bar",
"lorem": "ipsum"
"fizz";: "bin"
};
x.par = "course";
Atom Version: 0.196.0
System: Mac OS X 10.10.2
Thrown From: fixmyjs package, v1.3.2
Uncaught Error: Cannot find module 'fixmyjs'
At module.js:330
Error: Cannot find module 'fixmyjs'
at Module._resolveFilename (module.js:328:15)
at Function.Module._resolveFilename (/Applications/Atom.app/Contents/Resources/app.asar/src/module-cache.js:383:52)
at Function.Module._load (module.js:270:25)
at Module.require (module.js:357:17)
at require (module.js:376:17)
at Object.<anonymous> (/Users/benhalverson/.atom/packages/fixmyjs/index.js:2:15)
at Module._compile (module.js:452:26)
at Object.loadFile [as .js] (/Applications/Atom.app/Contents/Resources/app.asar/src/babel.js:162:21)
at Module.load (module.js:347:32)
at Function.Module._load (module.js:302:12)
at Module.require (module.js:357:17)
at require (module.js:376:17)
at Package.module.exports.Package.requireMainModule (/Applications/Atom.app/Contents/Resources/app.asar/src/package.js:691:34)
at Package.module.exports.Package.activateConfig (/Applications/Atom.app/Contents/Resources/app.asar/src/package.js:239:12)
at PackageDetailView.module.exports.PackageDetailView.activate (/Applications/Atom.app/Contents/Resources/app.asar/node_modules/settings-view/lib/package-detail-view.js:163:26)
at PackageDetailView.module.exports.PackageDetailView.updateInstalledState (/Applications/Atom.app/Contents/Resources/app.asar/node_modules/settings-view/lib/package-detail-view.js:201:12)
at /Applications/Atom.app/Contents/Resources/app.asar/node_modules/settings-view/lib/package-detail-view.js:235:24
at /Applications/Atom.app/Contents/Resources/app.asar/node_modules/emissary/lib/emitter.js:155:30
at Array.forEach (native)
at PackageManager.module.exports.Emitter.emitSlow (/Applications/Atom.app/Contents/Resources/app.asar/node_modules/emissary/lib/emitter.js:154:47)
at PackageManager.module.exports.Emitter.emit (/Applications/Atom.app/Contents/Resources/app.asar/node_modules/emissary/lib/emitter.js:107:30)
at PackageManager.module.exports.PackageManager.emitPackageEvent (/Applications/Atom.app/Contents/Resources/app.asar/node_modules/settings-view/lib/package-manager.js:414:19)
at /Applications/Atom.app/Contents/Resources/app.asar/node_modules/settings-view/lib/package-manager.js:323:26
at exit (/Applications/Atom.app/Contents/Resources/app.asar/node_modules/settings-view/lib/package-manager.js:41:16)
at triggerExitCallback (/Applications/Atom.app/Contents/Resources/app.asar/src/buffered-process.js:213:47)
at /Applications/Atom.app/Contents/Resources/app.asar/src/buffered-process.js:220:18
at Socket.<anonymous> (/Applications/Atom.app/Contents/Resources/app.asar/src/buffered-process.js:98:18)
at emitOne (events.js:82:20)
at Socket.emit (events.js:166:7)
at Pipe.close (net.js:464:12)
-6:14.3.0 core:copy (atom-text-editor.editor)
-6:11.9.0 editor:select-to-end-of-line (atom-text-editor.editor)
-6:10.6.0 pane:show-next-item (atom-text-editor.editor)
-6:09.7.0 core:move-up (atom-text-editor.editor)
11x -6:09.2.0 core:move-left (atom-text-editor.editor)
-6:07.1.0 emmet:insert-formatted-line-break-only (atom-text-editor.editor)
-6:07.1.0 editor:newline (atom-text-editor.editor)
-6:06.7.0 core:move-up (atom-text-editor.editor)
-6:06.4.0 core:paste (atom-text-editor.editor)
5x -6:04.0 pane:show-next-item (atom-text-editor.editor)
5x -6:00.1.0 pane:show-previous-item (atom-text-editor.editor)
-5:56.9.0 core:save (atom-text-editor.editor)
-5:56 pane:show-previous-item (atom-text-editor.editor)
-5:54.7.0 core:save (atom-text-editor.editor)
-5:53.2.0 core:move-down (atom-text-editor.editor)
-0:16.8.0 core:confirm (atom-text-editor.editor.mini)
{
"core": {}
}
# User
atom-jade, v0.1.0
atom-pair, v1.1.3
atom-typescript, v2.15.2
autocomplete-css, v0.6.0
autocomplete-plus, v2.8.0
autocomplete-plus-python-jedi, v0.2.3
autocomplete-ruby, v0.0.1
color-picker, v1.5.0
emmet, v2.3.7
icon-font-picker, v0.0.1
language-typescript, v0.15.0
linter, v0.12.0
linter-csslint, v0.0.11
linter-jshint, v0.1.0
linter-less, v0.3.1
npm-autocomplete, v0.1.2
travis-ci-status, v0.13.0
# Dev
No dev packages
Thanks very much for this package. Because I'm lazy, I'd really like a keyboard shortcut, instead of having to use the Command Palette to type 'FixMyJS'.
Have tried installing via apm:
apm install fixmyjs
If I go to manage packages I can see it is enabled, however I have not managed to run it on any file.
I tried the Command Palette as mentioned in the docs, but it doesn't seem to appear as an option if I type fix
. Any suggestions? Should I be able to execute it via Keyboard shortcut or Context menu?
Thanks ;)
Although this used to work for me (and be awesome), it has stopped working recently. I tried uninstalling it and reinstalling it, but no dice. I globally installed fixmyjs via npm, and although I can not run it on the command line, I still can't use the Atom version. I'm not sure if something else I installed messed it up, or what.
Failed to activate package named 'fixmyjs' Error: Cannot find module 'fixmyjs'
at Module._resolveFilename (module.js:344:15)
at Function.Module._resolveFilename (/Applications/Atom.app/Contents/Resources/app/src/module-cache.js:383:52)
at Function.Module._load (module.js:286:25)
at Module.require (module.js:373:17)
at require (module.js:392:17)
at Object.<anonymous> (/Users/gears/.atom/packages/fixmyjs/index.js:2:15)
at Module._compile (module.js:468:26)
at Object.Module._extensions..js (module.js:486:10)
at Module.load (/Applications/Atom.app/Contents/Resources/app/node_modules/coffee-script/lib/coffee-script/register.js:45:36)
at Function.Module._load (module.js:318:12)
at Module.require (module.js:373:17)
at require (module.js:392:17)
at Package.module.exports.Package.requireMainModule (/Applications/Atom.app/Contents/Resources/app/src/package.js:623:34)
at Package.module.exports.Package.activateConfig (/Applications/Atom.app/Contents/Resources/app/src/package.js:250:12)
at Package.module.exports.Package.activateNow (/Applications/Atom.app/Contents/Resources/app/src/package.js:232:14)
at /Applications/Atom.app/Contents/Resources/app/src/package.js:682:29
at Emitter.module.exports.Emitter.emit (/Applications/Atom.app/Contents/Resources/app/node_modules/event-kit/lib/emitter.js:82:11)
at CommandRegistry.module.exports.CommandRegistry.handleCommandEvent (/Applications/Atom.app/Contents/Resources/app/src/command-registry.js:224:20)
at /Applications/Atom.app/Contents/Resources/app/src/command-registry.js:3:61
at CommandPaletteView.module.exports.CommandPaletteView.confirmed (/Applications/Atom.app/Contents/Resources/app/node_modules/command-palette/lib/command-palette-view.js:120:32)
at CommandPaletteView.module.exports.SelectListView.confirmSelection (/Applications/Atom.app/Contents/Resources/app/node_modules/go-to-line/node_modules/atom-space-pen-views/lib/select-list-view.js:336:21)
at space-pen-li.<anonymous> (/Applications/Atom.app/Contents/Resources/app/node_modules/go-to-line/node_modules/atom-space-pen-views/lib/select-list-view.js:140:19)
at HTMLOListElement.jQuery.event.dispatch (/Applications/Atom.app/Contents/Resources/app/node_modules/archive-view/node_modules/atom-space-pen-views/node_modules/space-pen/vendor/jquery.js:4676:9)
at HTMLOListElement.elemData.handle (/Applications/Atom.app/Contents/Resources/app/node_modules/archive-view/node_modules/atom-space-pen-views/node_modules/space-pen/vendor/jquery.js:4360:46)
Such a nifty idea! Any chance for an Atom package? I suppose the package might like "find" in that you could step thru the jshint issues, but then I could get my config file to be what I really care about.
Hi,
I just tried your package and the result is sobering.
I've installed "linter-jshint" and "fixmyjs" and produced an error inside a JS file.
I chose "FixMyJS" from the command options and... nothing happened.
When I reenter "FixMyJS" I don't get a matching option, so I'm not able to "re-fix" ANY file.
An error occurs in the console:
Failed to activate package named 'fixmyjs' Error: Cannot find module 'fixmyjs'
at Module._resolveFilename (module.js:351:15)
at Function.Module._resolveFilename (/Applications/Atom.app/Contents/Resources/app/src/module-cache.js:383:52)
at Function.Module._load (module.js:293:25)
at Module.require (module.js:380:17)
at require (module.js:399:17)
at Object.<anonymous> (/Users/cstuff/.atom/packages/fixmyjs/index.js:2:15)
at Module._compile (module.js:475:26)
at Object.loadFile [as .js] (/Applications/Atom.app/Contents/Resources/app/src/6to5.js:138:21)
at Module.load (module.js:370:32)
at Function.Module._load (module.js:325:12)
at Module.require (module.js:380:17)
at require (module.js:399:17)
at Package.module.exports.Package.requireMainModule (/Applications/Atom.app/Contents/Resources/app/src/package.js:651:34)
at Package.module.exports.Package.activateConfig (/Applications/Atom.app/Contents/Resources/app/src/package.js:251:12)
at Package.module.exports.Package.activateNow (/Applications/Atom.app/Contents/Resources/app/src/package.js:232:14)
at /Applications/Atom.app/Contents/Resources/app/src/package.js:710:29
at Emitter.module.exports.Emitter.emit (/Applications/Atom.app/Contents/Resources/app/node_modules/event-kit/lib/emitter.js:82:11)
at CommandRegistry.module.exports.CommandRegistry.handleCommandEvent (/Applications/Atom.app/Contents/Resources/app/src/command-registry.js:224:20)
at /Applications/Atom.app/Contents/Resources/app/src/command-registry.js:3:61
at CommandPaletteView.module.exports.CommandPaletteView.confirmed (/Applications/Atom.app/Contents/Resources/app/node_modules/command-palette/lib/command-palette-view.js:120:32)
at CommandPaletteView.module.exports.SelectListView.confirmSelection (/Applications/Atom.app/Contents/Resources/app/node_modules/atom-space-pen-views/lib/select-list-view.js:338:21)
at space-pen-div.atom.commands.add.core:confirm (/Applications/Atom.app/Contents/Resources/app/node_modules/atom-space-pen-views/lib/select-list-view.js:109:19)
at CommandRegistry.module.exports.CommandRegistry.handleCommandEvent (/Applications/Atom.app/Contents/Resources/app/src/command-registry.js:243:29)
at /Applications/Atom.app/Contents/Resources/app/src/command-registry.js:3:61
at KeymapManager.module.exports.KeymapManager.dispatchCommandEvent (/Applications/Atom.app/Contents/Resources/app/node_modules/atom-keymap/lib/keymap-manager.js:558:16)
at KeymapManager.module.exports.KeymapManager.handleKeyboardEvent (/Applications/Atom.app/Contents/Resources/app/node_modules/atom-keymap/lib/keymap-manager.js:396:22)
at HTMLDocument.module.exports.WindowEventHandler.onKeydown (/Applications/Atom.app/Contents/Resources/app/src/window-event-handler.js:176:20)
Any hints?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.