Linux - NewbieThis Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place!
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Introduction to Linux - A Hands on Guide
This guide was created as an overview of the Linux Operating System, geared toward new users as an exploration tour and getting started guide, with exercises at the end of each chapter.
For more advanced trainees it can be a desktop reference, and a collection of the base knowledge needed to proceed with system and network administration. This book contains many real life examples derived from the author's experience as a Linux system and network administrator, trainer and consultant. They hope these examples will help you to get a better understanding of the Linux system and that you feel encouraged to try out things on your own.
Click Here to receive this Complete Guide absolutely free.
Ive made a function and I cant seem to call it. it will run when I use it as a script, as soon as I make it a function glass()
then I tried to put it into a script called run_glass
I get an error on line 4 doesnt recognize end of file. Basically I just put it into the file run_glass to see if it would run and it wouldnt. Do i need to put something before or after the function designation to get it to call and run properly? Hopefully this makes sense to someone. Thank you for reading
Can you post the actual code of your script for us? The gibberish text you typed in doesn't help one bit man... Not trying to be a d*ck either, but without seeing code, how can we help you troubleshoot?
LOL no offense taken, Hey I just want to help you help me. Here is the code all I want to do is be able to call this function into another script that only contains this function merely to prove the function can be called and works
echo "enter in a number: "
echo "enter in another number: "
echo "the number $a to the power of $b is"
expr ="$(( $a ** $b )) "
I was talking about creating a function once you create it How do you add it to a script. Like for instance I want to run the function glass (that i created) in a script called run_glass. Where the only contents of the script run_glass is the glass function. how would I make that run? the script is above.