Currently drush make doesn't modify .info files when cloning from Git if repository isn't hosted on Drupal.org.

For the purposes of custom continuous integration scenarios it's necessary to be able to force a modification of .info files when cloning from Git even if repository isn't hosted on Drupal.org.

CommentFileSizeAuthor
#2 drush-make-force-gitinfofile-no-gitprojectinfo-2005070-2.patch2.39 KBAnonymous (not verified)
#1 drush-make-force-gitinfofile-2005070-1.patch1.59 KBAnonymous (not verified)

Comments

Anonymous’s picture

Here is the patch against latest 8.x-6.x-dev (which also works perfectly for 7.x-5.x-dev) to resolve this feature request.

Please review and commit. Thank you!

Anonymous’s picture

There are some custom continuous integration scenarios where injection of project property into .info file during Git cloning is not necessary (because profile/module/theme is developed for single website and so it's not hosted at any update site and shouldn't be considered by Drupal update module). That's why I further improved my above patch to introduce --no-gitprojectinfo drush make option to skip injection of project info into .info files when cloning from Git.

Here is updated patch against latest 8.x-6.x-dev (which also works perfectly for 7.x-5.x-dev) to resolve this feature request.

Please review and commit. Thank you!

moshe weitzman’s picture

Status: Needs review » Needs work

pm-download already has --gitinfofile option. Thats what make should set to FALSE in order to achieve this. I'm not too familiar with make in order to say exactly how that gets done.

Anonymous’s picture

Status: Needs work » Needs review

For cloning from Git drush make uses its own implementation make_download_git(), so --gitinfofile option is irrelevant here (drush make implementation provides superior functionality than pm-download).

To process .info files drush make also uses its own implementation DrushMakeProject::processGitInfoFiles(), which in turn calls drush_pm_inject_info_file_metadata() to actually inject version info into .info files. That's why to implement --no-gitprojectinfo drush make option I also had to add corresponding check into drush_pm_inject_info_file_metadata().

Having said above, I still consider my patch appropriate and set status back to needs review.

Please review and commit. Thank you!

greg.1.anderson’s picture

Status: Needs review » Closed (won't fix)
Issue tags: +Needs migration

This issue was marked closed (won't fix) because Drush has moved to Github.

If this feature is still desired, you may copy it to our Github project. For best results, create a Pull Request that has been updated for the master branch. Post a link here to the PR, and please also change the status of this issue to closed (duplicate).

Please ask support questions on Drupal Answers.

bircher’s picture

https://github.com/drush-ops/drush/issues/187

no pull request so far though.

greg.1.anderson’s picture

Status: Closed (won't fix) » Closed (duplicate)

A pull request makes it more likely this will be noticed and acted on, that's all.

Changing status to 'duplicate' now that it has been migrated.