Since we are talking about help stuff, (in another thread)
Do we have any tool to convert documentation written in javadoc style
(those comments in the source code) to fpdoc xml? I like to write my
documentation as comments...
thanks
--
Felipe Monteiro de Carvalho
There seems to exist an issue with (output) redirection, when
I try to
run an external program from code. What I want to achieve is this:
In a Win32 console I can run
diff -r dir1 dir2 diff.txt
When I use e.g. Exec('diff', args), diff complains about an excess
argument, it works
Does there exist a simple way to run diff, and to redirect
its output
into an file? A batch file? Platform independence would be
nice, of course.
Start the shell instead of diff:
exec('cmd','/c diff -r dir1 dir2 diff.txt');
The /c tells the shell to execute the command
This is all windows though.
Cross platform solution:
Uses process
...
p:=TProcess.Create(nil);
{$IFDEF WIN32}
p.CommandLine := 'cmd /c diff -r dir1 dir2 diff.txt';
{$ENDIF}
{$IFDEF LINUX}
p.CommandLine := 'bash -c diff -r dir1 dir2 diff.txt';
{$ENDIF}
p.Execute;
...
Ludo
Andrew Haines schrieb:
The best way I know is described here:
http://wiki.lazarus.freepascal.org/Executing_External_Programs#How_to_redirect_output_with_TProcess
Thanks for the link, I didn't know before that redirecting is such a big
issue.
RunCommandAndDirectOutput('diff', '-r dir1
On 16 July 2011 22:37, Hans-Peter Diettrich drdiettri...@aol.com wrote:
Does there exist a simple way to run diff, and to redirect its output into
an file? A batch file? Platform independence would be nice, of course.
Execute diff with the two parameters via TProcess. Read the output as
Hi,
When I do a 'make clean' in my fpc trunk directory I get:
make[2]: Entering directory `/home/mattias/...fpc/packages/fcl-web'
./fpmake distclean ...
Invalid command-line argument at position 1: distclean
Usage: ...
The packages/fcl-web/fpmake is an old executable.
Is this normal?
What is
On 17 Jul 2011, at 11:40, Mattias Gaertner wrote:
When I do a 'make clean' in my fpc trunk directory I get:
make[2]: Entering directory `/home/mattias/...fpc/packages/fcl-web'
./fpmake distclean ...
Invalid command-line argument at position 1: distclean
Usage: ...
The
Ludo Brands wrote:
This is all windows though.
Cross platform solution:
Uses process
...
p:=TProcess.Create(nil);
{$IFDEF WIN32}
p.CommandLine := 'cmd /c diff -r dir1 dir2 diff.txt';
{$ENDIF}
{$IFDEF LINUX}
p.CommandLine := 'bash -c diff -r dir1 dir2 diff.txt';
{$ENDIF}
p.Execute;
On Sun, 17 Jul 2011 11:48:11 +0200
Jonas Maebe jonas.ma...@elis.ugent.be wrote:
On 17 Jul 2011, at 11:40, Mattias Gaertner wrote:
When I do a 'make clean' in my fpc trunk directory I get:
make[2]: Entering directory `/home/mattias/...fpc/packages/fcl-web'
./fpmake distclean ...
On 17.07.2011 08:08, Felipe Monteiro de Carvalho wrote:
Since we are talking about help stuff, (in another thread)
Do we have any tool to convert documentation written in javadoc style
(those comments in the source code) to fpdoc xml? I like to write my
documentation as comments...
I don't
Ludo Brands schrieb:
Start the shell instead of diff:
exec('cmd','/c diff -r dir1 dir2 diff.txt');
The /c tells the shell to execute the command and exit immediately.
Thanks, this comes close to what I had in mind :-)
But it looks quite platform dependent, like my other idea of invoking
Ludo Brands schrieb:
Cross platform solution:
Uses process
...
p:=TProcess.Create(nil);
{$IFDEF WIN32}
p.CommandLine := 'cmd /c diff -r dir1 dir2 diff.txt';
{$ENDIF}
{$IFDEF LINUX}
p.CommandLine := 'bash -c diff -r dir1 dir2 diff.txt';
{$ENDIF}
p.Execute;
Looks like this could be
Felipe Monteiro de Carvalho schrieb:
Since we are talking about help stuff, (in another thread)
Do we have any tool to convert documentation written in javadoc style
(those comments in the source code) to fpdoc xml? I like to write my
documentation as comments...
I've been working on PasDoc
On Sun, 17 Jul 2011, Felipe Monteiro de Carvalho wrote:
Since we are talking about help stuff, (in another thread)
Do we have any tool to convert documentation written in javadoc style
(those comments in the source code) to fpdoc xml? I like to write my
documentation as comments...
There
Cross platform solution:
Uses process
...
p:=TProcess.Create(nil);
{$IFDEF WIN32}
p.CommandLine := 'cmd /c diff -r dir1 dir2 diff.txt'; {$ENDIF}
{$IFDEF LINUX}
p.CommandLine := 'bash -c diff -r dir1 dir2 diff.txt';
{$ENDIF}
p.Execute;
Looks like this could be
Might be safer to refer to sh rather than bash in this context, since
Debian and Ubuntu are moving from Bash to Dash with sh being an
appropriate symlink.
For this simple example it won't matter but for more complex ones using
certain shell specifics it is a must to launch the correct
On 17 Jul 2011, at 13:32, Ludo Brands wrote:
For this simple example it won't matter but for more complex ones using
certain shell specifics it is a must to launch the correct shell. The sh
symlink can point to anything.
Yes, but bash may not even exist.
Jonas
On Sun, 17 Jul 2011 09:51:12 +, Mark Morgan Lloyd wrote about Re:
RE : RE : RE : [fpc-devel] Running programs with output redirection:
Ludo Brands wrote:
[snip]
{$IFDEF LINUX}
p.CommandLine := 'bash -c diff -r dir1 dir2 diff.txt';
{$ENDIF}
p.Execute;
Might be safer to refer to sh
On Sun, Jul 17, 2011 at 6:48 AM, Jonas Maebe jonas.ma...@elis.ugent.be wrote:
To be safe, you should always make distclean before updating from svn (even
without fpmake, since directories or units may get moved, which then won't be
cleaned anymore after the update). Now, for a while make
On 07/17/11 05:50, Hans-Peter Diettrich wrote:
Andrew Haines schrieb:
The best way I know is described here:
http://wiki.lazarus.freepascal.org/Executing_External_Programs#How_to_redirect_output_with_TProcess
Thanks for the link, I didn't know before that redirecting is such a big
issue.
On 17 Jul 2011, at 16:43, Marcos Douglas wrote:
On Sun, Jul 17, 2011 at 6:48 AM, Jonas Maebe jonas.ma...@elis.ugent.be
wrote:
To be safe, you should always make distclean before updating from svn (even
without fpmake, since directories or units may get moved, which then won't
be
On Sun, Jul 17, 2011 at 12:16 PM, Jonas Maebe jonas.ma...@elis.ugent.be wrote:
On 17 Jul 2011, at 16:43, Marcos Douglas wrote:
On Sun, Jul 17, 2011 at 6:48 AM, Jonas Maebe jonas.ma...@elis.ugent.be
wrote:
To be safe, you should always make distclean before updating from svn (even
without
On 17 Jul 2011, at 17:46, Marcos Douglas wrote:
I use fixes_2_4, not trunk. But what you said doesn't matter what
source we use, right?
I always used these scripts to compile:
On Sun, Jul 17, 2011 at 12:51 PM, Jonas Maebe jonas.ma...@elis.ugent.be wrote:
On 17 Jul 2011, at 17:46, Marcos Douglas wrote:
I use fixes_2_4, not trunk. But what you said doesn't matter what
source we use, right?
I always used these scripts to compile:
On 17 July 2011 12:28, Hans-Peter Diettrich drdiettri...@aol.com wrote:
I've been working on PasDoc for a while (PasDoc2), and ended up in adding
documentation in external files. But inline documentation makes sense in the
implementation section, which is not handled by PasDoc.
The tiOPF had
On 17 July 2011 12:38, Michael Van Canneyt wrote:
The entire purpose of fpdoc is not to have the documentation clutter up the
sources.
Especially true if you start adding images or diagrams (graphs, UML,
screenshots etc) inside your documentation too.
Documentation belongs outside the source
27 matches
Mail list logo