Take the 2-minute tour ×
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems.. It's 100% free, no registration required.

In my tmux.conf, I need to start a session with the name of the current user in capitals (this is actually a simplification but it will do as an example).

Imagine a fictitious line like this one, which is illegal:

new-session -n BananaWindow -s "$(echo "${USER}" | tr '[:lower:]' '[:upper:]')" 'bash -l'

How can I achieve what is intended above?

share|improve this question
    
I keep my config files in a common git repo and have been looking for a way to change tmux's behaviour based on an if $HOSTNAME‚Ķ statement of some kind, so I'd be interested in an answer to this, too. –  Iain Dawson Oct 5 '12 at 11:34
add comment

Know someone who can answer? Share a link to this question via email, Google+, Twitter, or Facebook.

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.