Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Mailing lists / lazarus / 2008-06

Publishing a Lazarus project - 'Command after'

9 messages · 3 people · –

Reply by email Subscribe to this list Your subscription

Read-only archive. Use j and k to move between messages.

Csányi Pál

Hello!

I have installed on Debian GNU/Linux Etch Lazarus version 0.9.25 beta Date 2008-6-18.

I try to publish a project with 'Command after'.

If I use as a 'Command after' in the 'Publish Project...' window the:

tar cjf $(ProjPath)/project.tar.bz2 $(ProjPublishDir)

command, then almost everything is OK:

the project.tar.bz2 is in the project directory, but if I untar it

with command:

tar xjf project.tar.bz2

then I get /lot/of/directories/project_files.

What to put in this command

tar cjf $(?)/lptinterface.tar.bz2 $(ProjPublishDir) ^^^
at this point

to get the project files in the project.tar.bz2 without these directories that is the path to the project directory?

What are these variables: $(ProjPublishDir), etc., and how many are there?

Where can I read about them?

Any advices will be appreciated!

Reply by email

Mattias Gaertner
to Csányi Pál
Show quoted text 20 lines
Hello! I have installed on Debian GNU/Linux Etch Lazarus version 0.9.25 beta Date 2008-6-18. I try to publish a project with 'Command after'. If I use as a 'Command after' in the 'Publish Project...' window the: tar cjf $(ProjPath)/project.tar.bz2 $(ProjPublishDir) command, then almost everything is OK: the project.tar.bz2 is in the project directory, but if I untar it with command: tar xjf project.tar.bz2 then I get /lot/of/directories/project_files.

Try the -C option of tar. For example:

/bin/tar czf $(TestDir)/projectname.tgz -C $(TestDir) projectname

Show quoted text 13 lines
What to put in this command tar cjf $(?)/lptinterface.tar.bz2 $(ProjPublishDir) ^^^ at this point to get the project files in the project.tar.bz2 without these directories that is the path to the project directory? What are these variables: $(ProjPublishDir), etc., and how many are there? Where can I read about them?

http://wiki.lazarus.freepascal.org/IDE_Macros_in_paths_and_filenames

Any advices will be appreciated!

Mattias

Reply by email

Csányi Pál
to Mattias Gaertner
Mattias Gaertner wrote 25 lines
On Thu, 26 Jun 2008 17:31:11 +0200 (Cs??nyi P??l) wrote: > I have installed on Debian GNU/Linux Etch Lazarus version 0.9.25 > beta Date 2008-6-18. > > I try to publish a project with 'Command after'. > > If I use as a 'Command after' in the 'Publish Project...' window the: > > tar cjf $(ProjPath)/project.tar.bz2 $(ProjPublishDir) > > command, then almost everything is OK: > > the project.tar.bz2 is in the project directory, but if I untar it > > with command: > > tar xjf project.tar.bz2 > > then I get /lot/of/directories/project_files. Try the -C option of tar. For example: /bin/tar czf $(TestDir)/projectname.tgz -C $(TestDir) projectname

I understand now the point, it works!

Show quoted text 6 lines
> What are these variables: $(ProjPublishDir), etc., and how many are > there? > > Where can I read about them? http://wiki.lazarus.freepascal.org/IDE_Macros_in_paths_and_filenames

Thanks! It's hard to find this link on the lazarus wiki page.

Now I want to include the binary file too in to the published project.tar.bz2 but I can't to get it, however I leave blank the box before Files / Ignore binaries.

Why can't I include the binary file in to the published project?

Reply by email

Mattias Gaertner
to Csányi Pál
Show quoted text 6 lines
Mattias Gaertner writes: [...] > http://wiki.lazarus.freepascal.org/IDE_Macros_in_paths_and_filenames Thanks! It's hard to find this link on the lazarus wiki page.

Yes, sometimes the search does not work very well. Even if I know that the page exists, the search does not find it.

