Ruby on Rails | Screencasts | Download | Documentation | Weblog | Community | Source

Ticket #9546 (closed defect: fixed)

Opened 1 year ago

Last modified 7 months ago

[PATCH] bzr branch specifies -r switch but does not specify revision

Reported by: ceefour Assigned to: minam
Priority: normal Milestone: 2.x
Component: Capistrano Version: edge
Severity: normal Keywords: patch
Cc: jamis, michiels

Description

In the default capify, it does not specify :revision. It should default to checking out the latest (last:1) revision but it doesn't.

The resulting checkout command is:

      bzr branch -r  sftp://.............

which errors, because the revision is not specified. It would be better to leave the '-r' switch altogether if a revision is not specified.

Attachments

bzr.rb-fix-head-revision-query.patch (0.8 kB) - added by michiels on 10/19/07 12:29:17.
Patch to not set -r flag if :revision is set to :head or nil

Change History

09/30/07 14:57:43 changed by minam

I'm afraid that I am not a bzr guru, so if anyone wants this change made, they'll need to submit a patch. I'll leave this ticket open so anyone so desiring may attach the patch to it.

10/19/07 12:22:30 changed by michiels

I have looked into this today. I'm not quite familiar with how Capistrano deployment SCM recipies should work. But this patch should fix this bug.

However, what should the query_revision() method return? Should it return the latest revision, or should it return the revision the user has configured in it's deploy.rb file?

10/19/07 12:29:17 changed by michiels

  • attachment bzr.rb-fix-head-revision-query.patch added.

Patch to not set -r flag if :revision is set to :head or nil

10/19/07 12:29:56 changed by michiels

Better yet. This new patch ommits the -r flag if :revision is set to :head or not specified in deploy.rb.

10/19/07 12:48:20 changed by michiels

  • cc changed from jamis to jamis, michiels.
  • summary changed from bzr branch specifies -r switch but does not specify revision to [PATCH] bzr branch specifies -r switch but does not specify revision.

10/19/07 12:49:11 changed by ceefour

  • keywords set to patch.

Thank you very much michiels.

That'd be so great.

10/19/07 12:50:46 changed by ceefour

Any chance we can also fix #9547 as well?

It's actually pretty "trivial", simply replacing the command line "bzr branch" with "bzr checkout --lightweight", everything else stays the same. But I'm not sure where to start looking.

01/30/08 05:46:11 changed by minam

  • status changed from new to closed.
  • resolution set to fixed.

(In [8752]) make sure bzr SCM works when revision is unspecified, or is head (closes #9546)