Reputation: 7552
I am trying to do this in my .bowerrc
file
"directory": "~/bower_components"
which I want is to resolve to the current users home folder:
/home/me/bower_components
but currently it is being resolved to:
[currentDirectory]/~/bower_components
Is their a way to get it to point to an absolute path?
Upvotes: 3
Views: 985
Reputation: 76
The field you need to set in the .bowerrc
is cwd
to give your installs an absolute root.
For example, the .bowerrc
file:
{
'cwd': '/var/www/libraries',
'directory': 'vendor'
}
will result in all your bower update/install
commands to place packages in /var/www/libraries/vendor
.
I experimented with using ~
for the cwd
parameter, and Bower didn't understand it.
The documentation for what Bower expects to find in .bowerrc
is in this Google doc.
Upvotes: 6