Nikita Karetnikov <nik...@karetnikov.org> skribis:

>>> +    (copy-file prog prog-real)
>
>> You lack a (chmod prog-real #o755), I think.
>
> Are you sure?
>
> If 'prog' is an executable, 'prog-real' will be an executable too.
>
> scheme@(guile-user)> (open-file "foo" "w")
> $1 = #<output: foo 9>
> scheme@(guile-user)> (chmod "foo" #o755)
> scheme@(guile-user)> (copy-file "foo" "bar")
> scheme@(guile-user)> (format #f "~o" (stat:perms (stat "bar")))
> $2 = "755"

Oh you’re right (I thought permissions were not preserved.)

So you can go ahead.  Sorry for the noise!

Ludo’.

Reply via email to