Archive for the ‘Uncategorized’ Category

going vertical on filenames

Thursday, May 17th, 2007

There are tricks worth knowing.

Even in textpad the only way to get a DOS filename to have no extension – not to be TXT – is to surround the filename in double quotes. Or save as a unix file. Then there are the protests of Windows Explorer when saving .anyrc files.

Had Windows required a file extension for every file, windoze might have become as marginal as the mac. No offense intended. Windows gave us “cd\” without the mandatory space character of “cd /”

Btw, the double-quote bit is essential if you are ever stuck using Ms Notepad

Now here’s the rub. Another little trick lets you put titles with a CRLF – mutli-line titles of your own choosing – on Windows desktop icons. But not in filenames.

Tangent to my point … Smalltalk folks sometimes get on a high-horse about types. It’s their hobbyhorse. As if the Symbol #-headed string is not as much a static types as you will ever need. And as much a worry if abused to the point of bloating. There is something to be said for software evolving to being typed as a prototype design evolves to a maintainable product. Optional typing is a feature in some powerful multi-paradigm languages.

Filenames are types. They even have evil proxy-types in the form of tilde-mangled 8.3 filenames. And they preclude the letters of my choosing as much as sets preclude dups and INT precludes a FLOAT.

But once is awhile I want a vertical filename

expect
libexpect

expectk

wish
blt

I remember the look which an IBM CUA-91 engineer from Boca gave me when I ventured my thoughts on 3-D widgets.

But if the SOM had survived in OS/3 we would not think twice about my having vertical filenames.

Now here is what an O-O desktop would give me on an O-O OS

That vertical filename would evolve as I reorganize the internal structure of that file on TCL Expect resources and related.

And its type is not ‘text’

Its type is

language

-resources and related

The closest thing that Windows offers, to my limited knowledge, is the virtual folder “My Documents”

But what of quote marks, quotation marks, if you will. This might be a useful type in and of itself.

If you have followed the Chronos project then you know that we have not yet put Date and Time to bed. But consider quotes.

PDF files will catch you with double-quotes-inverted and double-quotes-erect and you may not even notice. But there are languages where the opening quotes are not the ending quotes. I say this, entre-guimets, if you will.

The American-English QWERTY keyboard has its secrets for most American and Canadian users who type filenames. They may know that Microsoft is using tilde in mangled names but they themselves never reach up with the left pinky for the backtick key. These are not deep secrets, such as the left SH-key not being the same as the right SH-key or NUMPAD Enter not being the carriage return.

That the double quote on an electronic keyboard is not the single-quote sent twice may baffle digital archeologists in the year 5010.

The markup people know the answer. Have the keyboard send invisible markup codes with my every keystroke. The smart keyboard will ‘know’ whether I am typing in a text box or

You must be kidding. The keyboard – part of the OS ? Is this that Io mania?

But if the keyboard knew that the type that it was typing was a label on a desktop icon …

Imagination dead. Awful.

That’s for the keyboard which knows you are misquoting. Call it the Googleboard. The silent amanuesis. The foot-slogging pedagogue. We have crawled to the very lip on our brem.

and an IDE for Io again (almost) with Expect Tcl

Thursday, May 17th, 2007

One of my favorite places in L.A. is the JUG, that being the Los Angeles Java User Group.

It was there that I heard an excellent presentation on Ruby Rails by a young guru who never leaves the command line but whose rationale for Ruby and Rails was, well, just more Smalltalk. It was at the LA JUG that I heard all the reasons to stay with Smalltalk and Seaside from a Google hacker who was explaining the virtues of the Instantiations GWT kit. As I mistakenly said then,

I was not ready to gwt my day job

But it seems that the path of least resistance to an IDE for Io is not where I expected: it lies in TCL and the expect language.

But wait: is there an IDE for working with TCL while building this IDE for Io?

Let me back up a few steps … you must not diss the cmd line. The ssh command line is our shibboleth. Even as the CRT becomes the LCD, the CRT remains.

It is not enough to explain that whatever the internet was, it is now not accessed from the command line. It is safe to say that almost all internet activity from users begins with an icon, a link in an e-mail ( or, in my case, a link in a pane in OneNote ). But those are users.

There should be a lesson in Japan where it is not enough to have Chinese kanji, each with its Chinese pronunciation and meaning, they must also dup the whole thing and give each a Nihon pronunciation and meaning. And that is not enough. For a language as easy to pronounce as Italian and as easy to read in Romanji as German, there must be alternative alphabets in hiragana and katakana.

Now there are languages which are difficult: Turkish may be one, being even difficult to learn if you are born to it. But there is a limit. Consider only the alphabets proliferated in Sri Lanka. Enter Tcl. Or should I say,

