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

Add WebStorm option for bundle updates #24

Closed
wants to merge 2 commits into from

Conversation

bendrucker
Copy link
Collaborator

Moving discussion from #23. Would like to hear what JetBrains has to say about this before even thinking about merging.

https://youtrack.jetbrains.com/issue/WEB-12496

@Odalrick you can change your package.json for now to just grab from git at the head of the branch. Let me know if it works.

{
  "devDependencies": {
    "karma-bro": "bendrucker/karmo-bro#webstorm"
  }
}

@bendrucker bendrucker self-assigned this Oct 1, 2014
@Odalrick
Copy link

Odalrick commented Oct 1, 2014

I pulled the package and got it to work as intended; the code gets rebuilt regardless. However, the plugin still won't behave and continues serving stale code.

@bendrucker
Copy link
Collaborator Author

Well if that's the case then there's no solution to this. The plugin isn't serving any code — that's up to Karma. If the bundle file is written out and future manual runs don't pick up the changes, there's nothing we can do. If you can confirm that's the case I'll go ahead and close this out.

@Odalrick
Copy link

Odalrick commented Oct 2, 2014

I think I can confirm that the bundle is being rebuilt.

I introduced an intentional syntaxerror and changed the test to failing and back. No change in PhpStorm.

DEBUG [plugin]: Loading karma-* from /home/ulrik/Projects/karma-bro/example/node_modules
DEBUG [plugin]: Loading plugin /home/ulrik/Projects/karma-bro/example/node_modules/karma-bro.
DEBUG [plugin]: Loading plugin /home/ulrik/Projects/karma-bro/example/node_modules/karma-chrome-launcher.
DEBUG [plugin]: Loading plugin /home/ulrik/Projects/karma-bro/example/node_modules/karma-jasmine.
DEBUG [plugin]: Loading plugin /home/ulrik/Projects/karma-bro/example/node_modules/karma-phantomjs-launcher.
DEBUG [plugin]: Loading plugin /home/ulrik/.WebIde80/config/plugins/js-karma/js_reporter/karma-intellij/lib/intellijPlugin.js.
DEBUG [framework.browserify]: created browserify bundle: /tmp/80b6bd75d1c5ac7a5dbeaab6d79c412cce083100.browserify
INFO [framework.browserify]: registering rebuild (autoWatch=true)
DEBUG [framework.browserify]: add bundle to config.files at position 3
WARN [karma]: Port 9876 in use
INFO [karma]: Karma v0.12.24 server started at http://localhost:9877/
INFO [launcher]: Starting browser PhantomJS
DEBUG [temp-dir]: Creating temp dir at /tmp/karma-56372454
DEBUG [launcher]: /home/ulrik/Projects/karma-bro/example/node_modules/karma-phantomjs-launcher/node_modules/phantomjs/lib/phantom/bin/phantomjs /tmp/karma-56372454/capture.js
DEBUG [framework.browserify]: building bundle
DEBUG [framework.browserify]: adding test/bSpec.js to bundle
DEBUG [framework.browserify]: adding test/externalSpec.js to bundle
DEBUG [framework.browserify]: adding test/failingSpec.js to bundle
DEBUG [web-server]: serving: /home/ulrik/Projects/karma-bro/example/node_modules/karma/static/client.html
DEBUG [framework.browserify]: bundling
DEBUG [web-server]: serving: /home/ulrik/Projects/karma-bro/example/node_modules/karma/static/karma.js
DEBUG [web-server]: upgrade /socket.io/1/websocket/xnE-ReNFyqDurVWBnZNS
DEBUG [karma]: A browser has connected on socket xnE-ReNFyqDurVWBnZNS
INFO [PhantomJS 1.9.7 (Linux)]: Connected on socket xnE-ReNFyqDurVWBnZNS with id 56372454
DEBUG [launcher]: PhantomJS (id 56372454) captured in 0.754 secs
INFO [framework.browserify]: 5897 bytes written (0.17 seconds)
INFO [framework.browserify]: bundle built
DEBUG [watcher]: Resolved files:
    /home/ulrik/Projects/karma-bro/example/node_modules/karma-jasmine/lib/jasmine.js
    /home/ulrik/Projects/karma-bro/example/node_modules/karma-jasmine/lib/adapter.js
    /home/ulrik/Projects/karma-bro/example/vendor/external.js
    /tmp/80b6bd75d1c5ac7a5dbeaab6d79c412cce083100.browserify
    /home/ulrik/Projects/karma-bro/example/test/bSpec.js
    /home/ulrik/Projects/karma-bro/example/test/externalSpec.js
    /home/ulrik/Projects/karma-bro/example/test/failingSpec.js
