buildr-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Alex Boisvert (JIRA)" <j...@apache.org>
Subject [jira] Resolved: (BUILDR-364) Package spec should be set to a Symbol when :file is used
Date Fri, 22 Jan 2010 19:54:21 GMT

     [ https://issues.apache.org/jira/browse/BUILDR-364?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Alex Boisvert resolved BUILDR-364.
----------------------------------

    Resolution: Fixed

Patch applied.  Thanks Klaas!

Sending        CHANGELOG
Sending        lib/buildr/packaging/package.rb
Transmitting file data ..
Committed revision 902243.


> Package spec should be set to a Symbol when :file is used
> ---------------------------------------------------------
>
>                 Key: BUILDR-364
>                 URL: https://issues.apache.org/jira/browse/BUILDR-364
>             Project: Buildr
>          Issue Type: Bug
>          Components: Packaging
>    Affects Versions: 1.3.5
>         Environment: jruby
>            Reporter: Klaas Prause
>            Priority: Minor
>             Fix For: 1.4
>
>
> It exists an inconsistency between different usages of the package task.
> 1. for "package :war" the resulting type is the Symbol :war
> 2. for "package :file => 'x.war'" the resulting type is the String 'war'
> All types should be symbols to make it easier for extensions to check the type of a package
and apply plugin specific options.
> Diff:
> --- package.rb	2010-01-21 14:35:42.300225858 +0100
> +++ package.rb.new	2010-01-21 14:35:37.770222393 +0100
> @@ -132,7 +132,7 @@
>        no_options = spec.empty? # since spec is mutated
>        if spec[:file]
>          rake_check_options spec, :file, :type
> -        spec[:type] = args.shift || spec[:type] || spec[:file].split('.').last
> +        spec[:type] = (args.shift || spec[:type] || spec[:file].split('.').last).to_sym
>          file_name = spec[:file]
>        else
>          rake_check_options spec, *ActsAsArtifact::ARTIFACT_ATTRIBUTES

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


Mime
View raw message