Skip to content

Commit

Permalink
terminfo: make macos the odd terminfo-relative-path
Browse files Browse the repository at this point in the history
  • Loading branch information
mrjbq7 committed Nov 14, 2024
1 parent c7a24e7 commit 232698b
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions extra/terminfo/terminfo.factor
Original file line number Diff line number Diff line change
Expand Up @@ -132,14 +132,12 @@ PRIVATE>

HOOK: terminfo-relative-path os ( name -- path )

M: windows terminfo-relative-path drop f ;
M: object terminfo-relative-path
[ first ] keep "%c/%s" sprintf ;

M: macos terminfo-relative-path
[ first >hex ] keep "%s/%s" sprintf ;

M: linux terminfo-relative-path
[ first ] keep "%c/%s" sprintf ;

: terminfo-path ( name -- path )
terminfo-relative-path terminfo-dirs [ swap append-path ] with map
[ file-exists? ] find nip ;
Expand Down

0 comments on commit 232698b

Please sign in to comment.