Zsh 1liner: Remove slashes from front & rear
Code:
local HEHE='/wee/oo/'
echo "${"${HEHE%/}"#/}"
Outputs:
wee/oo
Written by Joel Kuzmarski
Related protips
Have a fresh tip? Share with Coderwall community!
Post
Post a tip
Best
#Zsh
Authors
Sponsored by #native_company# — Learn More
#native_title#
#native_desc#