Re: [Jgeneral] Missing error messages and -O2?

2023-03-04 Thread 'Viktor Grigorov' via General
It is define. Oh, wait, my bad: I pass 2>&/dev/null to the command to surpress 
the one message on start-up, and if in this version all error messages go to 
stderr, which they seem to do, it's explained. All's fine and dandy in the 
universe again.



Mar 4, 2023, 22:16 by henryhr...@gmail.com:

> Even if eformat_j_ is undefined or fails, you should get the old terse 
> messages.
>
> Henry Rich
>
> On 3/4/2023 3:12 PM, 'Viktor Grigorov' via General wrote:
>
>> I updated to the official 941 and I'm getting no error messages. I'd had a 
>> eformat.ijs missing error, so I rm -r 'd the /usr/share/j/9sth/addons dir, 
>> and cp -r 'd the one in the zip thereto. No more messages, but also no error 
>> messages. My jsource clone, built yesterday, spits out errors messages for 
>> the same inputs, e.g. length errors for 1 2 * 1 2 3.
>>
>> How can diagnose it? Should I even, that is, should I stick with the source?
>>
>> Also, I noticed -O2 being passed to gcc for linux---how come not -O3?
>> --
>> For information about J forums see http://www.jsoftware.com/forums.htm
>>
>
> --
> For information about J forums see http://www.jsoftware.com/forums.htm
>

--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] Missing error messages and -O2?

2023-03-04 Thread Henry Rich
Even if eformat_j_ is undefined or fails, you should get the old terse 
messages.


Henry Rich

On 3/4/2023 3:12 PM, 'Viktor Grigorov' via General wrote:

I updated to the official 941 and I'm getting no error messages. I'd had a 
eformat.ijs missing error, so I rm -r 'd the /usr/share/j/9sth/addons dir, and 
cp -r 'd the one in the zip thereto. No more messages, but also no error 
messages. My jsource clone, built yesterday, spits out errors messages for the 
same inputs, e.g. length errors for 1 2 * 1 2 3.

How can diagnose it? Should I even, that is, should I stick with the source?

Also, I noticed -O2 being passed to gcc for linux---how come not -O3?
--
For information about J forums see http://www.jsoftware.com/forums.htm


--
For information about J forums see http://www.jsoftware.com/forums.htm


[Jgeneral] Missing error messages and -O2?

2023-03-04 Thread 'Viktor Grigorov' via General
I updated to the official 941 and I'm getting no error messages. I'd had a 
eformat.ijs missing error, so I rm -r 'd the /usr/share/j/9sth/addons dir, and 
cp -r 'd the one in the zip thereto. No more messages, but also no error 
messages. My jsource clone, built yesterday, spits out errors messages for the 
same inputs, e.g. length errors for 1 2 * 1 2 3.

How can diagnose it? Should I even, that is, should I stick with the source?

Also, I noticed -O2 being passed to gcc for linux---how come not -O3?
--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] Folders and Projects

2023-03-04 Thread Thomas Bulka
chris burke  writes:

>> Is it mandatory, that project directories are children of the
>> folders specified in UserFolders_j_? Or is it at least discouraged
>> to create a J project in an arbitrary
> directory which is not part of the folder hierarchy already known to J?
>
> You can create a project anywhere you like, but lose the benefit of
> Folders if your project is not under a Folder.
>
>> Or, to put it in another way: What is the recommended way to create
>> a J project in a directory outside of the
>> /home/user/j9.4-user/projects hierarchy?
>
> Create a Folder name for your directory (Edit|Configure|Folders).
> Restart J, then Project|New. Alternatively, just create a directory
> under your Folder and add an empty .jproj file with that name.

Hi Chris,

thank you very much for your comprehensive reply. I think, it now makes
sense to me!

Regards,

Thomas
--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] Folders and Projects

2023-03-04 Thread Raul Miller
Also you provide a mechanism to package projects as a single script.
That's one of the things which distinguishes a project directory from
some other directory.

--
Raul

On Sat, Mar 4, 2023 at 11:30 AM chris burke  wrote:
>
> Folders and Projects are just convenient ways to name and navigate
> through directories. This helps you organize your code, particularly
> when using Jqt. It also helps when sharing code with someone else who
> may use a different directory structure, since they need only define
> Folder names to match their directories, otherwise no change is needed
> to the source code.
>
> A Folder is a short name for a directory, and Project is a
> subdirectory of a Folder with a .jproj file. Typically you create a
> Folder for any new system, and Projects under that Folder for its
> various components.
>
> For example, on my machine
>
>jpath '~Sqlite'NB. a folder name
> /home/chris/dev/apps/sqlite/source
>
>dir jpath '~Sqlite/base'   NB. a project under that folder
> api.ijs   1947 27-Aug-18 12:29:08
> base.jproj 114 24-May-18 12:18:49
> build.ijs   50 30-Apr-18 07:42:27
> info.ijs   399 30-Apr-18 07:42:27
> ...
>
> The examples in the wiki should give you the idea.
>
> As regards your questions:
>
> > Is it mandatory, that project directories are children of the folders 
> > specified in UserFolders_j_? Or is it at least discouraged to create a J 
> > project in an arbitrary
> directory which is not part of the folder hierarchy already known to J?
>
> You can create a project anywhere you like, but lose the benefit of
> Folders if your project is not under a Folder.
>
> > Or, to put it in another way: What is the recommended way to create a J 
> > project in a directory outside of the /home/user/j9.4-user/projects 
> > hierarchy?
>
> Create a Folder name for your directory (Edit|Configure|Folders).
> Restart J, then Project|New. Alternatively, just create a directory
> under your Folder and add an empty .jproj file with that name.
>
> On Sat, Mar 4, 2023 at 4:32 AM Thomas Bulka
>  wrote:
> >
> > Hi Forum,
> >
> > I studied the guide about folders and projects in the wiki and it kind
> > of confused me
> > (https://code.jsoftware.com/wiki/Guides/Folders_and_Projects).
> >
> > It says "A project is a subdirectory of a folder that contains a file
> > with extension .jproj with the same name as the directory." Fine.
> >
> > Folders have been introduced together with the nouns SystemFolder_j_ and
> > UserFolders_j_ which J creates upon installation. Also fine.
> >
> > I'm not sure about the conclusion, though. Is it mandatory, that project
> > directories are children of the folders specified in UserFolders_j_? Or
> > is it at least discouraged to create a J project in an arbitrary
> > directory which is not part of the folder hierarchy already known to J?
> >
> > Or, to put it in another way: What is the recommended way to create a J
> > project in a directory outside of the /home/user/j9.4-user/projects
> > hierarchy?
> >
> > Sorry for this most likely trivial question, but somehow I'm not able to
> > figure out the connection between folders and directories.
> >
> > Thanks in advance!
> >
> > Regards,
> >
> > Thomas
> > --
> > For information about J forums see http://www.jsoftware.com/forums.htm
> --
> For information about J forums see http://www.jsoftware.com/forums.htm
--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] Folders and Projects

2023-03-04 Thread chris burke
Folders and Projects are just convenient ways to name and navigate
through directories. This helps you organize your code, particularly
when using Jqt. It also helps when sharing code with someone else who
may use a different directory structure, since they need only define
Folder names to match their directories, otherwise no change is needed
to the source code.

A Folder is a short name for a directory, and Project is a
subdirectory of a Folder with a .jproj file. Typically you create a
Folder for any new system, and Projects under that Folder for its
various components.

For example, on my machine

   jpath '~Sqlite'NB. a folder name
/home/chris/dev/apps/sqlite/source

   dir jpath '~Sqlite/base'   NB. a project under that folder
api.ijs   1947 27-Aug-18 12:29:08
base.jproj 114 24-May-18 12:18:49
build.ijs   50 30-Apr-18 07:42:27
info.ijs   399 30-Apr-18 07:42:27
...

The examples in the wiki should give you the idea.

As regards your questions:

> Is it mandatory, that project directories are children of the folders 
> specified in UserFolders_j_? Or is it at least discouraged to create a J 
> project in an arbitrary
directory which is not part of the folder hierarchy already known to J?

You can create a project anywhere you like, but lose the benefit of
Folders if your project is not under a Folder.

> Or, to put it in another way: What is the recommended way to create a J 
> project in a directory outside of the /home/user/j9.4-user/projects hierarchy?

Create a Folder name for your directory (Edit|Configure|Folders).
Restart J, then Project|New. Alternatively, just create a directory
under your Folder and add an empty .jproj file with that name.

On Sat, Mar 4, 2023 at 4:32 AM Thomas Bulka
 wrote:
>
> Hi Forum,
>
> I studied the guide about folders and projects in the wiki and it kind
> of confused me
> (https://code.jsoftware.com/wiki/Guides/Folders_and_Projects).
>
> It says "A project is a subdirectory of a folder that contains a file
> with extension .jproj with the same name as the directory." Fine.
>
> Folders have been introduced together with the nouns SystemFolder_j_ and
> UserFolders_j_ which J creates upon installation. Also fine.
>
> I'm not sure about the conclusion, though. Is it mandatory, that project
> directories are children of the folders specified in UserFolders_j_? Or
> is it at least discouraged to create a J project in an arbitrary
> directory which is not part of the folder hierarchy already known to J?
>
> Or, to put it in another way: What is the recommended way to create a J
> project in a directory outside of the /home/user/j9.4-user/projects
> hierarchy?
>
> Sorry for this most likely trivial question, but somehow I'm not able to
> figure out the connection between folders and directories.
>
> Thanks in advance!
>
> Regards,
>
> Thomas
> --
> For information about J forums see http://www.jsoftware.com/forums.htm
--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] Error during installation of J9.4

2023-03-04 Thread bill lam
You are correct. It should be 904. Mea culpa.

On Sat, 4 Mar 2023 at 10:19 PM Robin Niemeyer 
wrote:

>  I am running Linux Mint which is ubuntu/debian based.
>
> I got the error message:
> update-alternatives: priority must be an integer
> during installation of J9.4
>
> The command in install-usr.sh causing the message was:
> update-alternatives --install $BIN/ijconsole ijconsole $BIN/ijconsole-9.4
> 9.4
>
> The final parameter 9.4 should be an integer.
> Some standard way of converting between version number and an integer
> should be used.
> I used a three digit approach for myself:
>
> sudo update-alternatives --install /usr/bin/ijconsole ijconsole
> /usr/bin/ijconsole-9.4 940
>
> This way it would get a higher priority than 9.03 --> 903 where just using
> 94 would be a lower priority.
> --
> For information about J forums see http://www.jsoftware.com/forums.htm
>
--
For information about J forums see http://www.jsoftware.com/forums.htm


[Jgeneral] Error during installation of J9.4

2023-03-04 Thread Robin Niemeyer
 I am running Linux Mint which is ubuntu/debian based.

I got the error message:
update-alternatives: priority must be an integer
during installation of J9.4

The command in install-usr.sh causing the message was:
update-alternatives --install $BIN/ijconsole ijconsole $BIN/ijconsole-9.4
9.4

The final parameter 9.4 should be an integer.
Some standard way of converting between version number and an integer
should be used.
I used a three digit approach for myself:

sudo update-alternatives --install /usr/bin/ijconsole ijconsole
/usr/bin/ijconsole-9.4 940

This way it would get a higher priority than 9.03 --> 903 where just using
94 would be a lower priority.
--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] Folders and Projects

2023-03-04 Thread Raul Miller
That's an interesting question, and I guess it boils down to "how does
the interpreter locate relevant .jproj files"?

If I look at all of J's .ijs files for those which reference '.jproj'
one in particular stands out: stdlib.ijs

And, if I look at J's system/main/stdlib.ijs for how .jproj gets
referenced, I see:

ProjExt=: '.jproj'

and

p=. (, '/' , ProjExt ,~ spath) each subdirtree y

Studying these clues in stdlib.ijs, the names I see being used here are:

   FolderIds FolderTree getfolderdefs setfolder

And that's as far as it goes there. But they're also used in
system/util/project.ijs and presumably it's also possible to use an
absolute path to reference a project.

I see two verbs mentioned which presumably take a project reference --
when I look at 
https://code.jsoftware.com/wiki/Guides/Folders_and_Projects#Project_Verbs
-- but the single example there does not take advantage of the above
FolderTree (or FolderIds) structure. So, I would guess that the
enumeration of projects under system and user folders is mostly only
for the J IDE. In jqt, that would be the Project > Open menu option.
(And, in that Project menu, 'New' should probably be 'New...' and
'Open' should probably be 'Open...' as traditionally we put a trailing
ellipsis on menu options which bring up a dialog).

Or, to make a long story short: If you want to open a project from the
J IDE, you'll need to put it under a folder which J manages.

--
Raul

On Sat, Mar 4, 2023 at 7:32 AM Thomas Bulka
 wrote:
>
> Hi Forum,
>
> I studied the guide about folders and projects in the wiki and it kind
> of confused me
> (https://code.jsoftware.com/wiki/Guides/Folders_and_Projects).
>
> It says "A project is a subdirectory of a folder that contains a file
> with extension .jproj with the same name as the directory." Fine.
>
> Folders have been introduced together with the nouns SystemFolder_j_ and
> UserFolders_j_ which J creates upon installation. Also fine.
>
> I'm not sure about the conclusion, though. Is it mandatory, that project
> directories are children of the folders specified in UserFolders_j_? Or
> is it at least discouraged to create a J project in an arbitrary
> directory which is not part of the folder hierarchy already known to J?
>
> Or, to put it in another way: What is the recommended way to create a J
> project in a directory outside of the /home/user/j9.4-user/projects
> hierarchy?
>
> Sorry for this most likely trivial question, but somehow I'm not able to
> figure out the connection between folders and directories.
>
> Thanks in advance!
>
> Regards,
>
> Thomas
> --
> For information about J forums see http://www.jsoftware.com/forums.htm
--
For information about J forums see http://www.jsoftware.com/forums.htm


[Jgeneral] Folders and Projects

2023-03-04 Thread Thomas Bulka
Hi Forum,

I studied the guide about folders and projects in the wiki and it kind
of confused me
(https://code.jsoftware.com/wiki/Guides/Folders_and_Projects).

It says "A project is a subdirectory of a folder that contains a file
with extension .jproj with the same name as the directory." Fine.

Folders have been introduced together with the nouns SystemFolder_j_ and
UserFolders_j_ which J creates upon installation. Also fine.

I'm not sure about the conclusion, though. Is it mandatory, that project
directories are children of the folders specified in UserFolders_j_? Or
is it at least discouraged to create a J project in an arbitrary
directory which is not part of the folder hierarchy already known to J?

Or, to put it in another way: What is the recommended way to create a J
project in a directory outside of the /home/user/j9.4-user/projects
hierarchy?

Sorry for this most likely trivial question, but somehow I'm not able to
figure out the connection between folders and directories.

Thanks in advance!

Regards,

Thomas
--
For information about J forums see http://www.jsoftware.com/forums.htm