You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by Med DAB <mo...@gmail.com> on 2009/03/05 14:55:11 UTC

Can we make a reference to a file from a jar or via scm?

Hello,

The application I'm developping depends on database patch version. 

I'm using sql:execute maven plugin to execute scripts.

My problem is how to make a reference to the sql scripts if they are in a
jar file which have a version or 

reference them using SCM?

If anyone have an answer, please help me. If not, is there a better and
cleaner way to make a dependency between application and database versions?
-- 
View this message in context: http://www.nabble.com/Can-we-make-a-reference-to-a-file-from-a-jar-or-via-scm--tp22352074p22352074.html
Sent from the Maven - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


RE: Can we make a reference to a file from a jar or via scm?

Posted by Med DAB <mo...@gmail.com>.
Thank you Martin for you answer. 

Thank you lhazlewood for your proposal. I believe that this is the issue.
I'll try it.


Med DAB wrote:
> 
> I'm using sql:execute plugin. I want to make a reference to a sql file in
> a jar file or in cvs project because the application depends on a database
> script version. 
> 
> What I'm doing now, I chekout the projet which 
> 
> contains  all the scripts and I refer all script files as follows:
> 
> <srcFile>../database-scripts-project/my-scripts/script1.sql</srcFile>
> <srcFile>../database-scripts-project/my-scripts/script1.sql</srcFile>
> 
> I believe that this is a dirty way to make a reference to my scripts.
> 
> If you have other alternatives, even with ant, can you explain it for me?
> 
> 
> mgainty wrote:
>> 
>> 
>> you can write the same build in ANT (which has no enforced version
>> checking)
>> 
>> Mavens strength is version checking for main artifact and all
>> dependencies and using that version for SCM integration..
>> 
>> I dont understand why you would want to cast off version-checking
>> ?
>> Martin 
>> ______________________________________________ 
>> Disclaimer and confidentiality note 
>> Everything in this e-mail and any attachments relates to the official
>> business of Sender. This transmission is of a confidential nature and
>> Sender does not endorse distribution to any party other than intended
>> recipient. Sender does not necessarily endorse content contained within
>> this transmission. 
>> 
>> 
>> 
>> 
>>> Date: Thu, 5 Mar 2009 05:55:11 -0800
>>> From: mohamed.dabbech@gmail.com
>>> To: users@maven.apache.org
>>> Subject: Can we make a reference to a file from a jar or via scm?
>>> 
>>> 
>>> Hello,
>>> 
>>> The application I'm developping depends on database patch version. 
>>> 
>>> I'm using sql:execute maven plugin to execute scripts.
>>> 
>>> My problem is how to make a reference to the sql scripts if they are in
>>> a
>>> jar file which have a version or 
>>> 
>>> reference them using SCM?
>>> 
>>> If anyone have an answer, please help me. If not, is there a better and
>>> cleaner way to make a dependency between application and database
>>> versions?
>>> -- 
>>> View this message in context:
>>> http://www.nabble.com/Can-we-make-a-reference-to-a-file-from-a-jar-or-via-scm--tp22352074p22352074.html
>>> Sent from the Maven - Users mailing list archive at Nabble.com.
>>> 
>>> 
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
>>> For additional commands, e-mail: users-help@maven.apache.org
>>> 
>> 
>> _________________________________________________________________
>> Express your personality in color! Preview and select themes for
>> Hotmail®. 
>> http://www.windowslive-hotmail.com/LearnMore/personalize.aspx?ocid=TXT_MSGTX_WL_HM_express_032009#colortheme
>> 
> 
> 

-- 
View this message in context: http://www.nabble.com/Can-we-make-a-reference-to-a-file-from-a-jar-or-via-scm--tp22352074p22354545.html
Sent from the Maven - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


RE: Can we make a reference to a file from a jar or via scm?

Posted by Med DAB <mo...@gmail.com>.
Thanks a lot lhazlewood. It's a good solution. It works fine :handshake:.

Mohamed


