You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@subversion.apache.org by Jari Aalto <ja...@cante.net> on 2013/06/16 09:31:27 UTC

BUG TRACKER: [svn export] please add options --exclude ITEM

Hi,

I'd like to open the following feature request in the
<http://subversion.tigris.org/issue-tracker.html>. Please advice.

DESCRITION

Please add to "svn export" option:

    -x, --exclude ITEM

which could be given multiple times. The option would exclude files and
paths relative to the current repository root from the final output.

The pattern could be:

    - String to match path
    - OR shell-like pattern to match path (allowing "*" and "[]")
    - OR regular expression (the best)

MOTIVATION

Many times the repository contains private development files that should
not be included in PACKAGE-VERSION.tar.gz

An example:

    ROOT
    | program.sh
    |
    | test.data
    | output.log
    |
    +- scripts/
       my-own.sh
       not-publishable.sh

    $ svn export -x ./test.data -x *.log -x scripts ../package-1.0+svn10.tar.gz

Would make an archive content:

    ROOT
    |
    + - program.sh

This is a snapshop from VCS tree. Different from if there would have been a
Makefile to do official release in target "make dist".

Jari


Re: BUG TRACKER: [svn export] please add options --exclude ITEM

Posted by Daniel Shahaf <da...@elego.de>.
James Hanley wrote on Mon, Jun 17, 2013 at 13:32:11 -0400:
> I think this is a feature that could also benefit svn checkin, as many
> times I'm working on multiple disjoint functions

See 'svn changelist'?

> or there is a common config file that is needed for checkout and may
> require some tweaks (such as running on simulated hardware, etc) but
> usually shouldn't be checked in.
> 

http://subversion.apache.org/faq.html#ignore-commit

> I would use this feature in both spots of checkin and export if available.
> 
> 
> On Sun, Jun 16, 2013 at 3:31 AM, Jari Aalto <ja...@cante.net> wrote:
> >     $ svn export -x ./test.data -x *.log -x scripts ../package-1.0+svn10.tar.gz
> >
> > Would make an archive content:
> >
> >     ROOT
> >     |
> >     + - program.sh

I'll note that this is actually *two* feature requests:

1) Add a -x/--exclude flag
(I can see the reason for that, if the --excluded files are large.
Workaround that works today: use --depth and 'svn ls $URL' to fetch only
parts of the tree; may be easier with checkout than with export)

2) Add an "output to tar.gz" mode
(off-the-cuff response: why hardcode tar.gz?  why not allow zip and
tar.bz2 as well?)

Re: BUG TRACKER: [svn export] please add options --exclude ITEM

Posted by James Hanley <jh...@dgtlrift.com>.
I think this is a feature that could also benefit svn checkin, as many
times I'm working on multiple disjoint functions or there is a common
config file that is needed for checkout and may require some tweaks (such
as running on simulated hardware, etc) but usually shouldn't be checked in.

I would use this feature in both spots of checkin and export if available.


On Sun, Jun 16, 2013 at 3:31 AM, Jari Aalto <ja...@cante.net> wrote:

>
> Hi,
>
> I'd like to open the following feature request in the
> <http://subversion.tigris.org/issue-tracker.html>. Please advice.
>
> DESCRITION
>
> Please add to "svn export" option:
>
>     -x, --exclude ITEM
>
> which could be given multiple times. The option would exclude files and
> paths relative to the current repository root from the final output.
>
> The pattern could be:
>
>     - String to match path
>     - OR shell-like pattern to match path (allowing "*" and "[]")
>     - OR regular expression (the best)
>
> MOTIVATION
>
> Many times the repository contains private development files that should
> not be included in PACKAGE-VERSION.tar.gz
>
> An example:
>
>     ROOT
>     | program.sh
>     |
>     | test.data
>     | output.log
>     |
>     +- scripts/
>        my-own.sh
>        not-publishable.sh
>
>     $ svn export -x ./test.data -x *.log -x scripts
> ../package-1.0+svn10.tar.gz
>
> Would make an archive content:
>
>     ROOT
>     |
>     + - program.sh
>
> This is a snapshop from VCS tree. Different from if there would have been a
> Makefile to do official release in target "make dist".
>
> Jari
>
>