Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Could not open input file: ./vendor/bin/protobuf #9

Open
xiaochuanyu opened this issue Mar 2, 2017 · 2 comments
Open

Could not open input file: ./vendor/bin/protobuf #9

xiaochuanyu opened this issue Mar 2, 2017 · 2 comments

Comments

@xiaochuanyu
Copy link

I'm trying to generate php code for a particular .proto file following instructions from the README.
I did the following in an empty directory with addressbook.proto :

brew install php composer protoc
composer require "protobuf-php/protobuf-plugin
php ./vendor/bin/protobuf --include-descriptors -i . -o ./src/ ./addressbook.proto

I get error saying:

Could not open input file: ./vendor/bin/protobuf

In vendor/ there is only the following folders:

autoload.php  composer/  protobuf-php/

What am I missing?

Info:

$ protoc --version
libprotoc 3.2.0
$ composer --version
Composer version 1.3.2 2017-01-27 18:23:41
$ php --version
PHP 7.1.2 (cli) (built: Feb 17 2017 10:51:21) ( NTS )
Copyright (c) 1997-2017 The PHP Group
Zend Engine v3.1.0, Copyright (c) 1998-2017 Zend Technologies
@jbq
Copy link

jbq commented Jun 19, 2017

Same here, I'm missing the vendor/bin directory. I followed the documentation but something is wrong.

@jbq
Copy link

jbq commented Jun 19, 2017

In fact this is a documentation problem in https://github.com/protobuf-php/protobuf

There are two different projects: protobuf, and protobuf-plugin. Both must be installed to follow the instructions in the README.

See https://github.com/protobuf-php/protobuf-plugin#composer-install for instructions

@xiaochuanyu xiaochuanyu changed the title Possible setup problem Could not open input file: ./vendor/bin/protobuf Jun 19, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants