 Hi everyone. So this is a brief FYI and sort of a request for you guys because sometimes there are things that I either Haven't worked out or don't have the time to work out And I think this is something that a lot of people might be interested in So I wanted to do a video on it now if you you may know if you watch the channel already even if you don't welcome That there is actually only let me pull up an instance of your XVT There is a terminal browser called W3M and one of the things that no one actually uses a terminal browser I mean that that's silly, but if You W3M actually comes with the ability to display images on the terminal So for example, I'm gonna run W3M on my website. So now I'm accessing my website and You'll see that there are these big boxes here Those are actually images that are trying to be displayed, but W3M it can display images just not very well So if I move around, I think they appear As you can see when I go through the image, you know It's it's messing up stuff like that and this is me using your XVT if I use my own terminal my build of ST Let me go to the same site It's not even gonna work that well You'll see that yeah, you can it looks like my face flickers into existence when I move But aside from that it doesn't really work or If I've tried other terminals, I mean every terminal is a little different W3M So it has this nice ability to Display images, but it it's not very I don't know robust. I suppose you could say now recently Well, I don't know how recent it is but One little utility that's growing in popularity and a lot of people have asked me about it is this one here It's called Yerberzuk or as we call it in the free world Ubersug and Ubersug is a nice little I suppose it's Python because You install it with pip, but it's a nice little utility or library or whatever That generates image previews much better than W3M now It doesn't have perfect compatibility with everything just because people haven't integrated it into everything, but I find Let me let me actually show you Compare what you just saw with W3M to Ubersug Now I actually have a little script. Let me show it to you Just the to test it out now they on the github They show you how you can run it either in bash or Python or whatever else, but so I have this little bash script right here I'll show you how this works. So this script is called IMG. I'm gonna run IMG on an image file IMG gonna run it on my wallpaper file and This how the script how I have it written here You can give Ubersug a couple arguments like the position where you want the image to be displayed and the Maximum height and width and other things as well, but these are the things that I use so I'm gonna say zero X and Y and a maximum width and height of 30 so I'm gonna run that and you'll see that it actually actually displays this image now I gave it a X and Y of zero so it appears in the top left corner But look how pretty your this image is and also if I spawn new terminals if I mouse away It's not breaking. I can I can move the window around I didn't even show you doing this in W3M because it's just a mess if you if you're familiar with you running Ranger Running image previews through Ranger, you know how terrible they can be but Ubersug their image Images display very perfectly even I think even if you clip through the terminal window It still Shows the part that's still left. So it's very consistent. Now, of course some the particulars of the long years and pull back up the script Now this little script I have I asked on my blog for you know, if people had found Solutions for vifm, which I'll talk about in just a second. No one gave me anything, but you know anyway I would like So let's see so it's much more robust as I said I'd sort of like to Or and I also think it already has compatibility with Ranger I think that was added recently you can check the Ranger documentation, but I think you can already use Ubersug for image previews But what I was doing a couple days ago, and I didn't manage to finish is Working out these image previews in vifm, which I've been using as a you know browser file browser So here's vifm and you can have a preview window if you want Now I'll show you that I'm running the script as the preview script But you'll see that as I go through these images, they're just not showing up They sometimes they flicker a little blackness flickers, but it doesn't even show the image now. I think everything is working out I mean, you'll see that the flickering if it pops up is the right size The script should be working everything falls into place because vifm you can send whatever preview script you have Things like the coordinates that you need and the maximum width width and height and all that kind of stuff So that's what I do. I send it to the script But for whatever reason it doesn't work and it's not specific to my terminal. I tried it on urx vt I tried it on alacrity. I tried it on Xfce terminal or whatever and it didn't work on any of them so if any of you guys want to take this script here and Try and get it to work with vifm I would highly appreciate it and I'm sure everyone I In case you guys haven't noticed I've really been using vifm as opposed to ranger I think I I sort of plan on switching larbs to using vifm. So I'd like to get image previews on this So I'll just say that The other thing in this as well So again, you can check out the other things you can do You know it talks about running it in Python stuff like that But another thing I'd like to have obviously the script that I made here Where I take You know just an image as an argument and I have to manually give it the maximum size or whatever And all this stuff I'd like to be able to just say let's say IMG and it prints out just an image right here and then It gives me my prompt at the bottom and that's it now What that would require of course I mean it's not too difficult to you know just have it print an image and then return to the prompt But I'd have to size everything the right way And that could be a little problematic. I actually do not know how to take You know terminal data and feed it into a script when you're when you're in an actual terminal I don't know like terminal size and stuff like that. I've never done it before I could probably read documentation for it But you know I have stuff to do nowadays So if anyone has any clues on how to do that like just generate a little script that can print out an image And then you can keep going that would be nice as well Aside from that. I I really just wanted to throw this video just to make you aware of uberzug Just and let you guys know that it is out here. I encourage you to play around with it It has some other options as well Obviously I talked talked about the the height and width and stuff like that and all the kind of arguments You can give it but you can check it out yourself So anyway, hopefully you can play around with this Hopefully someone if I don't figure it out Someone else can figure out how to get the image briefs and via them because I would definitely Appreciate it, but anyway, so that's about it, and I will see you guys next time