Now I want to include the binary file too in to the published project.tar.bz2 but I can't to get it, however I leave blank the box before Files / Ignore binaries.

Maybe your file mask is incorrect?

Why can't I include the binary file in to the published project?

You did something wrong.

Mattias

Reply by email

Csányi Pál
to Mattias Gaertner
Mattias Gaertner wrote 8 lines
On Thu, 26 Jun 2008 22:21:49 +0200 (Cs??nyi P??l) wrote: > Now I want to include the binary file too in to the published > project.tar.bz2 but I can't to get it, however I leave blank the box > before Files / Ignore binaries. Maybe your file mask is incorrect?

My system is Debian GNU/Linux Etch so the executable binaries hasn't a file mask.

After I compiled a Lazarus project I get the following files in the project directory:

lptinterface1.hu.mo
lptinterface1.po
lptinterfaceunit1.o
interfaces.o
lptinterface1.hu.po
lptinterface1.sr.mo
lptinterfaceunit1.pas
interfaces.pas
lptinterface1.lpi
lptinterface1.sr.po
lptinterfaceunit1.ppu
interfaces.ppu
lptinterface1.lpr
lptinterfaceunit1.lfm
lptinterfaceunit1.rst
lptinterface1 <-------- This is the binary file. lptinterface1.mo
lptinterfaceunit1.lrs
lptinterface1.compiled
lptinterface1.o
lptinterfaceunit1.lrt

I can to run the 'lptinterface1' binary file in the xterm window with the

./lptinterface1

command.

This file: lptinterface1 hasn't a file mask, right?

When I am publishing this project I have the following setup at:

(_ mean that the box is not set,
* mean that the box is set)

'Files':

_ Ignore binaries

'Use Include Filter':

* Use Include Filter
* Simple Syntax

.(pas|pp|inc|lfm|lpr|lrs|lpi|lpk|sh|xml|txt|po)

'Exclude Filter':

* Use Exclude Filter
* Simple Syntax

.(bak|ppu|ppw|o|so);*~;backup

Is my file mask incorrect?

What am I doing wrong?

Reply by email

Mattias Gärtner
to Csányi Pál

Zitat von Cs????nyi P????l :

Show quoted text 13 lines
Mattias Gaertner writes: > On Thu, 26 Jun 2008 22:21:49 +0200 > (Cs????nyi P????l) wrote: > >> Now I want to include the binary file too in to the published >> project.tar.bz2 but I can't to get it, however I leave blank the box >> before Files / Ignore binaries. > > Maybe your file mask is incorrect? My system is Debian GNU/Linux Etch so the executable binaries hasn't a file mask.

No file has a mask. Your file has no extension.
That's why you must use the right mask in the 'include filter'.

Show quoted text 51 lines
After I compiled a Lazarus project I get the following files in the project directory: lptinterface1.hu.mo lptinterface1.po lptinterfaceunit1.o interfaces.o lptinterface1.hu.po lptinterface1.sr.mo lptinterfaceunit1.pas interfaces.pas lptinterface1.lpi lptinterface1.sr.po lptinterfaceunit1.ppu interfaces.ppu lptinterface1.lpr lptinterfaceunit1.lfm lptinterfaceunit1.rst lptinterface1 <-------- This is the binary file. lptinterface1.mo lptinterfaceunit1.lrs lptinterface1.compiled lptinterface1.o lptinterfaceunit1.lrt I can to run the 'lptinterface1' binary file in the xterm window with the ./lptinterface1 command. This file: lptinterface1 hasn't a file mask, right? When I am publishing this project I have the following setup at: (_ mean that the box is not set, * mean that the box is set) 'Files': _ Ignore binaries 'Use Include Filter': * Use Include Filter * Simple Syntax .(pas|pp|inc|lfm|lpr|lrs|lpi|lpk|sh|xml|txt|po)

This mask does not fit for lptinterface1. One solution: append: ,lptinterface1

