basicsys@mars~/lec1>echo abcd abcd basicsys@mars~/lec1>echo -n abcd abcdbasicsys@mars~/lec1>echo "ab\ncd" ab\ncd basicsys@mars~/lec1>echo ab\ncd abncd basicsys@mars~/lec1>echo "abcd" abcd basicsys@mars~/lec1>echo "ab\"cd" ab"cd basicsys@mars~/lec1>echo "ab\\cd" ab\cd basicsys@mars~/lec1>echo "ab\cd" ab\cd basicsys@mars~/lec1>echo -e "ab\ncd" ab cd basicsys@mars~/lec1>echo -e -n "ab\ncd" ab cdbasicsys@mars~/lec1>echo -n -e "ab\ncd" ab cdbasicsys@mars~/lec1>echo -ne "ab\ncd" ab cdbasicsys@mars~/lec1>echo -en "ab\ncd" ab cdbasicsys@mars~/lec1>echo -e "\a" basicsys@mars~/lec1>echo -e "abc\aabcccccc\a" abcabcccccc basicsys@mars~/lec1>echo -e "abc\a\a\a\a\a\a\a\a\a\a\a\a\a\a\a\a\a\a\a\a\a" abc basicsys@mars~/lec1>echo -e "\a" basicsys@mars~/lec1>echo -e "abc\a\a\a\a\a\a\a\a\a\a\a\a\a\a\a\a\a\a\a\a\a" abc basicsys@mars~/lec1>echo -e "\a" basicsys@mars~/lec1>echo -e "abc\a\a\a\a\a\a\a\a\a\a\a\a\a\a\a\a\a\a\a\a\a" abc basicsys@mars~/lec1>echo -e "\x30" 0 basicsys@mars~/lec1>echo -e "\x41" A basicsys@mars~/lec1>echo -e "\001" basicsys@mars~/lec1>echo -e "\002" basicsys@mars~/lec1>echo -e "\001\002\003\004" basicsys@mars~/lec1>cat F1 abcd efgh xy 1234 basicsys@mars~/lec1>ls F1 F5 old P1.1 P1.3 tichon2013.txt F2 lec1-morning2013.txt P1 P1.2 P1.4 udi basicsys@mars~/lec1> basicsys@mars~/lec1>asfhskfsfka -bash: asfhskfsfka: command not found basicsys@mars~/lec1>cat afsdfksflas basicsys@mars~/lec1>cat -n F1 1 abcd 2 efgh xy 3 1234 basicsys@mars~/lec1>cat F2 hello hi bye basicsys@mars~/lec1>cat -n F2 1 hello 2 3 hi 4 5 6 bye basicsys@mars~/lec1>cat -s F2 hello hi bye basicsys@mars~/lec1>cat -sn F2 1 hello 2 3 hi 4 5 bye [admashac@mars ~]$ pwd /home/cs/y11/admashac [admashac@mars ~]$ cd lec1 [admashac@mars lec1]$ cd [admashac@mars ~]$ pwd /home/cs/y11/admashac [admashac@mars ~]$ man echo ECHO(1) User Commands NAME echo - display a line of text SYNOPSIS echo [OPTION]... [STRING]... DESCRIPTION Echo the STRING(s) to standard output. -n do not output the trailing newline -e enable interpretation of backslash escapes -E disable interpretation of backslash escapes (default) --help display this help and exit --version output version information and exit If -e is in effect, the following sequences are recognized: [admashac@mars ~]$ cat .bashrc # .bashrc # Source global definitions if [ -f /etc/bashrc ]; then . /etc/bashrc fi # User specific aliases and functions PS1="\u@\h\w>" set -C PATH=$PATH:. admashac@mars~/lec1>ls P2 admashac@mars~/lec1>cat P2 pwd date admashac@mars~/lec1>P2 -sbash: ./P2: Permission denied admashac@mars~/lec1>chmod u+x P2 admashac@mars~/lec1>ls P2 admashac@mars~/lec1>P2 /home/cs/y11/admashac/lec1 Tue Oct 30 19:18:52 IST 2012 basicsys@mars~/lec1>cat P3 echo hello date sleep 2 echo after sleeping date basicsys@mars~/lec1>chmod u+x P3 basicsys@mars~/lec1>P3 hello Tue Oct 30 19:23:16 IST 2012 after sleeping Tue Oct 30 19:23:18 IST 2012 admashac@mars~/lec1>~basicsys/register Hello you called the basic systems registeration program You need to call it in order to be able to submit exercises. You need to call this program just once. Please enter your id number (9 digits): 205833320 Please enter your name (first-name and last-name): shachar admati You entered, id: 205833320 name: shachar admati OK to update your details: (y/n)? y Your details were sent for update. It will take several days Until your details will be updated, bye. Instructions to be able to run programs --------------------------------------- Do the following just once for the whole course: 1. login to mars 2. write: pico .bashrc 3. then using copy/paste add the following 3 lines to the end of the file .bashrc PS1="\u@\h\w>" set -C PATH=$PATH:. (do not add spaces in the above 3 lines!!!!) 4. exit from pico using ctrl+X and save the file 4. write: logout 5. then login again using telnet mars.netanya.ac.il Instructions on how to run a specific program --------------------------------------------- 1. using pico create a file. for example do pico P2 then write inside the file two commands, for examle pwd date then exit pico and save the file 2. write chmod u+x P2 3. run the program P2 by writing P2 Instructions on how to register to the course. ---------------------------------------------- in order to be able to register to the course, run the following command (just one time for the whole semester) ~basicsys/register you can run the above command from any directory. then enter your id number and name and exit. For example after typing ~basicsys/register and then giving id as 11111111 and name as udi rotics the following was seen on the screen: basicsys@mars~>~basicsys/register Hello you called the basic systems registeration program You need to call it in order to be able to submit exercises. You need to call this program just once. Please enter your id number (9 digits): 111111111 Please enter your name (first-name and last-name): udi rotics You entered, id: 111111111 name: udi rotics OK to update your details: (y/n)? y Your details were sent for update. It will take several days Until your details will be updated, bye. Instructions on how to submit exercises ---------------------------------------------- In exercise 1 you have to prepare 4 files, their names are P1.1 P1.2 P1.3 P1.4 after you prepared the files and tested them, you need will submit them for check (you have to submit all 4 files in one submit command). To submit the files for check you write the command ~basicsys/submit from the directory that contains the 4 files P1.1 P1.2 P1.3 P1.4 Then you will be asked for exercise number (write there 1 and not ex1). Then you will be asked for the lonin name of your partner, if you don't have a partner write the login name of yourself there). Here is an example of the screens I got when I did ~basicsys/submit from the basicsys login name basicsys@mars~>~basicsys/submit Hello you have called the submit program Enter the exercise number: 1 Hello you have called the submit ex1 program. Note that you can submit files only once. Do you want to continue (y/n)? y Enter the login name of your partner (if you do not have a partner then enter your login name): basicsys Your user id is: basicsys your partner user id is: basicsys OK to continue (y/n)? basicsys You have to enter y or n y The files that you have to submit are : P1.1 P1.2 P1.3 P1.4 Your file list is: P1.1 P1.2 P1.3 P1.4 Recall that you can submit exercises just once!!! OK to submit your files (y/n)? y Your files where submitted successfully. Bye.