linux – Why am I getting a “no such file or directory” error while trying to an FFmpeg audio recording?

I am on Arch Linux and attempting to record audio as it plays on my computer using ffmpeg and store it as a .flac file. I invoke the following command:

ffmpeg -f pulse -i default -c:a flac -compression_level 8 "~/path/to/target/directory/myRecording.flac"

At which point I get an Error opening output. It then lists the above target filename, followed by No such file or directory. I have verified that the target directory exists. I have tried using different sources identified via pactl, but nothing changes the error even though the directory I want to write to absolutely does exist.

Read more here: Source link