Link to home
Start Free TrialLog in
Avatar of Bruce Gust
Bruce GustFlag for United States of America

asked on

php composer doesn't work. composer does. Why?

I'm working through a tutorial that has me entering in a command into the Git Bash interface that looks like this:

php composer.phar require coolcsn/csn-user:dev-master

When I do that, I get an error message that says "Could not open input file: composer.phar"

I can do what needs to be done by entering the same command like this:

composer
composer.phar require coolcsn/csn-user:dev-master

But I want to understand why the first command doesn't work and, if the fact that it doesn't work, represent something I need to change on my system.

What do you think?
ASKER CERTIFIED SOLUTION
Avatar of Loganathan Natarajan
Loganathan Natarajan
Flag of India image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of Bruce Gust

ASKER

Hey, Logonathan!

I have installed composer and I am using Windows. When I run "composer" on Git Bash, I get a screen that outlines all of the specifics relative to that application. So, I'm confident I do have the app, I just can't seem to fire anything pertaining to composer when I've got "php" prefacing the command.

Make sense?
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
hielo, when I execute that command I don't get the error,just a a collection of text that has my PHP version number etc.
This is no an answer, just a recommendation.  Get off Windows.  Go get a Mac.  You can thank me later.  I've been down this path before, and I found Windows to be the biggest impediment I could imagine.  Like you I had become comfortable with Windows, so I didn't know what I was missing.  I promise that in a few months of working with a Mac and using the command line, you will never want to go back to Windows for anything.  Plus, most of our colleagues who have advanced beyond the "beginner" level of web development are using Macs, so it will be easier to get help when you speak the same language!
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
I got it figured out, fellas. Thanks for your input.