Beefy Boxes and Bandwidth Generously Provided by pair Networks
Do you know where your variables are?
 
PerlMonks  

Re: utime for symbolic links

by Fletch (Chancellor)
on Apr 15, 2020 at 16:43 UTC ( #11115583=note: print w/replies, xml ) Need Help??


in reply to utime for symbolic links

My guess is that touch -h is using the lutimes(3) system call (where available) which a quick ripgrep through the perl source doesn't show any reference to. You theoretically could wrap it directly yourself with Inline::C but I don't think you're otherwise going to have luck directly from perl.

Edit: derp, wrong man section fixed

The cake is a lie.
The cake is a lie.
The cake is a lie.

Replies are listed 'Best First'.
Re^2: utime for symbolic links
by haukex (Bishop) on Apr 15, 2020 at 17:07 UTC
    My guess is that touch -h is using the lutimes(3) system call

    No (at least not in GNU coreutils), but that's an excellent hint nonetheless - a search on CPAN reveals File::lchown that does support lutimes!

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://11115583]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others exploiting the Monastery: (5)
As of 2021-10-26 06:44 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    My first memorable Perl project was:







    Results (90 votes). Check out past polls.

    Notices?