openbiblio.social is one of the many independent Mastodon servers you can use to participate in the fediverse.
Der Einstieg in das Fediverse für Bibliotheksmenschen

Administered by:

Server stats:

660
active users

#p

2 posts2 participants1 post today
Replied in thread

@sigue

The annoying thing is, obviously CLSIP goes out of it's way to add this version in the first place. (ext:default-directory) probably [need to check] calls getcwd(3) at some place and this returns a string. And naively converting this string gives us

[5]> (describe (pathname "/tmp/"))

#P"/tmp/" is a pathname, with the following components:
DIRECTORY = (:ABSOLUTE "tmp")

Calling @scream for an opinion here.

Replied in thread

@sigue

In SBLC (for comparison):

* (defvar p (make-pathname :directory '(:absolute "tmp") :version :newest))
P
* (describe p)
#P"/tmp/"
[pathname]

HOST = #<SB-IMPL::UNIX-HOST {100000D633}>
DIRECTORY = (:ABSOLUTE "tmp")
VERSION = :NEWEST
* (describe (make-pathname :defaults p :version nil))
#P"/tmp/"
[pathname]

HOST = #<SB-IMPL::UNIX-HOST {100000D633}>
DIRECTORY = (:ABSOLUTE "tmp")
*

#common-lisp #scbl

Replied in thread

@sigue

Now, how do I remove the version from a pathname. In CLISP:

[1]> (defvar p (make-pathname :directory '(:absolute "tmp") :version :newest))
P
[2]> (describe p)

#P"/tmp/" is a pathname, with the following components:
DIRECTORY = (:ABSOLUTE "tmp")
VERSION = :NEWEST

[3]> (describe (make-pathname :defaults p :version nil))

#P"/tmp/" is a pathname, with the following components:
DIRECTORY = (:ABSOLUTE "tmp")
VERSION = :NEWEST

Is that even legal?

#common-lisp #clisp

Replied to sigue

@sigue

Thanks for pointing me to DESCRIBE. I somehow vaguely remembered that something like this existed, but couldn't find it again.

Now, the plot thickens:

[5]> (describe #P"/tmp/")

#P"/tmp/" is a pathname, with the following components:
DIRECTORY = (:ABSOLUTE "tmp")

(I assume you meant #P"/tmp/")

[4]> (describe (ext:default-directory))

#P"/tmp/" is a pathname, with the following components:
DIRECTORY = (:ABSOLUTE "tmp")
VERSION = :NEWEST

I'll have to think how to change this, but the likely thing is, to wrap uiop:getcwd (which for CLISP uses ext:default-directory underneath) and remove :VERSION. I am wrapping getcwd anyway (because some lisp implementation return strings instead of pathnames), so I only have to special case CLISP.

Replied in thread

@SDF Wow, I have very fond memories of this machine as it was the first instance of netmbx, our public access Unix system that was later running on a Xenix box. It had a couple of dialin modems connected to it and polled tub aka db0tui6 using UUCP

#N netmbx
#S Altos 68000; Unix SysIII
#O netmbx Berlin
#C Ralf Moritz †
#E mor...@netmbx.uucp
#T +49 30 87 81 24
#P Woerther Str. 36, D-1000 Berlin 20, W. Germany
#L 52 31 N / 13 24 E city
#R
#W mor...@netmbx.uucp; 870530
#
netmbx tub(DAILY)