Yazi v25.5.28

v25.5.28Desktop
Added 3
  • Directory size calculation in spotter folder preview computed dynamically in real time and asynchronously
  • piper.yazi plugin to use output of any shell command as preview content
  • Input component now supports password mode with obscure option
Changed 5
  • tab_active and tab_inactive configuration moved under new [tabs] section
  • Redesigned tab bar as standalone single-line component decoupled from header with tab titles displayed by default and mouse tab switching support
  • Sixel image preview performance improved 9x by replacing neural network quantization with Wu's Color Quantizer
  • Directory size calculation speed doubled by dividing tasks into chunks and reusing existing threads
  • Long filenames in file list and archive preview are now truncated with file extensions displayed at the end
Removed 2
  • tab_width configuration option has been removed
  • sixel_fraction configuration option has been removed
Deprecated 8
  • [manager] configuration section is deprecated in favor of [mgr]
  • ya.mgr_emit(), ya.app_emit() and ya.input_emit() functions are deprecated
  • ya.preview_widgets() function is deprecated
  • Command:args() method is deprecated
  • ya pack subcommand is deprecated
  • LEFT, CENTER, RIGHT alignment options on ui.Line and ui.Text are deprecated
  • NONE, TOP, RIGHT, BOTTOM, LEFT, ALL options on ui.Bar and ui.Border are deprecated
  • WRAP_NO, WRAP, WRAP_TRIM wrap options on ui.Text are deprecated
Breaking Changes
Deprecated
Redesign Tabs

https://github.com/sxyazi/yazi/pull/2745 decouples tabs from the header into an independent tab bar component to enhance UX:

  • A standalone single-line component increases the available space for displaying tabs.
  • Tab titles are displayed by default to increase recognizability.
  • Supports switching tabs via mouse for easier navigation.

The new tab bar is only shown when there is more than one tab, ensuring no space is wasted for users who don't use tabs.

https://github.com/user-attachments/assets/5ca33561-7558-4b9c-8b6a-9dfbc0bc8aa4

Calculate Real-Time Directory Size in Spotter

https://github.com/sxyazi/yazi/pull/2695 adds directory sizes to the folder spotter. The size is computed dynamically in real time and asynchronously, which means:

  • Every time a user clicks <Tab> on a directory, the latest size is calculated.
  • For large directories, real-time changes in size are reported to the user, with "(?)" appended at the end to indicate that the calculation is in progress.
  • If the user closes the spotter or switches directories using the left/right arrow keys, any ongoing calculations will be canceled to avoid wasting resources.

Also, the computed directory size will be updated in the file list:

  • If the user sets linemode = size, the latest size will be shown on the right of the file line.
  • If the user sets sort_by = size, the file list will be sorted by the latest sizes (if necessary).

https://github.com/user-attachments/assets/eb2981e6-3e02-4997-abfc-83cc456a1677

9x Faster Sixel Image Preview

https://github.com/sxyazi/yazi/pull/2707 replaces the existing neural network quantization algorithm with Wu's Color Quantizer, which offers better performance while maintaining comparable quality.

Old implementation (neural network via color_quant, with default sixel_fraction = 20) – average 189.5763999ms:

time: 190.025ms
time: 191.054417ms
time: 187.696792ms
time: 188.060791ms
time: 189.381958ms
time: 191.618042ms
time: 192.383125ms
time: 190.511291ms
time: 187.8395ms
time: 187.193083ms

New implementation (Wu - sRGB via quantette) – average 20.9199916ms:

time: 21.226458ms
time: 20.719542ms
time: 21.207583ms
time: 20.815875ms
time: 21.071291ms
time: 21.273459ms
time: 20.811792ms
time: 20.723166ms
time: 20.52675ms
time: 20.824ms
piper.yazi Plugin

With piper.yazi, you can use the output of any shell command as preview content. This eliminates the need to write a separate plugin for each command, making the use of custom previewers much more convenient.

screenshot-002418

See https://github.com/yazi-rs/plugins/tree/main/piper.yazi#examples for more examples!

Double Directory Size Calculation Speed

https://github.com/sxyazi/yazi/pull/2683 greatly improves directory computation performance by dividing the task into chunks and reusing existing threads. Directory sorting and file trashing will be observably twice as fast.

Run the benchmark script against a 10.16GB folder 5 times in release mode:

Old: elapsed 759.877791ms
New: elapsed 364.802583ms

Old: elapsed 734.5155ms
New: elapsed 360.103375ms

Old: elapsed 734.124167ms
New: elapsed 365.662458ms

Old: elapsed 733.27325ms
New: elapsed 365.694042ms

Old: elapsed 743.394875ms
New: elapsed 364.455083ms
Input Component Now Supports Password Mode

With https://github.com/sxyazi/yazi/pull/2675, a new obscure = true option is available:

local value = ya.input {
  title = "Password:",
  obscure = true,
  position = { "center", w = 50 },
}

https://github.com/user-attachments/assets/ff5b21f2-977b-4e9f-a279-e4cb15b51a57

Truncate Long Items in the File List

https://github.com/sxyazi/yazi/pull/2754, https://github.com/sxyazi/yazi/pull/2759, and https://github.com/sxyazi/yazi/pull/2778 add truncation support for long filenames in the file list and archive preview, and display file extensions at the end, ensuring that even if a filename is truncated, you can still know what file type it is by its extension.

https://github.com/user-attachments/assets/0f1afbdb-17ec-410f-adea-e8b1d2ed6341

types.yazi Plugin

For a long time, Yazi lacked a type definition file, which made plugin development very painful. Now, it's here!

types.yazi provides type definitions for Yazi's Lua API, empowering an efficient plugin development experience.

Improved Built-In Previewers
Improve Path Auto-Completion Results

The auto-completion results for interactive cd (key: g => <Space>) will now more closely match the user's input keywords.

Done in https://github.com/sxyazi/yazi/pull/2765

What's Changed
New Contributors

Full Changelog: https://github.com/sxyazi/yazi/compare/v25.4.8...v25.5.28

View original

Upgraded? How did it go?

Discussion