Linux Help!

#1
alrighty this is what im trying to do:

- Create a directory called class.
- Move into that directory.
- Create a text file, that contains what is your absolute path, relative path and call it paths.txt

help!!! im new to linux (Im using Knoppix)
 

mqudsi

Mostly Harmless
Staff member
#2
OK, first you have to start a shell. It's likely to be in the menu at the top -> applications/programs/utilities -> accessories OR system tools -> shell or terminal window.
OR
run -> xterm OR console OR shell

Once the shell is open,
Code:
mkdir class
makes the directory "class" in your default (home) folder (same as My Documents in Windows).

To move into that directory:
Code:
cd ./class
Just like in Windows.

Then to create a text file, use the "touch" command:
Code:
touch paths.txt
To find out your current *path* run
Code:
Cwd
and to find out the *name* of the relative path it's going to be ~/USER NAME/class/

After this, it depends on your system, but try running either of these commands:
Code:
nano paths.txt
or
Code:
pico paths.txt
or
Code:
vi paths.txt
That'll open a "GUI" of sorts from where you can type text in it the way you would in note/wordpad under windows.

Type the text returned from the shell samples above, and exit :smile:
 

mqudsi

Mostly Harmless
Staff member
#4
try
Code:
getcwd
 

mqudsi

Mostly Harmless
Staff member
#8
Yeah, now continue to the nano step.

Good work :smile:

And the relative path would be /class/paths.txt
 

mqudsi

Mostly Harmless
Staff member
#9
Oh, and welcome to NeoSmart Technologies, Ryan! :grinning:
 

mqudsi

Mostly Harmless
Staff member
#11
No problem Ryan, just glad you got through it ok.... I'm sure you'll come to love linux in time (or maybe not, but I have to pretend to be fair here).

:smile: :tongueout:oint:
 
#12
New to Linux

I'm new to Linux and I'm using Unbuntu. I need to first find out how to open the shell.

This is my assignment:



Click on Terminal Program.
  • Create a directory called class. Move into that directory. Create a text file that contains what is your absolute path, relative path and call it paths.txt
  • Save txt file to floppy drive, CD or other external memory for later submission to the faculty member.


Addendum:

My second question is, in using Ubuntu, do I need to enter commands to open the shell to do this assignment?
 
Last edited:

JustinW

Super Moderator
Staff member
#13
Most of the commands above should help you get through your assignment. Just click on Terminal from the menu to open it... no need to open another shell.
 
#14
New to linux (using Unbuntu)

I used the commands listed below and I was wondering. I have to find the absolute and relative path. This may be a foreign question, but is the current path the same as the relative or absolute path? When the GUI opens, I'm not sure what to type in and how to exit the GUI in Unbuntu. There is an Exit command at the bottom but it is not a clickable item but it has ^X beside Exit and I was wondering how do I Exit the GUI because if I close it the terminal will be killed.