The colors inside vim (or vi) are difficult to read. Change colors or at least disable the colors option.
@rainonmyface6 жыл бұрын
I came here to say this - super great tutorial, it is a little difficult to see when it goes to blue on black.
@farahmohumad53553 жыл бұрын
nano is the best
@farahmohumad53553 жыл бұрын
i like it the way you explain if
@DoodahGurl11 жыл бұрын
Great video. Very informative! Thanks for uploading.
@drakejohnson38038 жыл бұрын
I don't know if you still look at these comments, but I had a few questions. First, is there a way to put if statements on one line? Second, why do you use "vi" instead of "nano" for text editing? I saw someone else use nano and a different person use vi. Is there somereason I should use vi over nano?
@theurbanpenguin8 жыл бұрын
+Drake Johnson Sure: cd /etc ; ls This will first change to the /etc directory and then list it. There is no conditional logic here. In other words the 2nd command will always try to tun even if the first command fails cd /etc && ls Here the listing with ls only runs cif the first command succeds. So we know we are listing the /etc directory cd /test || mkdir test In this last example the second command only runs if the first command fails. In this case we create the directory if it does not already exist. All of these examples can include more than two commands. In the long run you can do more with vi or vim than you can with nano. Nano is great wheile you are learning but try vi as well
@drakejohnson38038 жыл бұрын
***** Thanks a lot. But by if statements on one line I meant could you do: if [[ $USER = "$USER"]] then echo "Your username for this computer is $USER." fi Instead of: if [[$USER = "$USER"]] then echo "Your username for this computer is $USER." fi
@TraceguyRune9 жыл бұрын
2:10 Thank you . Now I can get my scripts to execute without "bash"
@MlleJulliette5 жыл бұрын
Heyyyyyyyy, can you add CC (Closed Captions)? Thanks!
@Occel0t5759 жыл бұрын
best shell scripting courses i've found on the entire youtube ! Can you please put them on a playlist so I can download them easily ?
@Occel0t5759 жыл бұрын
jackmatt47 i'm dumb gonna create it myself :P
@Berghiker4 жыл бұрын
How do I make a new bash profile? Mine is not found on my mac.
@igotdembombs10 жыл бұрын
9:47 "We're testing to see if Andrew does not equal Andrew, and of COURSE Andrew does not equal Andrew"
@neckbont9 жыл бұрын
Thanks for the video very however where do you define what the variable USER is in the script?
@theurbanpenguin9 жыл бұрын
The variable $USER is set during the login and is part of your environment. As such you so not need to set the USER variable
@TraceguyRune9 жыл бұрын
+kornsnap $USER is a constant and a global. It's defined by the system
@ScreenPrintR Жыл бұрын
Mr. The Urban Penquin, do you have an online site with courses? Thank you in advance. Oops, I found it. Sorry. Must have misspelled it before.
@m-stermoh80310 жыл бұрын
thanks for this video it's very informative
@devilsey39 жыл бұрын
Well video,,good for basic concept :)
@add111ful11 жыл бұрын
too gud nice explanation...
@CosminRusu15411 жыл бұрын
VERY NICE!!!
@joshoduyoye1109 жыл бұрын
SO when you set USER to andrew... are assigning andrew to the user or are you using typing andrew when you execute it?
@jzantana9 жыл бұрын
+Josh Oduyoye That's an environment variable that gets its value upon login.
@taurus1519869 жыл бұрын
hello! after making the file executable I try to go back in /home/myname and execute bash01.sh but it tells me "bash01.sh: command not found". can anybody help? thanks
@theurbanpenguin9 жыл бұрын
Go to the diectory where the script is a.n run it with ./scriptname
@taurus1519869 жыл бұрын
+theurbanpenguin thanks a lot
@TraceguyRune9 жыл бұрын
+Albert Rama make sure its in one of the $PATH directories try this: mv bash01.sh $HOME/bin/
@paasaanepali87298 жыл бұрын
where did you get that if section from
@stablizershock8 жыл бұрын
I want to execute command in current folder without defining patch how to do it>?
@theurbanpenguin8 жыл бұрын
+stablizershock ./ or bash
@stablizershock8 жыл бұрын
***** I made sh file named as "install.sh" and i use "sh install.sh to execute but I want my customers to just open the file and command run as intended so should I use "./install.sh" command?
@brianmcgrady26749 жыл бұрын
when I echo $PATH I dont have a /home/bri/bin , any isea why?
@theurbanpenguin9 жыл бұрын
+Brian Mcgrady you can add it to your path variable PATH="$PATH:$HOME/bin"
@changjoe0112 жыл бұрын
Thank you !
@DJReeRee9 жыл бұрын
Relax, Kris. This is a learning environment for us all. Its not stupid about the comment i made as mary clo. I am at work and we have virtual box on our machines, we do technical support and you tube videos play extremely lower for us than that of windows. i was only commenting from my personal experience. No need to be insulting.
@theurbanpenguin11 жыл бұрын
Nu, but speak a little. I have friends in Cluj and we visit at least every year
@RenegadeFury11 жыл бұрын
that's sorta annoying how it's not == compared to most languages when checking
@TraceguyRune9 жыл бұрын
+Barack Lasagna Actually, its about half and half. Half the languages out there don't require "=="
@koczewniknawsegda365611 жыл бұрын
You are romanian?
@lthzm5 жыл бұрын
On roblox?
@gregshubert998210 жыл бұрын
~bin isn't in my $PATH
@Berghiker4 жыл бұрын
How do I make a new bash profile? Command not found on my mac.
@theurbanpenguin11 жыл бұрын
Nu, but speak a little. I have friends in Cluj and we visit at least every year