tmux-plugins / tmux-net-speed Goto Github PK
View Code? Open in Web Editor NEWThis project forked from beeryardtech/tmux-net-speed
Tmux plugin to monitor upload and download speed of one or all interfaces
License: MIT License
This project forked from beeryardtech/tmux-net-speed
Tmux plugin to monitor upload and download speed of one or all interfaces
License: MIT License
Awesome little plugin! Is it possible to format the net_speed output string to something like U: 0.2 MB/s D: 10.4 MB/s
and keep it at this unit? I'd like to get a uniform look without it jumping around between KB/s, MB/s and B/s
After using tmux for a while (uptime 229 days), I started getting errors saying tmux has too many files open. The exact error message happens when I tried to create a new window via <prefix> c
and the error is Create window failed: fork failed: Too many open files
.
I used htop
to investigate and it looks like many, many instance of the tmux-net-speed
are running.
As you can see from this screnshot, I only have 10 windows open, but much more than 10 instances of the plugin running. Ideally, I'd expect 1 instance of the plugin running and its results shared across all of the windows, but even if it created one instance per window, I'd only expect to see 10 instances. But ps aux | grep tmux-net-speed | wc -l
tells me there's 537
instances running.
If it helps, here's my ~/.tmux.conf file:
# Enabled plugins:
set -g @plugin 'tmux-plugins/tpm' # tmux Plugin Manager; autodownloads and installs any plugins you list here.
set -g @plugin 'tmux-plugins/tmux-sensible' # Sensible defaults for tmux according to the community.
set -g @plugin 'tmux-plugins/tmux-cpu' # Shows CPU status. Specifically, introduces variables like #{cpu_percentage} for use with `status-right`.
set -g @plugin 'tmux-plugins/tmux-net-speed' # Shows network speed. Specifically, introduces variables like #{net_speed} for use with `status-right`.
set -g @plugin 'tmux-plugins/tmux-prefix-highlight' # Shows when you've hit the tmux prefix. Specifically, introduces the variable #{prefix_highlight} for use with `status-right`.
set -g @plugin 'tmux-plugins/tmux-sidebar' # Shows file listings as a sidebar. Invoke with <prefix> <tab>
set -g @plugin 'tmux-plugins/tmux-resurrect' # Allows you save and restore tmux environments (e.g. if you need to reboot). Invoke with <prefix> <Ctrl+S> and <prefix> <Ctrl+R>
# tmux-sidebar config (depends on `tree` being installed)
set -g @sidebar-tree-command 'tree -lL 2 -hDF -c -C' # See `man tree` for full explanation. TL;DR: follow symbolic links, max depth 2; show size, last changed date, an an indicator for directory/socket/executable/etc.; sort by recently changed; colorize
set -g @sidebar-tree-width '60' # Because we added so much info, make the default width a bit wider.
# What to show in the bottom right corner (depends on tmux-cpu, tmux-net-speed, tmux-prefix-highlight)
set -g status-right-length 75 # 50 < perfect < 75
set -g @prefix_highlight_show_copy_mode 'on' # Show when copy mode is on.
set -g @prefix_highlight_show_sync_mode 'on' # Show when sync mode is on.
set -g @net_speed_format "D:%7s U:%7s" # Default string format is too wide IMHO.
set -g status-right '#{prefix_highlight} #{cpu_bg_color}CPU: #{cpu_icon} #{cpu_percentage} #{ram_bg_color}RAM: #{ram_icon} #{ram_percentage} #[bg=green]| #{net_speed} | %a %h-%d %H:%M'
# Initialize TMUX plugin manager (keep this line at the very bottom of tmux.conf)
run -b '~/.tmux/plugins/tpm/tpm'
If network bond is set up (e.g. LACP), traffic is counted twice, once for master and again for slave.
This is a feature request to support Mac OSX. There is no directory and no network interfaces list at /sys/class/net/
. I'm not sure what the best tool for Mac would be.
Perhaps display a warning if no network interfaces are found here as well.
Thanks in advance for the consideration, it would be a very useful tool.
it just shows 0 in my status bar
when I run ./run_test.sh
it meet error: en0 eth0 wlan0 should .........bla bla
How can I fix this ?
Need to apply tmux-plugins/tmux-battery@7def624 to this repo as well.
I wanted to hide zero value "0 B/s", conditions are supported.
readonly show_speed="#{?#{!=:#{download_speed},0 B/s},#{download_speed},}"
Problem is, that do_interpolation()
expands only first #{download_speed}
Please do global variable expanding
result=${input//$download_interpolation/$download_speed}
vs
result=${input/$download_interpolation/$download_speed}
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.