lsd-rs / lsd-rs/lsd

refactoring `src/theme/icons.rs`

Open
#821 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

kind/enhancement
Dominant language
Rust
Stars
16.2k
Forks
510
PR merge metrics
No merged PRs in 30d

Description

Directly using emojis

https://github.com/lsd-rs/lsd/blob/ea56a7c385db4d4e67992d2d13de94ebc2a97234/src/theme/icon.rs#L41-L56

would it be useful to directly use emoji?

impl Default for ByType {
    fn default() -> ByType {
        ByType {
            dir: "".into(),          // 
            file: "".into(),         // 
            pipe: "".into(),         // 
            socket: "".into(),       // 
            executable: "".into(),   // 
            symlink_dir: "".into(),  // 
            symlink_file: "".into(), // 
            device_char: "".into(),  // 
            device_block: "ﰩ".into(), // ﰩ
            special: "".into(),      // 
        }
    }
}

Compiletime Hashset

https://github.com/lsd-rs/lsd/blob/ea56a7c385db4d4e67992d2d13de94ebc2a97234/src/theme/icon.rs#L99-L101

using phf set could help with storing duplicate default values

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by checking the linked ranges in src/theme/icon.rs; the issue title refers to src/theme/icons.rs, so resolve that path discrepancy first. Clarify whether the goal is direct emoji defaults, a compile-time phf set, or both, then verify the chosen refactor preserves the default icon values and duplicate handling.

Written by the indexing model from the issue text.

Assessment

Tech stack
rust
Domain
cli
Issue type
Refactor
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.