How to create a .txt-like file with a gazebo?

I started working with bower and it seems really useful. I come from the python background, so I'm used to having virtualenv and requirements.txt .

Since I prefer not to store all my dependencies in the original control, if I can help, I was wondering how to create a file like requirements.txt using bower ?

+4
source share
1 answer

After I joked a bit, I have a solution.

bower uses a file called bower.json (formerly component.json ), which is similar to Gemfile or requirements.txt .

It can be created manually and will look something like this:

 { "name": "<app name, defaults co current folder name>", "version": "0.0.0", "dependencies": { "backbone": "~0.9.10", "underscore": "~1.4.3" } } 

However, an element that I was missing should have included the --save flag when installing packages in bower :

 bower install <package_name> --save 

Unfortunately, I do not believe that there is a way to set this default behavior using a .bowerrc file.

As an added tidbit, once you have the bower.json file, installing dependencies will be as easy as running bower install .

+9
source

All Articles