r/learnprogramming • u/sundid • Nov 07 '19
Neat website to learn Linux/Bash
Not sure if this was mentioned before, but it helped me a lot.
57
u/andreyred Nov 07 '19
What’s the benefits of learning linux for someone not in the software field?
65
u/tosch901 Nov 07 '19
Cause it's a great OS to work with in general imo. So if you don't use software that needs a specific os in order to work properly, I'd give it a try.
32
u/iamanenglishmuffin Nov 07 '19
To the level that this website guides through? Probably none.
I take it you are not in the software industry but programming may be useful in your job. Depending on what tools you are using it may be somewhat easier to set up your development environment in a Unix like operating system like Linux or Mac.
Desktop environments built for Linux offer a lot more UI customization than Mac or windows. I used Arch Linux with xfce as my daily driver for a long time not just for development work. It did everything mac or windows did and more, and was blazing fast on an old Intel chip + small ssd.
Most Linux you will encounter in the wild is either so barebones that you will likely not be touching it if you are not a software developer (eg server) or so built out that the fact it is Linux is irrelevant (android).
If you are on a Mac it would be helpful to learn how to use the file system and do basic tasks through the shell.
6
u/Rampo321 Nov 07 '19
For someone that is trying to learn programming and has really only used windows, what Linux would you recommend I try because it seems like there is so many to choose from?
8
Nov 07 '19
Pop!_OS is a derivative of Ubuntu, created and maintained by System76, a very well known manufacturer that promotes and ships hardware empowered by Linux.
It's a very polished and non invasive os, very easy to assist into the transition from Windows/other.
Just be sure to not sink yourself into the war of distros, the general rules are that most of the distros are basically the same, but with different packages manager, philosophy, updates delivering and defaults.
You should just give a peek to the major ones (Ex. Debian, Ubuntu, Arch, Manjaro, Fedora, Open Suse, Mint, ecc) and then, try the some Desktop Environments (start with KDE, GNOME (POP OS run this by default, XFCE) to find what suits your habits/preferences.
That's it.
You'll see a lot of people worshipping a given distro for reasons unknown even to them, it's only fanboyism running wild and most of them could barely deal with a terminal (its not like Linux is all about terminal, but you'll definitely discover why it's so useful if you dig it enough). Stay away.
I've suggested pop os due their minimalistic approach, optimization and very long procedures reduced to one command (ex. Tensorflow). You can learn more from their site.
5
u/iamanenglishmuffin Nov 08 '19 edited Nov 08 '19
Ubuntu is considered the standard.
Ubuntu ships with a desktop environment called Gnome.
A desktop environment is the part of the OS that let's you use and configure things like toolbars, widgets, launchers, workspaces, window management, themes and colors, etc. (in Windows the desktop environment would be things like the login screen, the desktop, the start menu, the toolbar, the system tray, themes like Aero).
There are many different distros, but you can install most DEs on any distro. Some distros ship with an optimized version of a specific DE. (edit for clarity: distro is short for Linux distribution. Distros are the different installs like Ubuntu or xubuntu or even Android, chromium-os, etc)
For example, Ubuntu ships with Gnome but Xubuntu ships with xfce4. You can install xfce4 on Ubuntu and you can install gnome on Xubuntu. But it's not advised to do that.
You can also do a "minimal install" of a Linux OS, which boots to the command line and then install a DE manually. This is my current way of booting up a new Ubuntu machine for everyday use. It's nothing fancy. You just type the command to install xfce4 after logging in, then type "start xfce4" and you have a DE.
When I started I originally used Linux Mint (built on Ubuntu) with xfce4. Xfce4 requires a bit of customization to be sleek but it's very lightweight and simple. You can make it feel a bit like windows 7 if you want.
Something like gnome is more feature rich but also can be complicated to customize.
I would recommend installing VirtualBox then download an Ubuntu image and try it out.
3
u/pm_me_steam_gaemes Nov 08 '19
This is a great breakdown. I've used Linux for a few years and know this, but I couldn't have explained it better myself.
Definitely recommend installing VirtualBox and just trying a proper Linux Distro in a VM.
I run Windows 10 on my main desktop, but I have ~10 VMs with various distros at the moment. I also generally use Linux on any laptop except for the one provided by work.
2
u/RightHandedGuitarist Nov 07 '19
I would personally recommend Pop!_OS from System76
Check out r/pop_os
2
u/stoph_link Nov 08 '19
I hear Peppermint is nice as well. I plan on spinning pop and peppermint up in hyper-v this weekend :)
4
u/demolsy Nov 07 '19
You can also activate Windows Subsystem for Linux. It basically gives you native Linux shell on your Windows machine. Your Windows file system is listed under mnt as well. With vscode they have an extension that allows you to work in your Linux environment natively from the Windows version of vscode. I have a full Linux environment for my dev while using Windows. The only problem is that you can't run graphics from the Linux env without implementing a few hacky solutions. So when I run data stuff with Python I still gotta use windows for the graphs
2
u/assertiveturtle Nov 07 '19
This! I know it's not actually linux but theres something about programming in windows with a unix based terminal inside my IDE. Feels great to use!
0
u/Rampo321 Nov 07 '19
A lot of those words very much confuse me lol. But this seems like it might be a better option for me. I will look into it, thanks.
5
u/12345Qwerty543 Nov 07 '19
Use Linux not the windows subsystem. WSL is not Linux. Linux != Command lines like that guy said. Just go get Ubuntu and run from there. You will learn 10x more in the same amount of time.
4
u/demolsy Nov 07 '19
Yes, WSL is not real Linux. It basically provides you a shell(like CMD but for Linux) where you can run CLIs. And as a programmer I very much enjoy using Windows while running all my dev tools in Linux. If you really want to learn Linux quickly and the best way. Just install it and dual boot. Personally, just a bash shell enough for me and all my needs.
0
Nov 08 '19
[deleted]
0
u/Rampo321 Nov 08 '19
I ended up installing pop on an old laptop I have. I'm gonna mess around with it tonight and maybe try Ubuntu on a VM on my PC tommorow. Thanks for the info.
2
u/NumbN00ts Nov 08 '19
Honestly, stick to the one for now. I’ve got Pop on a old laptop as well and have my gaming rig that still runs Win10. Gaming on Linux just isn’t stable enough and when I want to game, it’s usually because I want to relax for a bit. I do have a project I want to work on that may be better suited to use that rig with Linux, but I’ll throw it on another drive when the time is right. Have fun and welcome to the community!
1
u/stoph_link Nov 08 '19
It really doesn't matter since the bash shell will function the same, so try some out and go with what you like.
If you have the hard drive space, I'd recommend spinning up some virtual environments. The go to VMs are Virtual Box and Hyper-V. There may be others, but this what I know of. Again go with what you're comfortable with.
Virtual Box is by Oracle and you just download it, install it, and go.
Hyper-V is built into Windows 10, and may require making a minor change in your BIOS, and enabling it in your Windows environment.
Once you have one of these programs installed, you can install a linux distro on a virtual machine.
If you are not very technical, I would recommend Virtual Box, and Ubuntu until you feel comfortable. But I hear Pop is really good too, but I haven't tried it yet.
If you want to get out if your comfort zone, use Hyper-v, and experiment with several distros.
Note that Gentoo and Arch will have you manually install the GUI OS, as in there is no installer to guide you and you will be typing commands to get the OS setup. So these may not be best for your first time unless you have someone to guide you, or if you don't mind reading/following documentation for initial installation. Or you can just use this as a command line OS to force you to learn bash.
1
u/PsydeliX_ Nov 07 '19
Use Ubuntu. Get the 18 LTS version so there will be a lot of guides and support readily available.
6
Nov 07 '19
Why did I see ‘btw I use Arch’ lol
1
u/iamanenglishmuffin Nov 08 '19
It was antergos, so a bit of an arch cheat and I had no right to be snobby about it.
1
Nov 08 '19
I meant in your second paragraph I literally read “btw I use arch.” I must be sick
2
u/iamanenglishmuffin Nov 08 '19
I mean that's the reason it's a meme right? Because if you read too fast every arch user sounds like a "BTW I use arch" arch user. If I didn't want to come across like that I could have just said Antergos 🤔🤔
3
Nov 07 '19
it runs super fast on old software and has lots of software that runs on it. All that software also happens to be free, which means you can buy a cheap computer, never pay another penny, and your system will work great
-3
Nov 07 '19 edited Nov 07 '19
IMO, there aren't any. Linux is not really a "user OS" regardless of how much people try to say Ubuntu is. I mean, it is, just not compared to Mac or Windows. Mac or Windows would usually serve you better.
I say this as someone who loves Linux. CentOS has been super kind to me... as a developer.
2
u/rochakgupta Nov 07 '19
To be honest, most of the issues are due to lack of proper drivers. I had set up Ubuntu for my parents who had never used a computer before. They seem to use it just fine. Also, if something doesn’t behave the way it should, I am able to troubleshoot and debug the issue better than an issue in other OS like Windows and Mac.
1
Nov 07 '19 edited Nov 07 '19
To be honest, most of the issues are due to lack of proper drivers.
Proper drivers, and OS updates that seem to break audio / something else every single time... why.
I had set up Ubuntu for my parents who had never used a computer before. They seem to use it just fine.
I did this for my parents a long time ago and they were pissed off they couldn't install Word. OpenOffice is really cool, but it wasn't the same. Just about everything is web-based now though, so maybe we're good.
Also, if something doesn’t behave the way it should, I am able to troubleshoot and debug the issue better than an issue in other OS like Windows and Mac
Just wondering if it's because you're better at Linux than you are Windows or Mac at debugging issues?
Regardless, I just don't see the reason to go to Linux for most people. More software runs on Mac or Windows still.
4
u/rochakgupta Nov 07 '19
Mac is too costly and Windows breaks much more than Linux. Also, I can do upgrades without shelling out a large sum.
1
u/Cosmic_Sands Nov 09 '19
I agree that most people are better off with Windows or Mac, but I don’t think that means Linux isn’t a “user OS” or that there aren’t any reasons why a non-developer might be interested.
1
u/billdietrich1 Nov 10 '19
Linux is not really a "user OS" regardless of how much people try to say Ubuntu is. I mean, it is, just not compared to Mac or Windows.
Please give some reasons. "it is, just not" is not very convincing.
Linux Mint (for one example) seems to work fine as a "user OS", out of the box. There are a few edge cases where the absence of real MS Office bites you on some documents. Other than that, the real hurdle is that Linux doesn't come pre-installed on computers, so someone moving to it may have to deal with partitioning and stuff. If you just want to wipe the whole disk and run only Linux, the Mint installer is pretty automatic.
1
Nov 11 '19
Mac OS and Windows have a greater share of the applications market, better driver support, are generally easier for developers to work with (for consumer-facing apps), have more consistent APIs, break less often when making system upgrades...
Cross-platform support has gotten better though, although games and a lot of other software applications still have to catch up.
1
u/billdietrich1 Nov 11 '19
True that the others have "more". That doesn't mean Linux doesn't have "sufficient".
Many people would argue about the "break less often when making system upgrades", at least about Windows.
Yes, Linux lacks in the games area. And not having real MS Office is a key problem IMO.
0
Nov 07 '19
[deleted]
5
u/haltingpoint Nov 07 '19
Can you elaborate on what makes some of them more impressive than others? My uninformed eye sees some pleasing color schemes, but other than that it looks like some basic system resource monitors and window layouts. Many of them that look aesthetically pleasing in the screenshots appear to have a bunch of windows that seem unpractical to constantly have displayed at all times taking up so much screen real estate. One common example is the histogram for what I'm guessing is music. Do people really find that valuable enough to ever have on their screen let alone taking up that much space? Or is it more because it just looks pretty for a screenshot and in real life they never have it open?
14
u/Stxvey Nov 07 '19
Love this website, have been going through the lessons for the past few weeks. Does anybody know where to go after it? For someone who is in uni still figuring things out, which one of the resources at the bottom of the page are worth investing the most time into?
5
2
u/adesme Nov 07 '19
I haven’t done this tutorial and I don’t know any of those books, but it at least looks like one is about scripting while another is about doing system administration, so I would say that it depends on what you want to do or what you want to get good at.
I’m pretty good with Linux but that’s quite simply from using it a lot and solving issues I’ve encountered while doing other projects.
2
98
u/guarana_and_coffee Nov 07 '19
If I could afford an award, you'd have one right now.
45
u/son_et_lumiere Nov 07 '19
I'll do it for you.
18
u/NeonLight001 Nov 07 '19
Not all heroes wear capes
23
u/mex036 Nov 07 '19
How do you know he isn't wearing a cape?
10
Nov 07 '19
[removed] — view removed comment
-3
17
3
u/ASIC_SP Nov 08 '19
I have a curated lists for various topics like linux commands, bash scripting, linux kernel, etc: https://github.com/learnbyexample/scripting_course/blob/master/Linux_curated_resources.md
6
Nov 07 '19
https://gist.github.com/LeCoupa/122b12050f5fb267e75f
Here's a cheatsheet for bash commands that everyone who uses linux should know
5
u/billdietrich1 Nov 07 '19
Nice.
But this explanation, while technically accurate, is not very helpful:
statement1 && statement2 # and operator statement1 || statement2 # or operator2
Nov 07 '19
This might not be for a novice. If you want more detailed explanations you can ask me what some stuff means and i'll do the best I can to answer
3
1
Nov 08 '19
I think what he means is that anyone who knows what an and operator does knows what the code does. Kind of useless description. Like saying "statement = statement # equal statements"
1
u/billdietrich1 Nov 10 '19
Better explanations would be:
statement1 && statement2 # if statement1 returns success (0), execute statement2 statement1 || statement2 # if statement1 returns fail (non-0), execute statement2
2
u/missmagdalene Nov 07 '19
Very cool! I'm so happy that I pick things up quickly, but in my first job I had to get familiar with bash/Linux on my own on the fly. Really wishing this was around then!
2
Nov 07 '19
Huge fan of this site! I've done the "Text-Fu" lesson and it was great! I need to revisit and do the networking one!
2
Nov 07 '19
This was awesome. I applied to an internship and they took me in on the basis that I basically learn the Linux basics in under 4 days. Went through this whole site. Helped a ton, would recommend to any newbie.
2
1
1
1
1
1
1
u/KaranKastle Nov 07 '19
This is a goldmine to any CS student. Thank you for this!!! Also, could you recommend something similar for SQL and Python Programming? I will be forever greatful!!!
Thanks in advance!!!
1
u/MrCrudley Nov 08 '19
Udemy has some really good courses. I'm starting "automate the boring stuff" to learn pyhton. My last job was 6 years of mainly hardware and my new job is all software based in AWS so I'm trying to get some software skills. Going to be challenging but it's a must to really advance my career and future proof myself.
1
u/chris1666 Nov 08 '19
Very sweet intro site, thanks for sharing, I shard it with an interested friend and subbed for their new classes.
1
1
u/FUHGETTABOUTIT_1 Nov 08 '19
GOLD! Thanks for sharing!! Definitely something to read/practice on my free time.
1
1
1
u/Holylander Nov 08 '19
Indeed, great site for the beginners, Cindy Quach (SRE, Google) has the rare ability to explain things in accessible manner.
https://www.coursera.org/instructor/cindy-quach
https://qconsf.com/sf2019/speakers/cindy-quach
1
u/bohemian03 Nov 07 '19
Amazing, thank you! I've been a Mac user for years and will have to use Linux for my new job. This will help me be prepared :)
0
0
Nov 07 '19
[deleted]
7
u/falloutofthecreed Nov 07 '19
I'm pretty sure the Mac terminal is like 99% the same as a Linux distro terminal
2
u/Smallzfry Nov 07 '19
Historically, the Mac terminal has used bash, which is the default on most Linux distros. It recently switched to zsh due to licensing issues, but the commands work the same either way.
396
u/billdietrich1 Nov 07 '19
https://linuxjourney.com/
http://linuxcommand.org/
https://linuxsurvival.com/linux-tutorial-introduction/
https://help.ubuntu.com/community/UsingTheTerminal
https://lym.readthedocs.io/en/latest/
https://ryanstutorials.net/linuxtutorial/
http://swift.siphos.be/linux_sea/index.html