# Add \`PathExt\` trait \(\#2823\) · gitcafe/zed

[View on GitCafe](https://git.cafe/gitcafe/zed/commit/ee1b4a52cc41cb7c331ad9936f1c1cbfb220057e)

Repository: [gitcafe/zed](https://git.cafe/gitcafe/zed)

Visibility: public

Requested revision: ee1b4a52cc41cb7c331ad9936f1c1cbfb220057e

Requested commit: ee1b4a52cc41cb7c331ad9936f1c1cbfb220057e

Commit: ee1b4a52cc41cb7c331ad9936f1c1cbfb220057e

Tree: 2c80a5378e3498f5ca455ea519a23c8df66e0d52

Author: Joseph T\. Lyons

Committer: GitHub

## Message

```
Add `PathExt` trait (#2823)

This PR adds a `PathExt` trait. It pulls in our existing `compact()`
function, as a method, and then adds a method, and testing, for
`icon_suffix()`. A test was added to fix:

- https://github.com/zed-industries/community/issues/1877

Release Notes:

- Fixed a bug where file icons would not be registered for files with
with `.` characters in their name
([#1877](https://github.com/zed-industries/community/issues/1877)).
```

## Parents

- [ad4fd7619b9d8e920758b681c2410ba1b55947e9](https://git.cafe/gitcafe/zed/commit/ad4fd7619b9d8e920758b681c2410ba1b55947e9?format=markdown)

[Source at this commit](https://git.cafe/gitcafe/zed/tree/ee1b4a52cc41cb7c331ad9936f1c1cbfb220057e?format=markdown)
