added sub_directory option

Consider a repository structured as follows:

```
Root/
├── client
├── docs
│   └── README.md
└── server
    └── app
    └── […]
```

You’d probably want to only deploy the `server` subdirectory, as it is the actual rails application. In this scenario setting `sub_directory` to “server” would do the trick. Leaving the setting untouched will still work and deploy from the root.


Vilea
--------------------------
Ivan Guajana, MSc ETH Computer Science
Technical Director
Technoparkstrasse 1, 8005 Zurich, Switzerland
ivan.guajana@vilea.ch, http://www.vilea.ch
Phone +41 (0)44 586 22 96

> On 19-dic-2014, at 21:17, Daniel Leong <notifications@github.com> wrote:
> 
> In lib/capistrano/tasks/gitcopy.rake:
> 
> > @@ -6,7 +6,7 @@ namespace :gitcopy do
> >    file archive_name do |file| 
> >      system "git ls-remote #{fetch(:repo_url)} | grep #{fetch(:branch)}"
> >      if $?.exitstatus == 0
> > -      system "git archive --remote #{fetch(:repo_url)} --format=tar #{fetch(:branch)} | gzip > #{ archive_name }"
> > +      system "git archive --remote #{fetch(:repo_url)} --format=tar #{fetch(:branch)}:#{fetch(:sub_directory)} | gzip > #{ archive_name }"
> 
> Sorry, but could you explain a scenario when this would occur?
> 
> I'm pretty noob and have not seen such situations occurring.
> 
> —
> Reply to this email directly or view it on GitHub.
>