Med DAB wrote:
> 
> I'm using sql:execute plugin. I want to make a reference to a sql file in
> a jar file or in cvs project because the application depends on a database
> script version. 
> 
> What I'm doing now, I chekout the projet which 
> 
> contains  all the scripts and I refer all script files as follows:
> 
> <srcFile>../database-scripts-project/my-scripts/script1.sql</srcFile>
> <srcFile>../database-scripts-project/my-scripts/script1.sql</srcFile>
> 
> I believe that this is a dirty way to make a reference to my scripts.
> 
> If you have other alternatives, even with ant, can you explain it for me?
> 
> 
> mgainty wrote:
>> 
>> 
>> you can write the same build in ANT (which has no enforced version
>> checking)
>> 
>> Mavens strength is version checking for main artifact and all
>> dependencies and using that version for SCM integration..
>> 
>> I dont understand why you would want to cast off version-checking
>> ?
>> Martin 
>> ______________________________________________ 
>> Disclaimer and confidentiality note 
>> Everything in this e-mail and any attachments relates to the official
>> business of Sender. This transmission is of a confidential nature and
>> Sender does not endorse distribution to any party other than intended
>> recipient. Sender does not necessarily endorse content contained within
>> this transmission. 
>> 
>> 
>> 
>> 
>>> Date: Thu, 5 Mar 2009 05:55:11 -0800
>>> From: mohamed.dabbech@gmail.com
>>> To: users@maven.apache.org
>>> Subject: Can we make a reference to a file from a jar or via scm?
>>> 
>>> 
>>> Hello,
>>> 
>>> The application I'm developping depends on database patch version. 
>>> 
>>> I'm using sql:execute maven plugin to execute scripts.
>>> 
>>> My problem is how to make a reference to the sql scripts if they are in
>>> a
>>> jar file which have a version or 
>>> 
>>> reference them using SCM?
>>> 
>>> If anyone have an answer, please help me. If not, is there a better and
>>> cleaner way to make a dependency between application and database
>>> versions?
>>> -- 
>>> View this message in context:
>>> http://www.nabble.com/Can-we-make-a-reference-to-a-file-from-a-jar-or-via-scm--tp22352074p22352074.html
>>> Sent from the Maven - Users mailing list archive at Nabble.com.
>>> 
>>> 
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
>>> For additional commands, e-mail: users-help@maven.apache.org
>>> 
>> 
>> _________________________________________________________________
>> Express your personality in color! Preview and select themes for
>> Hotmail®. 
>> http://www.windowslive-hotmail.com/LearnMore/personalize.aspx?ocid=TXT_MSGTX_WL_HM_express_032009#colortheme
>> 
> 
> 

-- 
View this message in context: http://www.nabble.com/Can-we-make-a-reference-to-a-file-from-a-jar-or-via-scm--tp22352074p22357758.html
Sent from the Maven - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


RE: Can we make a reference to a file from a jar or via scm?

Posted by Med DAB <mo...@gmail.com>.
I'm using sql:execute plugin. I want to make a reference to a sql file in a
jar file or in cvs project because the application depends on a database
script version. 

What I'm doing now, I chekout the projet which 

contains  all the scripts and I refer all script files as follows:

<srcFile>../database-scripts-project/my-scripts/script1.sql</srcFile>
<srcFile>../database-scripts-project/my-scripts/script1.sql</srcFile>

I believe that this is a dirty way to make a reference to my scripts.

If you have other alternatives, even with ant, can you explain it for me?