DEBUG [karma]: Execution (fired by runner)
DEBUG [karma]: Setting client.args to  undefined
DEBUG [karma]: All browsers are ready, executing
DEBUG [web-server]: serving: /home/ulrik/Projects/karma-bro/example/node_modules/karma/static/context.html
DEBUG [web-server]: serving (cached): /home/ulrik/Projects/karma-bro/example/node_modules/karma-jasmine/lib/jasmine.js
DEBUG [web-server]: serving (cached): /home/ulrik/Projects/karma-bro/example/test/failingSpec.js
DEBUG [web-server]: serving (cached): /home/ulrik/Projects/karma-bro/example/node_modules/karma-jasmine/lib/adapter.js
DEBUG [web-server]: serving (cached): /home/ulrik/Projects/karma-bro/example/vendor/external.js
DEBUG [web-server]: serving (cached): /tmp/80b6bd75d1c5ac7a5dbeaab6d79c412cce083100.browserify
DEBUG [web-server]: serving (cached): /home/ulrik/Projects/karma-bro/example/test/bSpec.js
DEBUG [web-server]: serving (cached): /home/ulrik/Projects/karma-bro/example/test/externalSpec.js
DEBUG [framework.browserify]: files changed
DEBUG [framework.browserify]: bundling
ERROR [framework.browserify]: bundle error
ERROR [framework.browserify]: Error: Line 11: Unexpected identifier while parsing file: /home/ulrik/Projects/karma-bro/example/test/failingSpec.js
DEBUG [framework.browserify]: files changed
DEBUG [framework.browserify]: bundling
INFO [framework.browserify]: 5895 bytes written (0.03 seconds)
INFO [framework.browserify]: bundle updated
INFO [watcher]: Changed file "/home/ulrik/Projects/karma-bro/example/test/failingSpec.js".
DEBUG [karma]: Execution (fired by runner)
DEBUG [karma]: Setting client.args to  undefined
DEBUG [karma]: All browsers are ready, executing
DEBUG [web-server]: serving (cached): /home/ulrik/Projects/karma-bro/example/node_modules/karma/static/context.html
DEBUG [web-server]: serving (cached): /home/ulrik/Projects/karma-bro/example/test/failingSpec.js
DEBUG [framework.browserify]: bundling
INFO [framework.browserify]: 5895 bytes written (0.01 seconds)
INFO [framework.browserify]: bundle updated
DEBUG [framework.browserify]: files changed
DEBUG [framework.browserify]: bundling
INFO [framework.browserify]: 5897 bytes written (0.01 seconds)
INFO [framework.browserify]: bundle updated
INFO [watcher]: Changed file "/home/ulrik/Projects/karma-bro/example/test/failingSpec.js".
DEBUG [karma]: Execution (fired by runner)
DEBUG [karma]: Setting client.args to  undefined
DEBUG [karma]: All browsers are ready, executing
DEBUG [web-server]: serving (cached): /home/ulrik/Projects/karma-bro/example/node_modules/karma/static/context.html
DEBUG [web-server]: serving (cached): /home/ulrik/Projects/karma-bro/example/test/failingSpec.js
DEBUG [framework.browserify]: bundling
INFO [framework.browserify]: 5897 bytes written (0.01 seconds)
INFO [framework.browserify]: bundle updated

@bendrucker
Copy link
Collaborator Author

Alrighty then. Will close this since it's non-standard behavior on their part and we have no way to work around it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants