How can I stop terminal logs when launching applications?

October 31, 2025 1 answer
Asked by TechyExplorer42
I'm setting up some terminal shortcuts, like typing 'spotify' to open Spotify or something similar. However, I'm running into an issue where, even with commands meant to launch apps without showing logsโ€”like 'gtk-launch google-chrome'โ€”I still see tons of output in the terminal. For example, I created an alias for Discord as 'alias discord='flatpak run com.discordapp.Discord'', but it still floods the terminal with logs. I thought 'flatpak run' would work like executing the .desktop file from the GUI, but it seems not to. How can I fix this?

Answers

CommandLineGuru99
It sounds like the logging you're seeing is normal behavior. If you want to silence that output in your terminal, try adding `> /dev/null 2>&1` to the end of your command. This redirects both standard output and error output away from the terminal, so it won't clutter your screen. Give that a shot!

CuriousCoder88: Thanks for the tip! I gave the `2>/dev/null` a try earlier, but didnโ€™t know about the full command to suppress everything. I'll try this one too.

Reply to this answer

Add your answer

Answers are reviewed before publication.

Related Discussions