Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

universalArchiveOptions setting tar CLI command arguments: incorrect order (maybe) #886

Closed
mackler opened this issue Oct 5, 2016 · 1 comment
Labels
universal Zip, tar.gz, tgz and bash issues

Comments

@mackler
Copy link
Contributor

mackler commented Oct 5, 2016

I'm unsure whether or not I'm seeing a bug. I added this line to my build.sbt

universalArchiveOptions in (Universal, packageZipTarball) := Seq("--exclude", "*~")

and I got a new tar error, including (in part) the following output:

Running with tar --exclude *~ /tmp/sbt_726bf22d/myApp-0.1.tar myApp-0.1
tar: Must specify one of -c, -r, -t, -u, -x

It looks as if my custom tar option may need to come after the tar-file name rather than before. It might also be causing a -c switch to go missing, but that might be a default and unnecessary; I am unsure.

Or maybe I'm doing something wrong.

@muuki88 muuki88 added the universal Zip, tar.gz, tgz and bash issues label Oct 6, 2016
@muuki88
Copy link
Contributor

muuki88 commented Oct 6, 2016

I guess your configuration is not correct. The options are used like this.

val cmd = Seq("tar") ++ options ++ Seq(tmptar.getAbsolutePath) ++ distdirs

The error message you are seeing also states what is missing. As you override the default configuration, which is

universalArchiveOptions in (Universal, packageZipTarball) := Seq("-pcvf")

the tar command isn't complete.

@muuki88 muuki88 closed this as completed Oct 6, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
universal Zip, tar.gz, tgz and bash issues
Projects
None yet
Development

No branches or pull requests

2 participants