Show quoted text 10 lines
'Exclude Filter': * Use Exclude Filter * Simple Syntax .(bak|ppu|ppw|o|so);*~;backup Is my file mask incorrect? What am I doing wrong?

Mattias

Reply by email

Csányi Pál
to Mattias Gärtner
Mattias G?rtner wrote 17 lines
Zitat von Cs????nyi P????l : > Mattias Gaertner writes: > > > On Thu, 26 Jun 2008 22:21:49 +0200 > > (Cs????nyi P????l) wrote: > > > >> Now I want to include the binary file too in to the published > >> project.tar.bz2 but I can't to get it, however I leave blank the box > >> before Files / Ignore binaries. > > > > Maybe your file mask is incorrect? > > My system is Debian GNU/Linux Etch so the executable binaries hasn't a > file mask. No file has a mask. Your file has no extension.

The binary file 'lptinterface1' has a mask?

That's why you must use the right mask in the 'include filter'.

OK

Now I have these setup:

Show quoted text 15 lines
> When I am publishing this project I have the following setup at: > > (_ mean that the box is not set, > * mean that the box is set) > > 'Files': > > _ Ignore binaries > > 'Use Include Filter': > > * Use Include Filter > * Simple Syntax > > .(pas|pp|inc|lfm|lpr|lrs|lpi|lpk|sh|xml|txt|po)

*;*.(pas|pp|inc|lfm|lpr|lrs|lpi|lpk|sh|xml|txt|po|mo)

Show quoted text 10 lines
This mask does not fit for lptinterface1. One solution: append: ,lptinterface1 > 'Exclude Filter': > > * Use Exclude Filter > * Simple Syntax > > .(bak|ppu|ppw|o|so);*~;backup

*.(compiled|rst|lrt|bak|ppu|ppw|o|so);*~;backup

It works! Thank you!

Reply by email

Mattias Gärtner
to Csányi Pál

Zitat von Cs????nyi P????l :

Show quoted text 6 lines
Mattias G??rtner writes: [...] > No file has a mask. Your file has no extension. The binary file 'lptinterface1' has a mask?

No. Well, at least not in this context. It is the same as asking 'has an apple an apple basket'?

Show quoted text 23 lines
> That's why you must use the right mask in the 'include filter'. OK Now I have these setup: >> When I am publishing this project I have the following setup at: >> >> (_ mean that the box is not set, >> * mean that the box is set) >> >> 'Files': >> >> _ Ignore binaries >> >> 'Use Include Filter': >> >> * Use Include Filter >> * Simple Syntax >> >> .(pas|pp|inc|lfm|lpr|lrs|lpi|lpk|sh|xml|txt|po) *;*.(pas|pp|inc|lfm|lpr|lrs|lpi|lpk|sh|xml|txt|po|mo)

The * fits any file. This the same as disabling 'Use Include filter'.

Show quoted text 12 lines
> This mask does not fit for lptinterface1. One solution: append: > ,lptinterface1 > > >> 'Exclude Filter': >> >> * Use Exclude Filter >> * Simple Syntax >> >> .(bak|ppu|ppw|o|so);*~;backup *.(compiled|rst|lrt|bak|ppu|ppw|o|so);*~;backup

... and that's why you must exclude a lot more files.

It works! Thank you!

Many roads lead to Rome.

Mattias

Reply by email

Csányi Pál
to Mattias Gärtner: Zitat von Cs????nyi P????l : No file has a mask. Your file has no extension. That's why…
Mattias G?rtner wrote 9 lines
> 'Use Include Filter': > > * Use Include Filter > * Simple Syntax > > .(pas|pp|inc|lfm|lpr|lrs|lpi|lpk|sh|xml|txt|po) This mask does not fit for lptinterface1. One solution: append: ,lptinterface1

.(pas|pp|inc|lfm|lpr|lrs|lpi|lpk|sh|xml|txt|po|lptinterface1)

This is the simplest solution. Thanks!

Reply by email