Skip to content

A utilitarian, horizontal-space-saving oh-my-zsh theme that shows your IP, even on Termux

License

Notifications You must be signed in to change notification settings

swomf/netmask-zsh-theme

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

20 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Netmask theme

A non-intrusive, Termux-first utilitarian theme for oh-my-zsh.

  • IPv4 address
    • Cross-platform: uses own implementation via C stdlib to avoid ifconfig/ip addr/Termux permission inconsistencies
  • Full directory structure
  • Git branch and status
  • Virtual environment
  • Support for the new high-speed async prompt

Netmask theme preview

Tested on rootless Android 13+ Termux and various desktop glibc Linux distributions.

Installation

git clone https://github.com/swomf/netmask-zsh-theme
cd netmask-zsh-theme
make config # Recommended. May not be necessary.
make && make install
# if necessary, use `sudo -E make install` instead.

Why make config?

By default, the theme will print the first network interface that starts with wl (e.g. wlan0, wlp3s0). However, some may prefer to explicitly define their wanted interface, or change it to tun0 or something else.

Run make help for more information.

Roadmap

  • Improve installation process when using sudo
    • sudo -E is sometimes needed because the presence of ohmyzsh is detected in the project Makefile via the $ZSH env var; this may not be defined in /root/.zshrc for system-wide ohmyzsh installations.
  • Test on non-glibc systems
    • macOS (Apple C Library)
    • *BSD (libc)
    • Alpine Linux/Void Linux (musl)
    • MinGW-w64 (msvcrt)

Inspiration

No code was reused.

About

A utilitarian, horizontal-space-saving oh-my-zsh theme that shows your IP, even on Termux

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published