4 ms·
I have a linux PC that acts as a NAS/media player attached to the TV in the living room. I wrote a java-based "shortcut" program that runs on both the NAS and
by brokenmachine 4y ago
I have a linux PC that acts as a NAS/media player attached to the TV in the living room.
I wrote a java-based "shortcut" program that runs on both the NAS and my Windows desktop PC.
This is so when I'm ssh'd to the NAS, I can just run a command to open any folder on the NAS in my Windows PC, and vice versa.
Basically both ends open a network socket listening for commands to execute on either side.
I can also enqueue music stored on the NAS in Foobar2k on my Windows PC, or play videos in VLC.
So in the ssh window to the NAS, I just type, "locate -i *michael*jackson* | onlymusic | sc enqueue", and that will enqueue all Michael Jackson music on the server in Foobar2k on my Windows desktop. On the windows end, if there is more than one file then it creates a temporary m3u (or was it m3u8?) playlist and enqueues that, instead of sending a thousand separate enqueue requests.
"onlymusic" is a simple tool I made to filter to only files ending in flac, mp3, wav, etc. I have "onlyvideos" as well.
It's the exact same program running at both ends, but it detects which PC it's running on by what OS is there, because it has to convert the paths to the files between both PCs.
I also set up right-click shortcuts that go the other way - they will open a new tmux window in the ssh session on the NAS in a particular folder.
It's probably all horribly insecure and took me much longer to create than the time actually saved by using it...
But it serves my purposes, and I learnt a lot by setting it up.