Solved how to bring the mocp background program to front ?

Dear all:
i have install moc music player in freebsd14.1. when i use mocp to play music. then, i type q , the mocp not close from freebsd14.1 system, just hide in backgroup . how to take it to front with some command ?
note : the mocp must use Q to close , not q . when i type q, the program hide in background . thanks.
 
What happens if you try running mocp again?
Dear richardtoohey2:
when i run mocp again will take mocp background program to front. but now, i want to use other command to manage the background program. and i have try jobs command , but nothing come back. i am new guy in freebsd, just want to know some command can do this job ? thanks.
 
I don't think this is anything to do with FreeBSD as such.

It is about how MOC works; I cannot see an obvious answer on the MOC website. It just says you can use q to detach and it says you can reattach again, but doesn't say how.

I do not understand your answer - are you saying there are now TWO instances of mocp running?
 
I don't think this is anything to do with FreeBSD as such.

It is about how MOC works; I cannot see an obvious answer on the MOC website. It just says you can use q to detach and it says you can reattach again, but doesn't say how.

I do not understand your answer - are you saying there are now TWO instances of mocp running?
Dear richardtoohey2:
i have running mocp in freebsd, when use q to detach it in background . how to use other command to take it to front ? not mocp again...thanks.
 
[…] just hide in backgroup . how to take it to front with some command ?
note : the mocp must use Q to close , not q . when i type q, the program hide in background . […]
  • mocp(1) is designed as a server/client program, both running on the same host.​
  • The TUI you usually see and use is the client. It talks to the server. ?​
  • The (user‑specific) server is automatically started once the user invokes mocp, its PID being stored at ~/.moc/pid.​
  • You can have as many clients as you want, even zero, the music keeps playing regardless. Pressing q terminates the client and only the client. You cannot “bring it back”, it’s gone. ?​
  • The last remaining mocp you see in a ps(1) listing is the server. If you want to terminate both the client and the server you press capital Q (implicitly terminating all other clients, too, since you can’t run no client without no server).​
  • Bottom line, as richardtoohey2 wrote, simply invoke mocp anew to regain control. This is the correct way, starting a new client. ?​
[…] i want to use other command to manage the background program. and i have try jobs command […]
For the shell’s job control ( jobs, fg %1, etc.) you need to send a SIGTSTP (terminal stop) signal, usually mapped to Control‑Z and recognized by almost all programs, including mocp(1). ?️​
 
Back
Top