Some archive stuff

classic Classic list List threaded Threaded
6 messages Options
Reply | Threaded
Open this post in threaded view
|

Some archive stuff

hans_d
Administrator
There are some issues left with our very nice new archive handling.

usePlugin('base')

task topLevelInclude(type: Zip) {
   baseName = "topLevelInclude"
   include "foo"
}

task inheritInto(type: Zip) {
   baseName = "inheritInfo"
   into "bar"
   from('foo')
}

- The topLevelInclude zip is empty. I would expect it to include foo.
- The inheritInto zip has foo as a first level file. I would expect it to be in bar/foo.

I have attached a zip with the test project.

- Hans

--
Hans Dockter
Gradle Project Manager
http://www.gradle.org






---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email

archivetest.zip (9K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: Some archive stuff

hans_d
Administrator
one more issue:

If I create the following zip:

task permissions(type: Zip) {
   baseName = "permissions"
   from('foo') {
      fileMode = 755
   }
}

After unzipping the zip, I have the following permissions for foo: --wxrw--wx  1 hans  hans   12 Nov 16 20:15 foo

- Hans

--
Hans Dockter
Gradle Project Manager
http://www.gradle.org

On Nov 16, 2009, at 8:28 PM, Hans Dockter wrote:

> There are some issues left with our very nice new archive handling.
>
> usePlugin('base')
>
> task topLevelInclude(type: Zip) {
>   baseName = "topLevelInclude"
>   include "foo"
> }
>
> task inheritInto(type: Zip) {
>   baseName = "inheritInfo"
>   into "bar"
>   from('foo')
> }
>
> - The topLevelInclude zip is empty. I would expect it to include foo.
> - The inheritInto zip has foo as a first level file. I would expect it to be in bar/foo.
>
> I have attached a zip with the test project.
>
> - Hans
>
> --
> Hans Dockter
> Gradle Project Manager
> http://www.gradle.org
>
>
>
>
>
> <archivetest.zip>---------------------------------------------------------------------
> To unsubscribe from this list, please visit:
>
>    http://xircles.codehaus.org/manage_email


---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email


Reply | Threaded
Open this post in threaded view
|

Re: Some archive stuff

Adam Murdoch-2


Hans Dockter wrote:
one more issue:

If I create the following zip:

task permissions(type: Zip) {
   baseName = "permissions"
   from('foo') {
      fileMode = 755
   }
}

After unzipping the zip, I have the following permissions for foo: --wxrw--wx  1 hans  hans   12 Nov 16 20:15 foo

  

You need to use octal for 755 to work, ie fileMode = 0755. You've asked for 0363, above, which is what you got.

Perhaps an integer type is not the best option for this property.  Maybe a string would be better instead, something like fileMode = "rwxr-xr-x", or fileMode = "ugo+x"


- Hans

--
Hans Dockter
Gradle Project Manager
http://www.gradle.org

On Nov 16, 2009, at 8:28 PM, Hans Dockter wrote:

  
There are some issues left with our very nice new archive handling.

usePlugin('base')

task topLevelInclude(type: Zip) {
  baseName = "topLevelInclude"
  include "foo"
}

task inheritInto(type: Zip) {
  baseName = "inheritInfo"
  into "bar"
  from('foo')
}

- The topLevelInclude zip is empty. I would expect it to include foo.
- The inheritInto zip has foo as a first level file. I would expect it to be in bar/foo.

I have attached a zip with the test project.

- Hans

--
Hans Dockter
Gradle Project Manager
http://www.gradle.org





<archivetest.zip>---------------------------------------------------------------------
To unsubscribe from this list, please visit:

   http://xircles.codehaus.org/manage_email
    


---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email


  

-- 
Adam Murdoch
Gradle Developer
http://www.gradle.org
Reply | Threaded
Open this post in threaded view
|

Re: Some archive stuff

hans_d
Administrator

On Nov 16, 2009, at 10:06 PM, Adam Murdoch wrote:



Hans Dockter wrote:
one more issue:

If I create the following zip:

task permissions(type: Zip) {
   baseName = "permissions"
   from('foo') {
      fileMode = 755
   }
}

After unzipping the zip, I have the following permissions for foo: --wxrw--wx  1 hans  hans   12 Nov 16 20:15 foo

  

You need to use octal for 755 to work, ie fileMode = 0755. You've asked for 0363, above, which is what you got.

I understand. I guess I was in Ant mode, which uses 3-digit octal notation.


Perhaps an integer type is not the best option for this property.  Maybe a string would be better instead, something like fileMode = "rwxr-xr-x", or fileMode = "ugo+x"

May be. Although I'm fine with the integer notation. 

- Hans

--
Hans Dockter
Gradle Project Manager



- Hans

--
Hans Dockter
Gradle Project Manager
http://www.gradle.org

On Nov 16, 2009, at 8:28 PM, Hans Dockter wrote:

  
There are some issues left with our very nice new archive handling.

usePlugin('base')

task topLevelInclude(type: Zip) {
  baseName = "topLevelInclude"
  include "foo"
}

task inheritInto(type: Zip) {
  baseName = "inheritInfo"
  into "bar"
  from('foo')
}

- The topLevelInclude zip is empty. I would expect it to include foo.
- The inheritInto zip has foo as a first level file. I would expect it to be in bar/foo.

I have attached a zip with the test project.

- Hans

--
Hans Dockter
Gradle Project Manager
http://www.gradle.org





<archivetest.zip>---------------------------------------------------------------------
To unsubscribe from this list, please visit:

   http://xircles.codehaus.org/manage_email
    


---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email


  

-- 
Adam Murdoch
Gradle Developer
http://www.gradle.org

Reply | Threaded
Open this post in threaded view
|

Re: Some archive stuff

Tomek Kaczanowski-3
>       fileMode = 755
> fileMode = "rwxr-xr-x",
> fileMode = "ugo+x"
would be really nice to be able to use all of them

but if I had to choose I would vote for the first one

--
Tomek

---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email


Reply | Threaded
Open this post in threaded view
|

Re: Some archive stuff

Adam Murdoch-2
In reply to this post by hans_d


Hans Dockter wrote:
There are some issues left with our very nice new archive handling.

usePlugin('base')

task topLevelInclude(type: Zip) {
   baseName = "topLevelInclude"
   include "foo"
}

task inheritInto(type: Zip) {
   baseName = "inheritInfo"
   into "bar"
   from('foo')
}

- The topLevelInclude zip is empty. I would expect it to include foo.
  

Does that mean that the following should create a Zip containing the entire project directory?

task someZip(type: Zip) {
}

Perhaps instead it should be an error to use include or exclude when no source has been specified.

- The inheritInto zip has foo as a first level file. I would expect it to be in bar/foo.

  

I'll fix that.

I have attached a zip with the test project.

- Hans

--
Hans Dockter
Gradle Project Manager
http://www.gradle.org





  

--------------------------------------------------------------------- To unsubscribe from this list, please visit: http://xircles.codehaus.org/manage_email

-- 
Adam Murdoch
Gradle Developer
http://www.gradle.org