Mailinglist Archive: opensuse-buildservice (120 mails)

< Previous Next >
[opensuse-buildservice] [PATCH] [obs-service-tar_scm] - Exclude SCM files by default
  • From: Troy Telford <ttelford.groups@xxxxxxxxx>
  • Date: Thu, 14 Jul 2011 17:48:00 -0600
  • Message-id: <ivnv7g$ldn$1@dough.gmane.org>
In my own testing of the tar_scm 'exclude' feature, I found that the 'tar' command grabs all of the scm's metadata (.svn, .git, etc.)

Tar has the option --exclude-vcs, which excludes these files from the tarball. These seems to make the most sense for the way I think tar_scm is supposed to be used.

An alternative (possibly better) way would be to have an option to the source service that allows the user to toggle this option on/off; however I don't currently know of any use cases where it would be useful to have the version control system's metadata in the tarball.

@@ -258,7 +258,7 @@

mv "$FILE/$MYSUBDIR" "${FILE}-${VERSION}" || exit 1

-tar cf "$MYOUTDIR/${FILE}-${VERSION}.tar" $EXCLUDES "${FILE}-${VERSION}" || exit 1
+tar cf "$MYOUTDIR/${FILE}-${VERSION}.tar" --exclude-vcs $EXCLUDES "${FILE}-${VERSION}" || exit 1
rm -rf "${FILE}-${VERSION}" "$FILE"

exit 0

--
Troy Telford


--
To unsubscribe, e-mail: opensuse-buildservice+unsubscribe@xxxxxxxxxxxx
For additional commands, e-mail: opensuse-buildservice+help@xxxxxxxxxxxx

< Previous Next >
This Thread
  • No further messages