Linux - Reddit – Telegram
Linux - Reddit
751 subscribers
4.17K photos
207 videos
39.8K links
Stay up-to-date with everything Linux!
Content directly fetched from the subreddit just for you.

Powered by : @r_channels
Download Telegram
Script to rename file name/content

Hello all,

My job has made strides for our team to be more efficient at programming. I am a bit familiar with Linux.

I want to create a program where I can upload a file : “0001.jar” , and it would create an xml file called “0001.xml” and a trigger file called “0001.trigger”. After this is done, I want the xml files I have created to have a specific field called <ID>0001<ID>, reflecting the file name.

How should I go about this as a novice programmer?

https://redd.it/llkgx5
@r_linux
[Events] vBeer online Party - Tomorrow 18th Feb at 3PM GMT

Fellow opensource fans, I invite you to **3mdeb's vBeer event** to discuss the open/libre firmware/hardware and other nice embedded things you have in mind! We could

* look through the growing family of opensource coreboot-based distros,
* explore the real possibilities of coreboot BIOS on the modern PCs,
* figure out what can we do to bring back the KGPE-D16 server support to a coreboot master,

\- and much more! There’ll be a lot of interesting talk with a cosy atmosphere and good vibes - so, feel invited and take your beer! ;) [http://live.evenea.com/3mdeb-vbeer](http://live.evenea.com/3mdeb-vbeer) , **Tomorrow** 18th Feb **at 3PM GMT**

https://redd.it/llt9sz
@r_linux
All my achievements in 2 month journey of being Linux Youtuber

This is my 0 to \~1k Subs journey where I provided Lot of goods to community without spamming my channel videos. This is why I Love Reddit. You can get recognized even with 0 followers.

**About Me -**

* I am Suraj Kushwah (aka **BugsWriter**)
* Distro - I hop between Arch & Gentoo (with dwm)
* I love **Linux**\-**libre kernel** and I am a big GNU fan.
* I started a Linux YT channel. Because Technology is getting shit everyday and I believe I have to save the world.

# Here my Past 2 months Achievements -

&#x200B;

* [myyt](https://github.com/Bugswriter/myyt) \- One command to search (with dmenu) and play YouTube videos from terminal. This was my first simple noscript, my purpose was just to teach but, surprisingly this got lot of attention and I got 1.7k total Upvotes on multiple subreddits. This motivated me a lot because I was used to live in dark, I was very good with Linux and computers but it was my hidden talent, because I had really shitty communication skills.

&#x200B;

* [redyt](https://github.com/bugswriter/redyt) \- Simple noscript to download images of top posts of any Sub Reddit and open it with sxiv. I made this just to show people power of terminal and again noscript also got lot of attention (1k+) Upvotes (total).

&#x200B;

* **After this I got shout out from** [Mental Outlaw](https://youtu.be/xogxETRXN4k) for myyt and redyt.. and I was so shocked because I was used to watch him to learn about gentoo.

&#x200B;

* [pirokit](https://github.com/Bugswriter/pirokit) \- Script to search torrents from dmenu and start download them instantly. This got lot of attention on r/piracy and some other Linux subreddits. (1k+ Upvotes)

&#x200B;

* [Unixporn Compilation](https://youtu.be/upCemv2UaLc) \- I believe everyone of you watched this video. I created this for my channel. People on r/unixporn loved this video. (5.5k+ Upvotes)

&#x200B;

* [Wallpaper Downloader](http://0x0.st/-zNM.bin) \- A Script to search and download wallpapers from Wallhaven in bulk. This got lot of attention on r/unixporn. (600+ Upvotes)

&#x200B;

* [Youtube Automation](https://www.reddit.com/r/linux/comments/l5awi1/automating_an_entire_youtube_channel_with/) \- I shared this technique of making compilation video by editing with ffmpeg and uploading it with simple shell magic. This got lot of attention on r/linux (1.6k upvotes)

&#x200B;

* [Tuxi](https://github.com/Bugswriter/tuxi) \- A program which scrape google to give question answer or any question on terminal. Now this one is one of my best. People are keep adding cool stuff to this. Got lot of attention on r/unixporn (2k+ Upvotes Total)

&#x200B;

* **Today I Got another** [**Shout Out**](https://youtu.be/PLwtX_gflAA) **from Mental Outlaw for Tuxi.**

&#x200B;

Besides all this I also shared some really good ideas which convince people why to learn using terminal. Like -

* Sharing files online quickly with dmenu.
* Why you need to learn awk.
* Gilfoyle's remote rig toggling program in BASH
* and some real life example of saving time with terminal.

Getting all these ideas, writing noscripts, recording & editing Video, Communicating with all response I get .. It's a lot of work for a lazy guy like me (after all that's why I write noscripts). But my passion for Linux and all the good response I get truly changed my personality.

With all this, I overcome my fear of speaking English. I remember during my first video I was so nervous in front of mic. Spending hours just to say one paragraph properly.

It's like dream come true. Showing people why to use Linux. Convince them to learn programs like **awk, sed, cut, paste, grep**.

My life is changed .. I hope my 2 month journey will motivate you to share your knowledge and providing goods to community.

I never spam any of my youtube video on any Linux subreddit. I always did text based post or posted demo video. I just share my video link in comments silently which I have to, since Youtube hardly promote good Linux YouTuber and If I don't share how people are going to know about
How to recover formatted ext4 created on lvm partition

I need to recover a ext4 that was created on a lvm filesystem as I accidentally formatted it by mistake from ext4 to ntfs using disks in Ubuntu desktop The lvm is a 7tb partition made up of 1tb, 2tb and 4tb drives. The lvm was created using gpart and webmin lvm management tool as I'm a noob when it comes to command line stuff

https://redd.it/lluxhr
@r_linux
Finally decided to install Linux again after years!

Three years ago I was DONE with Windows, I had jusr found out about Linux and it only took me 5 minutes to tell myself "woah this is so much better than Windows 10!", so I installed it immediately.

I am obsessed with customizing my OS', needless to say both my phone and PC look nothing like stock Android and Linux, even on Windows I did my best to change everything (but obvioulsy there is a limit... ew).

I loved being able to customize Linux so much, that's when I understood what freedom really was (lol), heck you can even change the bootsplash?!?

But I was younger and dumber than now, and I didn't really know how to use the terminal, so that's pretty much where the pros for Linux ended, I couldn't use Photoshop, many videogames and school programs... Sure, there were Wine (which mostly didn't work) and alternatives, but it wasn't the same thing, so there I was installing Windows 10 back.

But 3 years later, Linux's distros improved so much since then, and I miss being able to do all that stuff, I just decided to install it again, but on a partition, so I can have fun with Linux (geez it looks to good!!) and switch to Windows for a few programs.

I know many things have changed since 3 years ago, when I used Ubuntu, and I'm planning on installing it again, is that still a good distro to install in 2021? Is there something I should know? Any tips? :)

https://redd.it/llwrgm
@r_linux
Nvidia Powermizer Prefer maximum performance won't save ?

I am on Pop Os and loving it. One problem I can't sort though is the Powermizer settings don't save and I have to manually do it every reboot. Is there a simple way to get this done or is it a pain to do ? Many thanks all.

https://redd.it/llzj8c
@r_linux
Suggestions for Interview Questions

I've been asked to develop some interview questions for a technical candidate with 5-8 years of infrastructure experience with emphasis on Linux and troubleshooting While I'm coming up with plenty of "explain DNS, explain routing, tell me about OSI" and scenario "computer A can't connect to computer C" type questions I'd like to get some ideas from some of you.

For those that have recently done interviews either as a candidate or interviewer, what sort of questions are popular? Any interesting scenario questions? What sort of questions separate competent/advanced to expert?

https://redd.it/lm25ty
@r_linux
Automatically join online classes.

Many of us need to attend classes online, and finding the right url for each class and clicking on it at the appropriate time is such a pain (I am too lazy to do all that).

So here is a solution I found out to make my life a little easier.
I started using **calcurse** to maintain my class time table. It is a beautiful tui application which manages events and todos. It has this amazing feature to run a command just before an event start. The default command would send a notification regarding the upcoming event. But this command can be changed to anything. Changing this command to open the class url would automatically open the class for you.

# Requirements
* calcurse

# Procedure

#### Adding Timetable

* Added each class as a recurring event in calcurse with the noscript having the class name and the class url as follows
```
Topology <Tab Space> https://meet.google.com/url123
```

#### Setting up noscript to open url
* Now when I run calcurse --next from the command line I get output as follows
```
$ calcurse --next
next appointment:
[08:26] Topology https://meet.google.com/url123
```
> This means the next class is topology and it is in 8hr 23min and the joining link is that.

* Here is a small noscript that would notify about the next event and also open the url if it exists.
```
#!/bin/sh

browser="brave"
event="$(calcurse --next | sed "1d")"
name="$(echo "$event" | sed -E 's/.*\] ([^\t]*).*/\1/')"
url="$(echo "$event" | grep -o "http\S*" )"

if [ -z "$url" ]
then
notify-send "$name"
else
notify-send "$name" "opening link..."
eval $browser $url 1>/dev/null 2>&1 &
fi
```
Save this as an executable somewhere

#### Configuring Calcurse to run the noscript
Now all that is left to do is to configure calcurse to run this noscript 15 seconds before the event starts.
* Add the following lines to calcurse config file (~/.cache/calcurse/conf).
```
notification.command= /home/user/path/to/this/noscript
notification.notifyall=all
notification.warning=15
```
And there we have it. Now whenever calcurse is open (or launched as daemon), all your classes will be automatically opened in the browser.

## Extra

* If you are really adventurous there are browser plugins that automatically mute, switch off camera and auto join you into google meet.
* I also add the following as a module in my status bar noscript to show when I have my next class.
```
event="$(calcurse -n | sed 1d | sed -E "s_^ *\[(.*):(.*)\] ([^\t]*)\t?.*_[\1h \2m->\3]_")"
```
This would give an output as *07h 27m -> Topology*.

This is taken from my [gitpage](https://github.com/pystardust/automeet)

https://redd.it/lm461b
@r_linux
A little ZSH cheatsheet

Hi there!

I recently wrote a small framework in ZSH, and that required me to look how to perform many things with the language that aren't always easy to find.

So I made a little cheatsheet, in case it can help anyone!

It shows the syntax for various processings you may have to perform (modifying an array properly, slicing, replacing, iterating over a global pattern silently...)

Here is the link, feel free to tell me if that helped you and/or if you see any error/potential improvement!

https://gist.github.com/ClementNerma/1dd94cb0f1884b9c20d1ba0037bdcde2

https://redd.it/lm4hmi
@r_linux
Alacritty color emoji support

Hey guys i recently started to play with alacritty terminal but i cant get color emoji rendering I looked it up on github they says alacritty support fallback fonts but I couldn't step joypixles font anyone know how can I get color emoji working on alacritty???

https://redd.it/lm8o56
@r_linux
Pinkpill, a minimal package update checker that supports AUR helpers

Should have put this in the noscript, but I forgot: this software works on Arch and derivatives only.

I am sure this has been done before, and maybe also better than what I did; but I had fun doing that, and so I thought I would share it.

This aims to be effectively just a background program that checks for updates and spawns a notification whenever updates arrive. It runs on NodeJS and TypeScript as a meme but that is fine as long as it works ig.

Link is https://github.com/AryToNeX/pinkpill

I hope this will be useful to people who have minimal Arch setups or people who dislike KDE's Discover so much.

Also, contributions are always welcome.

https://redd.it/lm812x
@r_linux
How do I create a file in another directory without changing directories?

I’m taking a Linux class. Currently working on the command line and after rereading the chapter over and over, I don’t understand how to do this.

The question is:

Without changing directories, and using a single command, create a file called January that contains a calendar for January 2021 in your Jan sub directory. Indicate the command below.


This is probably something basic for people who know how to work on the command line but I don’t know how to do it, some help would be greatly appreciated!

https://redd.it/lmdjwz
@r_linux
Free & Open Source Photo Software

I’m looking for free and open source photo software that can detect duplicate photos plus do basic photo editing.

I have well over 20,000 photos and I know there are duplicates but it would be very time consuming to go through every one. Thank you for your help and your advice.

Is there such software available?

https://redd.it/lmdb6e
@r_linux
Simplest way to remotely access SSH for a headless Linux server?

I'll be deploying some small rigs for friends and was wondering what the general consensus is for a simple remote SSH setup. My current home server runs wireguard which I use to SSH into from wherever I'm at, but that requires being local to the device for initial setup. It's been rock-solid for the 1+ year it's been running.

So I guess my question is how can I setup a Linux server such that after I ship it is then able to be plugged in and ready for me to remote SSH into it?

https://redd.it/lmd7rs
@r_linux
I play games, but when will /if Linux be able to play triple a noscripts?

I know some steam games do work with Linux but as a gamer and video editor, when will I be able to run Linux on my main machine and not have to worry about compatibility. I truly think Linux is the future and community-driven software is better for everyone. I just want to know when I can stop dual-booting Linux and Windows

https://redd.it/lmeuk9
@r_linux