Skip to content

Commit

Permalink
add lstat to Node.FS.Aff (#85)
Browse files Browse the repository at this point in the history
  • Loading branch information
artemisSystem authored Jun 23, 2024
1 parent 687a771 commit 93e65d5
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 0 deletions.
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@ Breaking changes:

New features:

- Add `lstat` to `Node.FS.Aff` (#85 by @artemisSystem)

Bugfixes:

Other improvements:
Expand Down
7 changes: 7 additions & 0 deletions src/Node/FS/Aff.purs
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ module Node.FS.Aff
, chown
, chmod
, stat
, lstat
, link
, symlink
, readlink
Expand Down Expand Up @@ -147,6 +148,12 @@ chmod = toAff2 A.chmod
stat :: FilePath -> Aff Stats
stat = toAff1 A.stat

-- | Gets file or symlink statistics. `lstat` is identical to `stat`, except
-- | that if the `FilePath` is a symbolic link, then the link itself is stat-ed,
-- | not the file that it refers to.
lstat :: FilePath -> Aff Stats
lstat = toAff1 A.lstat

-- |
-- | Creates a link to an existing file.
-- |
Expand Down

0 comments on commit 93e65d5

Please sign in to comment.