Expect Tcl

Nothing should be as difficult as it now is to create a process under Windows. I will not bore you with it all now, but if you must have async communication and resource sharing between processes you may want to set aside the Win32 SDK and API. Even in Smalltalk.

Consider the admirable CommandShell project for Squeak Smalltalk. The best of this Tcl-ish business lies in the AttachableFileStream and the piped processes. Alas, those pipes are not for anyone inhaling through open Windows.

There was a time and an OS where I thought named pipes were the answer. And only a few hours ago I was thinking that for my needs, pipes would do. And then I was even driven to consider KERMIT.

and an aside.

Kermit is not gone; it has not croaked its last. While I do not remember when I last used kermit, I may have been mistaken to set it aside: kermit can be used to configure communication, either as C-kermit or G-kermit at die.de.

Because Io, the language, is readily embedded, building an IDE should not be an issue. But the IDE that I want must also serve trans and cecil and perhaps slate at the drop of a hat. Or a zip. Or a tar.

( to be continued )

And Tcl, as you may know, is in an active state. Literally. The Perl and Python people at activestate are also one of the centers for Tcl.

git python

Tuesday, May 15th, 2007

A funny thing happened on the way to the repository …

I had been unable to build the latest compressed Io sources on Win32 CYGWIN ( and so had to go for sources in the Io repository.)

But Io has moved off darcs to Linus Torvald’s git which you can right-click to save link at http://git.or.cz/.

To build git you must first make a configure file. And that will take autoconf.

Off to for that puppy. It built fine.

And now back at my git a

make configure

resulted in autoconf doing a GEN configure.

I was then able to run

./configure –prefix=/usr

for my git.

Here things got antsy. The git folks recommend that you make the docs, but it seems that somehow we have missed the dependency on

asciidoc

That was easily remedied at asciidoc

But here is the catch: asciidoc is going to require CYGWIN python

It is not enough to test your CYGWIN python install by running

python -V

to check the version. I suggest running

/bin/python2.5.exe -c ‘import sys; import time; print sys.path’

In my case the path to ‘lib-dynload’ and the python time module in time.dll just could not be found.

The first thing was to

unset PYTHONHOME

Then an

echo $PYTHONPATH

revealed the need to reset the comma-separated strings of a GNU PYTHONPATH

I used

PYTHONPATH=’/lib/python2.5′,’/lib/python2.5/lib-dynload’,$PYTHONPATH
export PYTHONPATH
/bin/python2.5.exe -c ‘import sys;import time; print sys.path’

Things looked better and now returning to git saw

make doc
make install-doc

run just fine.

And my tips for getting Io, the language, to build from git sources is sure to follow.

line edit history for Io, the language

Monday, May 14th, 2007

Since learning that Io would not play with stdin and stdout redirects in my Emacs or other shell alternatives, it has been so great to get a cmdline history into Io with rlwrap

Some gift in my CYGWIN configuration means that I could not find rlwrap after tar had unpacked the exe.

What is working is

~/usr/bin/rlwrap io.exe

Now the Io cmd line is able to find my last commands with the usual cmd line history keys.

As a ‘readline’ wrapper for languages with minimal frontends, this will be great!

rlwrap can be found at univie

I was unable to raise knoware.nl which may be its usual home.

You will need bzip2.exe to decompress the bz2 file.

Just run

bzip2.exe -d rlwrap-some-version.bz2

then move the rwrap-version.tar to the root of your cygwin install and go into bash to run

tar -xf rlwrap-some-version.bz2

Anvil WebServer and a Finnish mystery

Wednesday, May 9th, 2007

I cannot tell what has become of the Anvil project of Njet.

What I did do was to take a swipe at running their app server on my Win32 box. They offer an MSI install, so that should have been easy.

Before I was able to get a page served up without a 404, I had occasion to check what they had written to the registry ( which was fine ) and to discover that they must have kept some of the key bits in Finnish.

The instructions for server configuration were fine. But not a word on how to test. And no hint that they will be using a mangled URL.

The cause was easy enough to find: although they updated the registry to reflect my chosen install drive, they did not update the server configuration. Rather the same mindset that hard-coded 9090 as their chosen port.

So if you try ANVIL, be sure to grep the ./conf and /WEB-INF directories for files with values set to ‘Program Files’ if you install anywhere but c:\Program Files\Anvil 3.5

And once it is up and running, it looks rather interesting. While I had expected to go to http://localhost:9090/site/examples/index.html, I find myself instead at

http://localhost:9090/$np8uxhg3rm/examples/

And now back to finding out why ncurses will not build on cygwin … since PWIG won’t build either …