This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
Support for Bower could be very useful for NetBeans. Petře, could you please create a Bugzilla component for it and assign there this task? However, I am not sure who will implement it (and should be its owner). Thanks.
Bower is javascript libraries manager, right? So we should extend a JavaScript Files panel, which is shown in wizard and project properties. For instance we can create a new tab in it: +--------+-------+ | CDNJS | Bower | +---------------------------------------------------------------------+ | Choose a library | | Available: [ ] Selected: | | +-------------------------------+ +-------------------------------+ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | +-------------------------------+ +-------------------------------+ | | Libraries folder: bower_components | ----------------------------------------------------------------------+ Does it make sense? Anything else needs to be done?
(In reply to Jan Becicka from comment #1) > Does it make sense? I don't know Bower but I guess this could be fine. > Anything else needs to be done? IMHO a support for its command line tool so one can easily invoke any of Bower's actions (via context menu on project perhaps?). Thanks.
(In reply to Tomas Mysik from comment #2) > (via context menu on project perhaps?) It could be nice to have it on bower.json file and make this file "important" (show it under Important files), just like Gruntfile.js
> IMHO a support for its command line tool so one can easily invoke > any of Bower's actions Especially some actions are more important than others, e.g. if I import an existing project which has libraries managed by Bower, I will want to run "bower install" as the first step - there could be an action for that. And there could be a project-level warning on projects where 'bower install' was not done yet. > Anything else needs to be done? As for the 'bower init' command, this could be exposed in the UI as: a/ The Bower panel under JavaScript Files could have a checkbox "Use Bower to manage JavaScript libraries", which would turn Bower on/off b/ New HTML5 project wizard could have a similar checkbox
> IMHO a support for its command line tool so one can easily invoke any of > Bower's actions (via context menu on project perhaps?). Bower have following commands: cache Manage bower cache help Display help information about Bower home Opens a package homepage into your favorite browser info Info of a particular package init Interactively create a bower.json file install Install a package locally link Symlink a package folder list List local packages lookup Look up a package URL by name prune Removes local extraneous packages register Register a package search Search for a package by name update Update a local package uninstall Remove a local package I think, that we can ignore cache, help, home and link. Init command should be "implemented" as New bower.json wizard. Info, install, list, lookup, prune, search, update and uninstall is what can be done in the customizer. And register command - will be simply unsupported.
> It could be nice to have it on bower.json file and make this file > "important" (show it under Important files), just like Gruntfile.js sure
(In reply to Petr Jiricka from comment #4) > > IMHO a support for its command line tool so one can easily invoke > > any of Bower's actions > > Especially some actions are more important than others, e.g. if I import an > existing project which has libraries managed by Bower, I will want to run > "bower install" as the first step - there could be an action for that. And > there could be a project-level warning on projects where 'bower install' was > not done yet. Agreed. > > Anything else needs to be done? > > As for the 'bower init' command, this could be exposed in the UI as: > a/ The Bower panel under JavaScript Files could have a checkbox "Use Bower > to manage JavaScript libraries", which would turn Bower on/off > b/ New HTML5 project wizard could have a similar checkbox I'm not sure, what should "turn off bower" suppose to do. Now we manage javascript libraries ourselves and we use CDNJS for that. If we now want to support bower, does it mean, that user can use our manager and bower together? Or user is required to choose just one manager and then use it and we will not support mixing?
You are right that turning off bower does not make much sense. > If we now want to support bower, does it mean, that user can > use our manager and bower together? Probably not, I guess it's one or the other, but not both at the same time.
(In reply to Petr Jiricka from comment #8) > You are right that turning off bower does not make much sense. > > > If we now want to support bower, does it mean, that user can > > use our manager and bower together? > > Probably not, I guess it's one or the other, but not both at the same time. So once user choose to use bower, CDNJS approach should not be available?
Basic support for bower implemented in 8.0.1: + bower.json and .bowerrc nodes under Important Files in Projects view + "bower install" action on HTML 5 Project + Project problem if HTML 5 Project contains bower.json, but bower modules not installed Prototype of Bower libraries selection panel is available at http://deadlock.netbeans.org/job/bower_support/ will not be integrated in 8.0.1 since it requires deeper API changes not suitable for dot dot release.
Hello, I'm new in Bower too and a NetBeans enthusiastic!!! Use since I don't remember, lot of years ago. Just a point, I don't know really if it helps. To use bower (!!!) in NetBeans I do: bower init // I use templates from other projects, so for me is not really necessary, but it's cool to another people bower search "anything" // I need to find some components to install the right bower install "anything" --save // The "--save" is necessary to add the dependency to bower.json bower update // Install, update, reinstall dependencies To remove any dependency I do it by hand, a dependency install lot of other dependencies so I just remove bower folder and update/reinstall again. Another thing: A people can use a private repository adding the dependency "name" and "git path". Examples: { "name": "Olho no Campo", "version": "0.0.1", "authors": [ "Francisco Ernesto Teixeira <fco.ernesto@gmail.com>" ], "description": "Cliente do Servidor Olho no Campo", "license": "MIT", "homepage": "https://s.olhonocampo.com.br", "private": true, "ignore": [ "**/.*", "node_modules", "bower_components", "test", "tests" ], "dependencies": { "angular": "~1.2.21", "angular-cookies": "~1.2.21", "angular-loader": "~1.2.21", "angular-resource": "~1.2.21", "angular-route": "~1.2.21", "angular-i18n": "~1.2.21", "angular-http-auth": "~1.2.1", "requirejs": "~2.1.14", "leaflet": "~0.7.3", "fullcalendar": "~2.0.2", "open-sans-fontface": "~1.1.0", "components-font-awesome": "~4.1.0", "ace": "https://netinho@bitbucket.org/netinho/wb0b30dgr.git" } } Another example: { "name": "Caixa Crescer", "version": "0.0.1", "authors": [ "Francisco Ernesto Teixeira <fco.ernesto@gmail.com>" ], "description": "Força de Vendas", "license": "MIT", "homepage": "http://www.caixacrescer.com.br", "private": true, "ignore": [ "**/.*", "node_modules", "bower_components", "test", "tests" ], "dependencies": { "jquery": "~2.1.1", "requirejs": ">= 2.1.*", "font-awesome": "~4.1.0", "jquery-meiomask": "~1.1.14", "leaflet": "~0.7.3", "ionic": "driftyco/ionic-bower#master", "raty-fa": "https://github.com/Jacob87/raty-fa.git", "Leaflet.awesome-markers": "~2.0.2" } }
Reassigning to Honza, he is now the owner of this area. Thanks.
If i'm create project with existing files not in my app folder, but in another folder where i'm place all my projects, then NetBeans doesn't found Important files like bower.js, package.js and not display it.
(In reply to seyfer from comment #13) > If i'm create project with existing files not in my app folder, but in > another folder where i'm place all my projects, then NetBeans doesn't found > Important files like bower.js, package.js and not display it. You need to place these files directly in the project directory.
There is Bower support (including library management) implemented in NetBeans development builds => I am closing this issue as fixed. If you miss some specific functionality, please, fill a separate enhancement. Thank you in advance.