bash - cd in pipe after getting folder path -


when run command, folder of local gem installed:

e.g.

bundle show gem  /users/user/projects/project/vendor/cache/gem-856752cd48f0 

can use pipe cd folder path?

e.g.

bundle show gem | ??? 

what replace question marks with?

you can use cd output of command:

cd "$(bundle show gem)" 

if want pipe, make use of xargs this:

bundle show gem | xargs cd 

Comments

Popular posts from this blog

python - matpltolib navigation toolbar edit curves and parameters line color automatically changes issue -

node.js - Nodejs javascript implementation of PBEWithMD5AndTripleDES/CBC/PKCS5Padding -