Skip to content

Conversation

vincent-psarga
Copy link
Contributor

@vincent-psarga vincent-psarga commented Sep 27, 2019

Summary

gem cucumber-messages can not be installed from git as the file lib/cucumber/messages_pb.rb is not checked-out.

This ensures that the file is created.

Still TO-DO:

  • Ensure the file is not regenerated (when installing via Bundler for example, the released gem contain the missing file)
  • Add a target in the makefile to ensure this is tested (basically running: rake build && gem install pkg/cucumber-messages-*.gem and ensure it does not fail)

Details

Motivation and Context

This should allow us to reference the gem from the GIT repo when working on cucumber-rubyor cucumber-ruby-core.

How Has This Been Tested?

Badly for now, see TODO section.

Types of changes

Not applicable.

  • Bug fix (non-breaking change which fixes an issue).
  • New feature (non-breaking change which adds functionality).
  • Breaking change (fix or feature that would cause existing functionality to not work as expected).

Checklist:

  • The change has been ported to Java.
  • The change has been ported to Ruby.
  • The change has been ported to JavaScript.
  • The change has been ported to Go.
  • The change has been ported to .NET.
  • I've added tests for my code.
  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.

@vincent-psarga
Copy link
Contributor Author

Is this require still needed? It stands for "make makefile", but we're creating it manually...

From what I've need, yes, it will provide the find_executablemethod.

@vincent-psarga vincent-psarga marked this pull request as ready for review September 30, 2019 08:35
This should avoid trouble when installing, for example if bash is not available.
The makefile should only be used during development, for released version the file
is there and nothing should be done.
@vincent-psarga
Copy link
Contributor Author

The idea was to avoid having to load the shell (for example for people using the gem on Windows). But maybe a simpler solution would be to use:

cd ../.. && protoc -I. --ruby_out lib/cucumber messages.proto && cd -

instead of:

pushd ../.. && protoc -I. --ruby_out lib/cucumber messages.proto && popd

This way we don't need bash at all. That said I'm not sure this would work at all when installing the gem on windows.
I'll have to try that out.

@stale
Copy link

stale bot commented Nov 30, 2019

This issue has been automatically marked as stale because it has not had recent activity. It will be closed in a week if no further activity occurs.

@stale stale bot added the ⌛ stale Will soon be closed by stalebot unless there is activity label Nov 30, 2019
@aslakhellesoy
Copy link
Contributor

This is related to #813

@stale stale bot removed the ⌛ stale Will soon be closed by stalebot unless there is activity label Nov 30, 2019
@aslakhellesoy
Copy link
Contributor

Will this approach work if the user doesn't have make installed? (Thinking about Windows users)

@stale
Copy link

stale bot commented Apr 28, 2020

This issue has been automatically marked as stale because it has not had recent activity. It will be closed in a week if no further activity occurs.

@stale stale bot added the ⌛ stale Will soon be closed by stalebot unless there is activity label Apr 28, 2020
@stale
Copy link

stale bot commented May 6, 2020

This issue has been automatically closed because of inactivity. You can support the Cucumber core team on opencollective.

@stale stale bot closed this May 6, 2020
@mattwynne mattwynne deleted the generate-messagepb-on-gem-install branch April 1, 2022 14:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
⌛ stale Will soon be closed by stalebot unless there is activity language: ruby library: cucumber-messages
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants