Putting all that together, I come up with

if. IFJ6 do. IFGTK =. -. IFJHS =. IFCONSOLE end.
if. IFGTK *. -. IFJHS do.
 code for grid
else.
 code for no grid
end.


I'll try that unless someone sees a problem.

Henry Rich

On 8/20/2012 7:55 PM, bill lam wrote:
I guess it is safe to assume shell script run under jconsole, or use
the verb isatty but which might not work under windows.

nouns for test environments,
jhs:  IFJHS

jconsole j602: IFCONSOLE
jconsole j701: IFGTK+:IFJHS

use IFJ6 to test for j602/j701


Пнд, 20 Авг 2012, Henry Rich писал(а):
You're right, that's not what I meant.

I mean, I want to put a test in lint.ijs to branch around the grid
code if jconsole, jhs or shell scripts are running.  I know I've seen
traffic here about variables that are set to indicate the operating
environment, but I don't even remember what to search for.  So: can
you tell me where to find the list of variables that describe the
environment; or, if it's not collected anywhere, can you tell me what
to test for to see if jconsole, jhs or shell scripts are running?

Henry Rich

On 8/20/2012 7:34 PM, bill lam wrote:
(I may mis-read your question)

test script for addons are run differently in j602 and j701, in
j602, it is the TESTFILE in project manager. In J701 it is the
run.ijs in the source folder.  You may checkout the tables/tara from
svn Public repo to see how it work.

Пнд, 20 Авг 2012, Henry Rich писал(а):
Sure, I could just return the table of lines in error.  What is the
best way to test for no grid?  Or better, can you point me to where
the test is documented?

Henry Rich

On 8/20/2012 7:04 PM, bill lam wrote:
Now it is ok.

On the lint itself, it depends on grid, this make it impossible to
run under jconsole, jhs or shell scripts.  Could the grid be
optional?

Пнд, 20 Авг 2012, Henry Rich писал(а):
OK, I've tried again, this time setting a property on the debug
folder, removing the files, and putting them back.  Somewhere along
the way there was a message 'manifest is invalid' but I haven't been
able to make it repeat.

Is it building properly, and are the properties correct?

[TortoiseSVN does not have a command-line tool to run SVN, but I
think the file properties are correct]

Henry Rich

On 8/19/2012 9:00 PM, bill lam wrote:
native eol is ok and should be the correct choice. What I observed
is that none of your files have propset. I've forgetten how
tortoisesvn work, Can you confirm by cd to the debug/lint folder and
type the svn command

svn pget svn:eol-style *

to see propset done or not?  If it prints nothing, then propset
has not yet done. Then you can type

Not sure how to check this with tortoisesvn.

Вск, 19 Авг 2012, Henry Rich писал(а):
I'm using TortoiseSVN.  I selected the /debug directory in addons,
right-clicked|TortoiseSVN|Settings; then push Edit under 'Set
configuration file', and added the lines:

*.ijs = svn:eol-style=native
*.jproj = svn:eol-style=LF
*.ijp = svn:eol-style=LF
*.ijt = svn:eol-style=LF
*.txt = svn:eol-style=LF
*.htm = svn:eol-style=LF
*.html = svn:eol-style=LF


Hey, wait a minute, I didn't fix the line for *.ijs.  It should be LF
too, like

*.ijs = svn:eol-style=LF


OK, I've made that change now, & I have re-put the files.  Is the
CRLF right now?  If not, what was wrong with the above?

Henry Rich

On 8/19/2012 8:18 PM, bill lam wrote:
I checkout it with both git and svn, but all of your files are still
using CRLF. I checked your file did not propset eol-style.  Which
svn client do you use?  How did you force files commit using LF?

Вск, 19 Авг 2012, Henry Rich писал(а):
I have made lint into an addon with its own directory.  It seems to
be there for J602, and, according to the log, for J701 as well.  I
fixed a couple of bugs in it too.

I ran it on a program that had been in production for years and it
found an undefined-variable path that had never been seen in practice
- but was about to, in about a week.  Just-in-time programming!

I tried fiddling with my SVN config to cause it to use LF
termination; if anyone with *nix can verify that it worked I'd be
obliged.

Henry Rich

On 8/17/2012 1:18 AM, Ian Clark wrote:
Thanks, Ric.
I was unaware of that about /misc/ and might have fallen foul of it myself.

On Fri, Aug 17, 2012 at 6:09 AM, Ric Sherlock <[email protected]> wrote:
Just to expand on Bill's message. The <addoncategory>/misc folders are
treated differently from other addons. Whereas other addons have a
manifest.ijs that lets the author specify which platforms and versions to
target, the misc addons currently only get built for a single version. This
is currently 7.
  On Aug 17, 2012 3:28 PM, "bill lam" <[email protected]> wrote:

That addons is j7 specific.  If the file was add to other folders, J602
might have a chance to see it.

Птн, 17 Авг 2012, Ian Clark писал(а):
It doesn't seem to be there on j602.

On Thu, Aug 16, 2012 at 9:42 PM, Henry Rich <[email protected]>
wrote:
I have tested it only on J6.02.

Henry Rich


On 8/16/2012 9:51 AM, Ian Clark wrote:

Is lint.ijs going to be available in j602 also?

Package Manager lets me download it for JGTK. I've tried running it
under j602 and it seems to work with the example I've tried, so there
can't be any major j7 dependencies.

On Mon, Aug 13, 2012 at 4:47 AM, Henry Rich <[email protected]>
wrote:

Yes, I created a directory and then realized it would go as a single
file
in
/misc, and deleted the /lint directory.

Henry Rich


On 8/12/2012 11:45 PM, Ric Sherlock wrote:


I think it was initially committed to addons/general/lint/lint.ijs
and
then subsequently moved? to addons/general/misc/lint.ijs  I can see
it
there at the moment using WebSVN.

There are a couple of other things regarding WebSVN that would be
nice...
     a) can we get the RSS enabled (makes it easier to keep up with
changes)
     b) the Ctrl+F1 functionality in GtkIDE that opened the
appropriate
source file using Trac, doesn't work correctly with WebSVN yet. For
example trying to get help on freads attempts to open this URL:


http://www.jsoftware.com/wsvn/base7/browser/trunk/main/main/files.ijs

instead of this one:

http://www.jsoftware.com/wsvn/system7/trunk/main/main/files.ijs

On Mon, Aug 13, 2012 at 3:36 PM, chris burke <[email protected]>
wrote:


lint.ijs is not in addons/general/misc. Did you commit your
changes?

AFAIK, JAL is working fine...

On Mon, Aug 13, 2012 at 10:10 AM, bill lam <[email protected]>
wrote:

There are some problem with JAL build script perhaps related to
the
recent relocation of server to amazon.  I think Chris will fix it.

Вск, 12 Авг 2012, Henry Rich писал(а):


I don't know what has to happen to make it show up in Package
Manager. Bill would.  Maybe some rebuild is required.

Perhaps you can check it out using SVN?

Henry Rich

On 8/12/2012 6:12 PM, Ian Clark wrote:


Sounds good, Henry. I certainly have a use for that.

But I can't see it in pacman for either JGTK or j602.

On Sun, Aug 12, 2012 at 9:10 PM, Henry Rich <
[email protected]>


wrote:


I have an alpha-test version of a syntax checker for J
scripts.  It
is


in


the addons, as

general/misc/lint.ijs

The goal is to catch errors before execution.  It can find only
gross
errors, but those are the kind my programming students make, so
this
is
progress IMO.  What it looks for is:

    explicit definitions lacking trailing ), and ) with no
definition
    undefined names, including names not defined in all paths
    verbs used with invalid valences
    non-noun results at the end of condition blocks and verbs
    syntax errors
    sentences with no effect on execution (eg verb verb)

The idea is that lint can be used in place of load.  It loads
the


script,


then checks it for errors by executing each line of each
explicit


definition


in 'safe mode' where side effects are prevented.

example:

lint '~addons/general/misc/lint.ijs'

The result of the verb is a table of (line number);(error
message).
If there are errors, it brings up a grid showing the program
and
error
messages.

I would test this a lot more before releasing it, but school
starts


tomorrow


& I'm not going to have much more time to put on it.  I think
it's


better


than nothing - not freshman-proof, but I'll fix that as the
freshmen


tear


into it.  Meanwhile I would appreciate suggestions and bug
reports.

(My thanks to Dan King who suggested this project at the J
Conference


in


response to my bellyaching about J's error-detection
deficiencies)

Henry Rich



----------------------------------------------------------------------
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



--
regards,
====================================================
GPG key 1024D/4434BAB3 2008-08-24
gpg --keyserver subkeys.pgp.net --recv-keys 4434BAB3

----------------------------------------------------------------------
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


----------------------------------------------------------------------
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
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm

--
regards,
====================================================
GPG key 1024D/4434BAB3 2008-08-24
gpg --keyserver subkeys.pgp.net --recv-keys 4434BAB3
----------------------------------------------------------------------
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

----------------------------------------------------------------------
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

----------------------------------------------------------------------
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

Reply via email to