You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@buildr.apache.org by "Ittay Dror (JIRA)" <ji...@apache.org> on 2008/11/17 21:34:44 UTC

[jira] Created: (BUILDR-217) separate 'type' from 'extension' in packages

separate 'type' from 'extension' in packages
--------------------------------------------

                 Key: BUILDR-217
                 URL: https://issues.apache.org/jira/browse/BUILDR-217
             Project: Buildr
          Issue Type: Improvement
          Components: Packaging
    Affects Versions: 1.3.2
            Reporter: Ittay Dror
             Fix For: 1.3.4


#package currently uses spec[:type] for both the 'type' of the artifact and the extension given to the file name.

but sometimes files with the same extension may be of different types. in OSGI for example, the extension is always .jar, but they can be bundles or fragements. another example is source jars or zips. their type is 'source', regardless of the extension (as long as it is some sort of zip of course).

in maven, ArtifactHandler separates between extension and 'packaging' i think it would be good for buildr to have the same

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (BUILDR-217) separate 'type' from 'extension' in packages

Posted by "Assaf Arkin (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/BUILDR-217?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12648314#action_12648314 ] 

Assaf Arkin commented on BUILDR-217:
------------------------------------

The package method uses the type argument to determine which packager to call, packager then decides how to apply the spec to the artifact, so it's entirely possible to have an :osgi packager creating a .jar artifact.

> separate 'type' from 'extension' in packages
> --------------------------------------------
>
>                 Key: BUILDR-217
>                 URL: https://issues.apache.org/jira/browse/BUILDR-217
>             Project: Buildr
>          Issue Type: Improvement
>          Components: Packaging
>    Affects Versions: 1.3.2
>            Reporter: Ittay Dror
>             Fix For: 1.3.4
>
>
> #package currently uses spec[:type] for both the 'type' of the artifact and the extension given to the file name.
> but sometimes files with the same extension may be of different types. in OSGI for example, the extension is always .jar, but they can be bundles or fragements. another example is source jars or zips. their type is 'source', regardless of the extension (as long as it is some sort of zip of course).
> in maven, ArtifactHandler separates between extension and 'packaging' i think it would be good for buildr to have the same

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (BUILDR-217) separate 'type' from 'extension' in packages

Posted by "Alex Boisvert (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/BUILDR-217?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12840028#action_12840028 ] 

Alex Boisvert commented on BUILDR-217:
--------------------------------------

I'm fine adding a new method and extending ActsAsArtifact sensibly... I would just like to have a more concrete example so we design + test this correctly.

> separate 'type' from 'extension' in packages
> --------------------------------------------
>
>                 Key: BUILDR-217
>                 URL: https://issues.apache.org/jira/browse/BUILDR-217
>             Project: Buildr
>          Issue Type: Improvement
>          Components: Packaging
>    Affects Versions: 1.3.2
>            Reporter: Ittay Dror
>
> #package currently uses spec[:type] for both the 'type' of the artifact and the extension given to the file name.
> but sometimes files with the same extension may be of different types. in OSGI for example, the extension is always .jar, but they can be bundles or fragements. another example is source jars or zips. their type is 'source', regardless of the extension (as long as it is some sort of zip of course).
> in maven, ArtifactHandler separates between extension and 'packaging' i think it would be good for buildr to have the same

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (BUILDR-217) separate 'type' from 'extension' in packages

Posted by "Antoine Toulme (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/BUILDR-217?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12840031#action_12840031 ] 

Antoine Toulme commented on BUILDR-217:
---------------------------------------

It would rather be an accessor on the package object named pkg_type, which would be set before the package is interpreted as an artifact, and the type is changed.

Ittay, I think even with that you still will have more than one package for the same type:
package(:osgi, :file => "myfile.jar")
package(:osgi)

So if you planned on referring on it through the type, that won't work. However, get that:
once a package has been defined for a particular type and settings, you can find it again by reusing the same arguments and call package.

define "foo" do
  package(:osgi) => your package
end
project("foo").package(:osgi) => your package

See what I mean ?


