Lazarus

Using the Lazarus IDE => General => Topic started by: bonmario on May 09, 2021, 07:41:01 am

Title: Bug in "startlazarus" ?
Post by: bonmario on May 09, 2021, 07:41:01 am
Hi,
if i use this command
Code: Pascal  [Select][+][-]
  1. /usr/share/lazarus/default/lazarus /media/DiscoC/MyDir/MyProject.lpr
it starts lazarus and open my project

but if i use this command
Code: Pascal  [Select][+][-]
  1. /usr/share/lazarus/default/startlazarus /media/DiscoC/MyDir/MyProject.lpr
it only starts lazarus

It's correct or it's a bug?
I seem to remember that in the past "startlazarus" also opened the project received as a parameter.

Thanks, Mario
Title: Re: Bug in "startlazarus" ?
Post by: Bart on May 09, 2021, 10:06:52 am
Which Lazarus version?
starlazarus is supposed to pass commandline parameters to lazarus.

Bart
Title: Re: Bug in "startlazarus" ?
Post by: bonmario on May 09, 2021, 11:07:19 am
Sorry, you're right.
Thisi is my version: Lazarus 2.1.0 r65078M FPC 3.2.0 x86_64-linux-gtk2

The same also in Windows

Hi, Mario
Title: Re: Bug in "startlazarus" ?
Post by: Bart on May 09, 2021, 11:32:04 am
Maybe report this on the bugtracker?

In starlazarus.lpr there are these lines:
Code: Pascal  [Select][+][-]
  1.             // if there is a lazarus instance accepting files, pass files to that
  2.             LazIDEInstances.PerformCheck;

So one might think that is is supposed to work.

Bart
Title: Re: Bug in "startlazarus" ?
Post by: Bart on May 09, 2021, 11:55:56 am
On windows for me this works as expected b.t.w.
Both commands open the same project.
(After the first I opende another project and closed Lazarus)
Code: [Select]
C:\devel\lazarus>lazarus c:\Users\Bart\LazarusProjecten\eplus\eplus.lpi

C:\devel\lazarus>startlazarus c:\Users\Bart\LazarusProjecten\eplus\eplus.lpi

Lazarus 2.1.0 r64844 FPC 3.2.2 i386-win32-win32/win64

Bart
Title: Re: Bug in "startlazarus" ?
Post by: lucamar on May 09, 2021, 01:48:10 pm
In Linux, at least, starting with v2.0.12 startlazarus doesn't pass the file name and one has to call lazarus-ide directly. I noticed this when a small tool I use to open projects stopped working.

What I don't remember is whether there was a bug report about it  :-[
Title: Re: Bug in "startlazarus" ?
Post by: trev on May 09, 2021, 02:07:08 pm
What I don't remember is whether there was a bug report about it  :-[

The only open issue for startlazarus seems to be https://bugs.freepascal.org/view.php?id=37034
TinyPortal © 2005-2018