Bash Script For Listening To Online Radio

  Рет қаралды 16,112

DistroTube

DistroTube

Күн бұрын

Пікірлер: 50
@DistroTube
@DistroTube 2 жыл бұрын
Typically, I like to do these "quick and dirty" scripts just to show you guys how to solve a problem. Obviously, the code can be improved and/or cleaned up a bit. You guys had a lot of good suggestions! I took some of the advice given and have made some changes. The radio station list is now an associative array in the dmscripts config file (a file that gets sourced for all the dmscripts). I swapped out 'dunstify' for 'notify-send' for better compatibility. And the case statement now only includes two options.
@bigmikeobama5314
@bigmikeobama5314 2 жыл бұрын
give em the D.....menu! love your content. the channel "switched to linux" got me to switch to linux (linux mint lmde) but your channel got me to switch to an arch based distro (garuda) love the open source community and your channel keep up the great work please sir!
@taylor85345
@taylor85345 2 жыл бұрын
Hey DT! I'd been toying with writing a script just like this for a while, so your video was very timely and looking over the script helped me figure out some better ways to leverage dmenu. Glad my PR was up to snuff!
@sirrobertdowneysenior8080
@sirrobertdowneysenior8080 2 жыл бұрын
Worth being a main GUI app on all major platforms
@MrLeoStief
@MrLeoStief 2 жыл бұрын
Nice! You got a lot of code duplication in there, though. I think it would be easier to maintain if you just put all those stations in an array and made the actual code use that.
@teenola5783
@teenola5783 2 жыл бұрын
I'm a noob to all of this but this sounds about right
@danwilhelm7214
@danwilhelm7214 2 жыл бұрын
Nice little script Derek. Maybe put the radio selection information in a text file for greater flexibility. Re-create an array based on this file each time you change stations so new entries get picked up quickly without any program changes. Thanks for the idea! I'll probably write one for myself.
@BrucesWorldofStuff
@BrucesWorldofStuff 2 жыл бұрын
Your adopted son over at " The Linux Cast" did a video on a project on Gitlab called Rofi-Beats that does the same thing but uses Rofi. You did add some improvements and use Dmenu and that said, there both awesome. Thanks DT for all the hard work! Yes finding radio stations you like and work is a bit of a pain! LOL LLAP
@gerardoalvarez2932
@gerardoalvarez2932 2 жыл бұрын
Hey DT ! I just want you to know you are the greatest . I have learnt so much from you , please keep on doing what you do . Love from Argentina
@MadCat2345
@MadCat2345 2 жыл бұрын
"From Russia with love" (c) :) And so distinct pronounce. It is important for non-native speaker.
@rizkyadiyanto7922
@rizkyadiyanto7922 2 жыл бұрын
Hey! DT, instead of using dunst/dunstify, you should use libnotify package and notify-send command instead. notify-send should work on every DE without installing dunst.
@Sladen70
@Sladen70 2 жыл бұрын
I love programming videos 😁 I've recently been working on how bash scripts can work. This is just what I needed.
@withercubes3295
@withercubes3295 2 жыл бұрын
Why not use notify-send (libnotify) instead of dunstify to make it not depend of a single notification daemon?
@systemuser9636
@systemuser9636 2 жыл бұрын
Hey DT! Thank you for another great video. 🐧👍
@Winnetou17
@Winnetou17 2 жыл бұрын
Why doesn't the start_radio function also have the pkill and the mpv commands in it ? With the URL sent as $2 ? It would get rid of so many lines.
@loisvallee7291
@loisvallee7291 2 жыл бұрын
that's the kind of useful tutorial i want !
@habamax
@habamax 2 жыл бұрын
I read "Generating Admenu" in the video preview pic :)
@AkshayKumar-kz6zh
@AkshayKumar-kz6zh 2 жыл бұрын
You should probably consult, Russ Hanamen(the guy who put radio on the internet)
@0xva
@0xva 2 жыл бұрын
Wouldn't it be better to put the radio station list on a external file instead of inside the script?
@marcin6386
@marcin6386 2 жыл бұрын
We can go even further and start talking about database by genre, topics, stations etc. It depends at what scale you want to build your tool. I think small scripts like that has its own charm 😀
@0xva
@0xva 2 жыл бұрын
@@marcin6386 good point
@multicat2742
@multicat2742 2 жыл бұрын
Hi DT, i know reviewing distros isn't the main focus of this channel, but a freebsd distro named helloSystem is imitating macos and looks really interesting and easy to use. Would be cool to hear your opinion on it.
@smeqwack7337
@smeqwack7337 2 жыл бұрын
Dmenu is so useful and modular, btw shot out to rofi. Similar to dmenu but looks more nicer. Specially with a polybar theme that uses it with a special theme.
@RyanParmeter
@RyanParmeter 2 жыл бұрын
Would have liked to hear what is critical about the URL for it to work with MPV. By chance is it the stream url wrapped in a meta tag inside the page header?
@falx966
@falx966 2 жыл бұрын
Why I bother with a bash script to listening radio stations when pyradio just do that?
@WilliamDye-willdye
@WilliamDye-willdye 2 жыл бұрын
Bash live coding == good video
@eom22x
@eom22x 2 жыл бұрын
Thanks, gracias, ありがとうございました, 谢谢。
@RobsonLanaNarvy
@RobsonLanaNarvy 2 жыл бұрын
Sorry to miss the subject, but I need to ask anyway. I manage to make work before, but in my new installation of Artix witch DWM, I wasn't able to make japanese chars to appear properly on DWM / ST, does someone have a definitive solution?
@AndersJackson
@AndersJackson 2 жыл бұрын
Could look if you have latin-1 instead of utf-8 somewhere. And you might need a switch to change character encoding. Try to use the man(1) command, like "man dwm" or even "man -k dwm" to see all manual pages with "dwm" in it.
@11WicToR11
@11WicToR11 2 жыл бұрын
i love scripts like this one, but there is so much copypasta ...one has to understand whole script to add new option. You should try compress "name" => "url" to a simpler form, like arrays
@tylerdean980
@tylerdean980 2 жыл бұрын
Would be cool if this worked with webSDR, then you could listen to worldwide broadcasts with that real radio feel
@dkosmari
@dkosmari 2 жыл бұрын
Kinda bizarre that you went for Zeno FM instead of radio-browser.
@peternilsson1951
@peternilsson1951 2 жыл бұрын
Hi do you know if I can install a linux Distro on an Imac intel one i5
@SimonIngelsson
@SimonIngelsson 2 жыл бұрын
There are guides to find online
@edbeckerich3737
@edbeckerich3737 2 жыл бұрын
Nuclear-player to the rescue
@wisnoskij
@wisnoskij 2 жыл бұрын
Why are you listening to copyrighted music when free and open licensed music exists?
@pipi_delina
@pipi_delina 2 жыл бұрын
Nice 1
@gabutism.5062
@gabutism.5062 2 жыл бұрын
Elkowar wacky widget please sir
@theodorealenas3171
@theodorealenas3171 2 жыл бұрын
"I wasn't planning on making a video, I did some administrative work, and I wanted to listen to some online radio. And I thought, hey man look at me rocking out, I'm on my RADIOOO! Would'n it be great if I had a DMenu script that's on my VIDEOOOO! With Danny and Lisa-a. They take me away from, the strangest places. With Danny and Lisa, aAaAa, tum tum tum, pa, pa tara ta tara ta tum"
@theodorealenas3171
@theodorealenas3171 2 жыл бұрын
I forgot to say, the song is "Radio Video" by System Of A Down. This specific thingie is from somewhere in the middle of the song, where the lead singer whispers.
@dougtilaran3496
@dougtilaran3496 2 жыл бұрын
C'mon man. Just add a pipe menu in openbox for "radio"
@pcrolandhu
@pcrolandhu 2 жыл бұрын
tldr: mpv link
@haadi.khan40
@haadi.khan40 2 жыл бұрын
first
@o.aggelos
@o.aggelos 2 жыл бұрын
Second
@burlydugong4851
@burlydugong4851 2 жыл бұрын
If you're an Emacs user, definitely check out eradio!
@WilliamLDeRieuxIV
@WilliamLDeRieuxIV 2 жыл бұрын
Anyone that is interested might want to look into the *SELECT* feature of bash for creating menus directly in bash. It might be useful to use *SELECT* over dmenu when you want to work directly from a tty with no x-server (eg. play a radio stream in a tty). An example using bash select for creating wifi ap selector script (without the need for a x-server): www.reddit.com/r/debian/comments/s2efmy/comment/hsjyio8/?context=3 You can find more info about SELECT here: linuxhint.com/bash_select_command/
Solve Problems With Shell Scripting And Dmenu
18:26
DistroTube
Рет қаралды 32 М.
Transform Your Scripts With Bash Simple Curses
16:15
DistroTube
Рет қаралды 111 М.
Walking on LEGO Be Like... #shorts #mingweirocks
00:41
mingweirocks
Рет қаралды 7 МЛН
BASH scripting will change your life
14:18
NetworkChuck
Рет қаралды 1 МЛН
Emacs Plugins That Impressed Me
10:49
DistroTube
Рет қаралды 37 М.
Shell Aliases Every Linux User Needs
29:03
DistroTube
Рет қаралды 38 М.
I Made The Ultimate Cheating Device
9:39
ChromaLock
Рет қаралды 1,4 МЛН
Vim And Emacs Are The Most Important Skills You Should Learn
21:57
Become a bash scripting pro - full course
36:00
CODE IS EVERYTHING
Рет қаралды 67 М.
What is $PATH on a Linux Shell? (The Linux Crash Course Series)
21:52
Learn Linux TV
Рет қаралды 35 М.
Why Isn't Functional Programming the Norm? - Richard Feldman
46:09
How A Steam Bug Deleted Someone’s Entire PC
11:49
Kevin Fang
Рет қаралды 1 МЛН
"Clean" Code, Horrible Performance
22:41
Molly Rocket
Рет қаралды 907 М.