> separate 'type' from 'extension' in packages
> --------------------------------------------
>
>                 Key: BUILDR-217
>                 URL: https://issues.apache.org/jira/browse/BUILDR-217
>             Project: Buildr
>          Issue Type: Improvement
>          Components: Packaging
>    Affects Versions: 1.3.2
>            Reporter: Ittay Dror
>
> #package currently uses spec[:type] for both the 'type' of the artifact and the extension given to the file name.
> but sometimes files with the same extension may be of different types. in OSGI for example, the extension is always .jar, but they can be bundles or fragements. another example is source jars or zips. their type is 'source', regardless of the extension (as long as it is some sort of zip of course).
> in maven, ArtifactHandler separates between extension and 'packaging' i think it would be good for buildr to have the same

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (BUILDR-217) separate 'type' from 'extension' in packages

Posted by "Antoine Toulme (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/BUILDR-217?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12839483#action_12839483 ] 

Antoine Toulme commented on BUILDR-217:
---------------------------------------

That's because of the semantic overlap with ActsAsArtifact which assumes that type is the extension of the file.

Would it be ok to have a different reader for the packaging type ?

something like: package(:osgi).pkg_type => :osgi

I don't see much of a use for this though.

> separate 'type' from 'extension' in packages
> --------------------------------------------
>
>                 Key: BUILDR-217
>                 URL: https://issues.apache.org/jira/browse/BUILDR-217
>             Project: Buildr
>          Issue Type: Improvement
>          Components: Packaging
>    Affects Versions: 1.3.2
>            Reporter: Ittay Dror
>
> #package currently uses spec[:type] for both the 'type' of the artifact and the extension given to the file name.
> but sometimes files with the same extension may be of different types. in OSGI for example, the extension is always .jar, but they can be bundles or fragements. another example is source jars or zips. their type is 'source', regardless of the extension (as long as it is some sort of zip of course).
> in maven, ArtifactHandler separates between extension and 'packaging' i think it would be good for buildr to have the same

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Resolved: (BUILDR-217) separate 'type' from 'extension' in packages

Posted by "Antoine Toulme (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/BUILDR-217?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Antoine Toulme resolved BUILDR-217.
-----------------------------------

    Resolution: Won't Fix

Looks like we cover this in a different way.

> separate 'type' from 'extension' in packages
> --------------------------------------------
>
>                 Key: BUILDR-217
>                 URL: https://issues.apache.org/jira/browse/BUILDR-217
>             Project: Buildr
>          Issue Type: Improvement
>          Components: Packaging
>    Affects Versions: 1.3.2
>            Reporter: Ittay Dror
>
> #package currently uses spec[:type] for both the 'type' of the artifact and the extension given to the file name.
> but sometimes files with the same extension may be of different types. in OSGI for example, the extension is always .jar, but they can be bundles or fragements. another example is source jars or zips. their type is 'source', regardless of the extension (as long as it is some sort of zip of course).
> in maven, ArtifactHandler separates between extension and 'packaging' i think it would be good for buildr to have the same

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (BUILDR-217) separate 'type' from 'extension' in packages

Posted by "Ittay Dror (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/BUILDR-217?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12648326#action_12648326 ] 

Ittay Dror commented on BUILDR-217:
-----------------------------------

yes, as with 'sources', but unless i'm mistaken, the #type method of the package will return 'jar', not 'osgi'

> separate 'type' from 'extension' in packages
> --------------------------------------------
>
>                 Key: BUILDR-217
>                 URL: https://issues.apache.org/jira/browse/BUILDR-217
>             Project: Buildr
>          Issue Type: Improvement
>          Components: Packaging
>    Affects Versions: 1.3.2
>            Reporter: Ittay Dror
>             Fix For: 1.3.4
>
>
> #package currently uses spec[:type] for both the 'type' of the artifact and the extension given to the file name.
> but sometimes files with the same extension may be of different types. in OSGI for example, the extension is always .jar, but they can be bundles or fragements. another example is source jars or zips. their type is 'source', regardless of the extension (as long as it is some sort of zip of course).
> in maven, ArtifactHandler separates between extension and 'packaging' i think it would be good for buildr to have the same

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.