mgainty wrote:
> 
> 
> you can write the same build in ANT (which has no enforced version
> checking)
> 
> Mavens strength is version checking for main artifact and all dependencies
> and using that version for SCM integration..
> 
> I dont understand why you would want to cast off version-checking
> ?
> Martin 
> ______________________________________________ 
> Disclaimer and confidentiality note 
> Everything in this e-mail and any attachments relates to the official
> business of Sender. This transmission is of a confidential nature and
> Sender does not endorse distribution to any party other than intended
> recipient. Sender does not necessarily endorse content contained within
> this transmission. 
> 
> 
> 
> 
>> Date: Thu, 5 Mar 2009 05:55:11 -0800
>> From: mohamed.dabbech@gmail.com
>> To: users@maven.apache.org
>> Subject: Can we make a reference to a file from a jar or via scm?
>> 
>> 
>> Hello,
>> 
>> The application I'm developping depends on database patch version. 
>> 
>> I'm using sql:execute maven plugin to execute scripts.
>> 
>> My problem is how to make a reference to the sql scripts if they are in a
>> jar file which have a version or 
>> 
>> reference them using SCM?
>> 
>> If anyone have an answer, please help me. If not, is there a better and
>> cleaner way to make a dependency between application and database
>> versions?
>> -- 
>> View this message in context:
>> http://www.nabble.com/Can-we-make-a-reference-to-a-file-from-a-jar-or-via-scm--tp22352074p22352074.html
>> Sent from the Maven - Users mailing list archive at Nabble.com.
>> 
>> 
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
>> For additional commands, e-mail: users-help@maven.apache.org
>> 
> 
> _________________________________________________________________
> Express your personality in color! Preview and select themes for Hotmail®. 
> http://www.windowslive-hotmail.com/LearnMore/personalize.aspx?ocid=TXT_MSGTX_WL_HM_express_032009#colortheme
> 

-- 
View this message in context: http://www.nabble.com/Can-we-make-a-reference-to-a-file-from-a-jar-or-via-scm--tp22352074p22354440.html
Sent from the Maven - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


RE: Can we make a reference to a file from a jar or via scm?

Posted by Martin Gainty <mg...@hotmail.com>.
you can write the same build in ANT (which has no enforced version checking)

Mavens strength is version checking for main artifact and all dependencies and using that version for SCM integration..

I dont understand why you would want to cast off version-checking
?
Martin 
______________________________________________ 
Disclaimer and confidentiality note 
Everything in this e-mail and any attachments relates to the official business of Sender. This transmission is of a confidential nature and Sender does not endorse distribution to any party other than intended recipient. Sender does not necessarily endorse content contained within this transmission. 




> Date: Thu, 5 Mar 2009 05:55:11 -0800
> From: mohamed.dabbech@gmail.com
> To: users@maven.apache.org
> Subject: Can we make a reference to a file from a jar or via scm?
> 
> 
> Hello,
> 
> The application I'm developping depends on database patch version. 
> 
> I'm using sql:execute maven plugin to execute scripts.
> 
> My problem is how to make a reference to the sql scripts if they are in a
> jar file which have a version or 
> 
> reference them using SCM?
> 
> If anyone have an answer, please help me. If not, is there a better and
> cleaner way to make a dependency between application and database versions?
> -- 
> View this message in context: http://www.nabble.com/Can-we-make-a-reference-to-a-file-from-a-jar-or-via-scm--tp22352074p22352074.html
> Sent from the Maven - Users mailing list archive at Nabble.com.
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
> 

_________________________________________________________________
Express your personality in color! Preview and select themes for Hotmail®. 
http://www.windowslive-hotmail.com/LearnMore/personalize.aspx?ocid=TXT_MSGTX_WL_HM_express_032009#colortheme

Re: Can we make a reference to a file from a jar or via scm?

Posted by Les Hazlewood <le...@hazlewood.com>.
Use the remote-resources plugin?  That can pull in your external .jar,
unpack it to a directory, and then you can use the SQL files within...

On Thu, Mar 5, 2009 at 8:55 AM, Med DAB <mo...@gmail.com> wrote:

>
> Hello,
>
> The application I'm developping depends on database patch version.
>
> I'm using sql:execute maven plugin to execute scripts.
>
> My problem is how to make a reference to the sql scripts if they are in a
> jar file which have a version or
>
> reference them using SCM?
>
> If anyone have an answer, please help me. If not, is there a better and
> cleaner way to make a dependency between application and database versions?
> --
> View this message in context:
> http://www.nabble.com/Can-we-make-a-reference-to-a-file-from-a-jar-or-via-scm--tp22352074p22352074.html
> Sent from the Maven - Users mailing list archive at Nabble.com.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
>
>