oh-my-fish / theme-budspencer

A theme for nerds, makes fish even more powerful. It's equipped with a hell of a lot of nice functions and key bindings to speed up your workflow.
MIT License
107 stars 41 forks source link

System beep after certain commands #10

Closed predmijat closed 4 years ago

predmijat commented 8 years ago

Hey,

I don't know if this is desired behavior or not, but I can hear system beep after commands like ls, touch, cat, cp, rm, maybe some others...there is no beep on cd though. I've test both with and without my custom (before).init.fish, and result is the same. I don't experience this with default theme, nor with "agnoster" theme which I've also used.

Should it be like that? If yes, how do I turn it off? If not, how can I debug it?

Thanks!

bpinto commented 8 years ago

I wonder if somewhere we are doing this: echo -e "\a" which would make a beep sound.

bpinto commented 8 years ago

Lol, look what I found: https://github.com/oh-my-fish/theme-budspencer/blob/master/fish_prompt.fish#L226

@predmijat Could you remove this line and see if the beep stops?

predmijat commented 8 years ago

Yup, that fixes it...nice find :)

bpinto commented 8 years ago

I don't know why it was added though. :D

bobthecow commented 8 years ago

It was introduced in 4e6a213eaf069eb21a3e4baadf70b1ef05e3124c … looks like debugging output that snuck in? @tannhuber?

bobthecow commented 8 years ago

Or maybe :trollface:

tannhuber commented 8 years ago

This is desired behaviour. I use the visual bell to set the X11 urgency hint flag. The window manager then tells me when a time consuming job has finished.

Example from my daily life: I'm doing data analysis with a R-script. This might take some hours. The job runs in a workspace for time consuming jobs. The status bar tells me there's something running in the last workspace (blue sand glass symbol). scrot-2015-11-03-205521

When the job is done, the urgency hint flag is set. The sand glass becomes red. scrot-2015-11-03-205821

The same happens with the window title bar. 2015-11-03-210946_1366x768_scrot

There's even a shortcut to quickly jump to a window with an urgency hint flag. I don't want to miss that feature anymore. It's very useful.

I didn't know that there're still people that haven't deactivated the acoustic beep.

predmijat commented 8 years ago

I actually thought that it might be something like that, but I wanted to be sure that it's not some function or whetever which can't work because of x and instead just sends a beep :) I'll close it, thanks for the explanation!

tannhuber commented 8 years ago

Probably, most people don't know about the urgency hint flag although it's an ICCCM standard feature. So, it might be a good idea to make it configurable. Let's reopen the issue until it's implemented as an option.

tannhuber commented 8 years ago

Done. set -U budspencer_nobell should switch the bell off.

bobthecow commented 8 years ago

@tannhuber We've started making theme configuration names a bit more generic in the hopes that more options will become portable across themes. The convention is to use a theme_ prefix. Let's use that for this option as well?

bpinto commented 8 years ago

I am jealous of your terminal @tannhuber I want that statusbar!!!

tannhuber commented 8 years ago

@bobthecow Good to know. I agree, it's a good idea to change these lines. As a reminder, I'd like to reopen the issue again. I'll check how it's done in bobthefish theme.

@bpinto The statusbar is dzen2. I'm not sure if it's a good choice for you. It's crucial to be a nerd in order to use it. ;-)

loganintech commented 8 years ago

This still happens for me and I don't know how to fix it.

clayauld commented 4 years ago

Please read the README for the repo. To turn off the terminal bell, add this to your init.fish

set -U budspencer_nobell