 Okay, it is the evening. I am wearing my pajama pants, which have penguins on them. Funny story. My in-laws think that I love penguins. I don't think they realize that Tux the mascot of Linux is a penguin, but I think like a decade ago they heard me say something about liking penguins because of Linux and they didn't really get it, but I constantly get penguin gifts from them, but that's okay because I don't mind it. I like penguins. Sure. Me and my family, a year ago we got year passes, annual passes to Universal Studios and Islands Adventure. We live in Florida. We're only three hours away, so we'd like to go in the off-season when there aren't very many lines. So there's a website. Let me go ahead and flip over to the screen here and you'll see. This is a script we're going to be creating in a moment, but here's the website. There's a website here that you can go to. It's an unofficial queue time. They actually have the ride wait times for lots of parks, but this is Universal Studios which is currently closed, but Islands Adventures is still open, so you can see the ride times here. And this is the website I've used the best. Universal Studios has their official app, but I'm not going to install some proprietary app just to see the wait times. I'm pretty sure this whole site people submit times, but every time I go to the park, it's been pretty accurate because they'll have signs up around the park in certain places telling you the wait times and also outside the rides, and this has always been in updates fairly often. And you know what? It wasn't too bad. If I click on a mobile view here, it actually looks kind of nice. I don't know if there's ads on here. I use Brave Browser. It looks like it blocked three ads, so there might be ads on here I'm not seeing. Overall, it's a pretty nice interface, but I kind of wanted to do my own, which is going to start off with a bash script. So let's go out of mobile mode here. Let's go here. This is the URL for Universal Studios. This one's for Islands Adventure. Let's do Islands Adventure since the park wait times are open. Again, this code that we're going to create, I've already created it. It's up on Payspin. Here's the URL. I will put that in the description of this video as well, but this is a really simple. We're just going to WGet the page, both pages, and then use some stuff to strip out the information we don't want. So let's go ahead and do that. I'm going to grab the Islands Adventure here and just as an example, I'm going to do a one-liner here. I'm going to say WGet dash Q capital O dash, which is going to dump the HTML out to the page here, out to our terminal. So I'm going to run that and there we go. Now I can look through that and forget what I need, but I've already done this. So what I did here was I removed all new lines and then I added new lines at the hyperlinks. And then I found hyperlinks that have a panel block in, I think it's the class name. And then here I'm just removing the, I get some HTML encoding when I pull it down. And I want to convert those back, the ampersands and apostrophes into what they should be. And then we do some cuttings. Let's go ahead and just do this one at a time so we can see what happens. So we take this last command, we'll pipe into TR. TR can replace characters with another character. In this particular case, we're saying dash D, which just means delete and backslash and his new line character. That's going to put everything on one line for me. And that's going to allow me to quickly, and there's lots of different ways you can do that, but now I'm going to use said. And I'm just going to again, if I say said, and I'm going to find all the hyperlinks. So I'm going to basically put all the hyperlinks, start new lines on hyperlinks. And then I am going to grep for ones that have the panel block class right here. And then I again, I'm going to replace the HTML encoding, which is in this case, they use ampersands and apostrophes. There are programs out there that can convert all HTML encoding to standard ASCII, I guess technically already is standard ASCII, but you know what I'm trying to say here. But I just needed to replace those two characters. And there we go. We have a list. And I've also put in here, I'm dividing things up by pipe symbols. And I did that right there. So this is actually a double said. So the second one's replacing apostrophes and then ampersands. This one's basically just removing the tags and replacing the spaces between the tags with pipe symbols. So now I have the names of the ride and I have whether they're closed or in some cases, their times. They also, there's certain cases where it's showing what island on islands I venture there in. We're not going to worry about that. We're going to go one, two, three is the name of the ride. One, four, five would be the time. And that's what I do here. So adding that to the end of our one liner. Boom. We get a nice little list of a column with the ride name. And then on the other side of the pipe is the time or whether it's open or closed. So let's go ahead and create a script. We'll just call it wait times, wait times.sh. And I will just copy and paste this code from Payspin in there. And here I've created a variable called URLs. And actually there's a better way to do this. I'm trying to get out of the habit of doing this where I create a string variable and then I loop through each line. I really should be using arrays. In the future, I will be doing this less hopefully. But basically, this is Universal Studios. This is Islands of Venture. It's going to loop through both. It's going to do a W get for one and then do all the chopping and W get for two. And then we will make that executable, wait times. And then we will run that and we have a syntax error in my copyright information. Oh, you know what? I probably, there, that's fine for now. And then we need our shebang line. I pasted things in before I was in insert mode. There we go. And we have all our rides and all our times. Now, how is this useful? Besides the fact that I can just run it in my shell, but I'm not at my computer when I'm at the parks, right? Well, right now I am looking at what times I'm keeping track because I'm going in about two weeks and I'm keeping track of what times are busy times. So I am looking at this regularly and I can do it right in my terminal here. But now that I have this all in plain text and nicely formatted, I can use it in other aspects. So what I ended up doing was taking that script and then I went and I just Google searched HTML list templates just to get a nice looking list. There's this top one that came up for me from freefrontend.com class 18 CSS lists, freefrontends. And I scrolled through here till I saw one that looked good and I liked the way this one looked. Here's what the demo looks like. And I took that, got rid of the information that is currently in there. And then I also widen it because this is set to 490 pixels max. I set mine to, I think, like 80 percent of the screen. So this is what it looks like. And so I can scroll through here when I hover over it. And I said it so I think every five minutes it refreshes the list automatically. It says universal wait times. So this way I can give this link to my wife and me and I'm going with my sister and we can all have it on our phone without any proprietary software. Don't have to go to that other website. And in if I hit F 12. I can hit mobile mode here. And this is what it looks like on my phone. I can scroll through them. Like I said, everything at Universal currently is closed because it's almost eight o'clock or it might be a little past eight o'clock. But Islands Adventure, I think, is open till nine currently at this time of year. So I hope that you found this useful. I hope that you check it out. And I hope that you have a great day. Please visit filmsbychris.com.