Difference between revisions of "Submit script"

From Tux
Jump to: navigation, search
Line 1: Line 1:
 
The '''<code>submit</code> script''' is a program used on UNLV CS servers for students to submit assignments to instructors.  It is more common to use it in required introductory CS courses such as CS 135, although instructors may opt to use alternate submission methods such as email, WebCampus, or Moodle).  Be sure to follow the assignment submission policies as provided by your instructor in class and on the syllabus.
 
The '''<code>submit</code> script''' is a program used on UNLV CS servers for students to submit assignments to instructors.  It is more common to use it in required introductory CS courses such as CS 135, although instructors may opt to use alternate submission methods such as email, WebCampus, or Moodle).  Be sure to follow the assignment submission policies as provided by your instructor in class and on the syllabus.
  
'''To use the <code>submit</code> script:'''
+
===To use the <code>submit</code> script:===
 
* SSH to <code>bobby.cs.unlv.edu</code> and log in
 
* SSH to <code>bobby.cs.unlv.edu</code> and log in
 
** You cannot submit your programs directly from lab computers in TBE B-361, you must SSH into <code>bobby</code> first
 
** You cannot submit your programs directly from lab computers in TBE B-361, you must SSH into <code>bobby</code> first
Line 13: Line 13:
 
* Check below for examples of correct and incorrect submissions as well as output from the script, but note that your file is received by the instructor only when you receive the message <code>'''''file'' Successfully Submitted!'''</code>
 
* Check below for examples of correct and incorrect submissions as well as output from the script, but note that your file is received by the instructor only when you receive the message <code>'''''file'' Successfully Submitted!'''</code>
  
'''Things to note:'''
+
===Things to note:===
 
* You should only submit <code>.cpp</code> or <code>.tar</code> files
 
* You should only submit <code>.cpp</code> or <code>.tar</code> files
 
** The script will only successfully submit text files (e.g. submitting <code>a.out</code> would not be allowed) or binary files with <code>.tar</code> extension
 
** The script will only successfully submit text files (e.g. submitting <code>a.out</code> would not be allowed) or binary files with <code>.tar</code> extension

Revision as of 17:22, 12 January 2018

The submit script is a program used on UNLV CS servers for students to submit assignments to instructors. It is more common to use it in required introductory CS courses such as CS 135, although instructors may opt to use alternate submission methods such as email, WebCampus, or Moodle). Be sure to follow the assignment submission policies as provided by your instructor in class and on the syllabus.

To use the submit script:

  • SSH to bobby.cs.unlv.edu and log in
    • You cannot submit your programs directly from lab computers in TBE B-361, you must SSH into bobby first
    • If bobby is not available, try cardiac.cs.unlv.edu or java.cs.unlv.edu
  • Navigate to the directory your file is located in
  • Make sure your program compiles, is documented, and is tested
  • Type the following: submit filename XX instructor
    • filename is the name of your file (e.g. asst1.cpp)
    • XX is the assignment code and can range from 01 to 30, inclusive (note: the leading 0 is important -- 04 is correct, 4 is not correct)
    • instructor is the login name of your instructor -- you can see a current list of instructors and usage tips by typing submit without any other text
  • Check below for examples of correct and incorrect submissions as well as output from the script, but note that your file is received by the instructor only when you receive the message file Successfully Submitted!

Things to note:

  • You should only submit .cpp or .tar files
    • The script will only successfully submit text files (e.g. submitting a.out would not be allowed) or binary files with .tar extension
    • For more information see the page on tar files, but note that these would only typically be used when multiple files are required for an assignment
  • Your file is time stamped and the instructor will download all student submitted files at once by specifying the assignment number and the last time stamp to accept
    • If your submission is due by 11:59 PM, you submit it at 12:03 AM, and your instructor downloads all submissions that are no later than 11:59 PM then your instructor will not get your submission
    • If your submission is for assignment 05 but you submit it with assignment code 06 then your instructor will not get your submission
  • You may submit as many times as you like although typically only the last submission prior to the deadline is downloaded by the instructor
  • The name of the file you submit does not matter -- when an instructor downloads your submission the file is renamed, although if you are submitting a .tar file the paths and filenames within are not modified

If you are curious and wish to view the submit script, it is located on bobby at /usr/bin/submit

Example submissions

Correct .cpp submission

[username@bobby directory]$ submit file.cpp 01 instructor
dos2unix: converting file /opt/submit/tmp_instructor/username.01.20180112160154 to Unix format ...
file.cpp Successfully Submitted!

Note the presence of a filename, a valid assignment code (01, not 1), and the instructor's name. You would replace file.cpp, 01, and instructor as appropriate.

The dos2unix message is in reference to a program that is run to correct differences in character sets between Windows and Linux. The message Successfully Submitted indicates that the program was submitted successfully.

Correct .tar submission

[username@bobby directory]$ submit file.tar 01 instructor
dos2unix: Binary symbol found at line 1
dos2unix: Skipping binary file /opt/submit/tmp_instructor/username.01.20180112161209
file.tar Successfully Submitted!

The message indicating skipping the file refers to the fact that there is no reason for dos2unix to correct character set differences in a binary file. The message Successfully Submitted indicates that the program was submitted successfully.

Invalid filename

[username@bobby directory]$ submit fakefile.cpp 01 instructor
File Not Found!, Submit Failed!
        Please specify a valid filename in the current directory
        and submit again.

Invalid .tgz submission

[username@bobby directory]$ submit file.tgz 01 instructor
File is not ASCII Text, Submit Failed!
        Please specify a text file.
        and submit again.

.tar files are the only binary files that the submit script will accept.

Instructor notes

Use getsubmit to see usage details on how to download student submissions and filter by assignment number and time stamp. Even after using getsubmit, all student submissions remain in ~/submit until you manually move or remove them.

When downloaded using getsubmit only the last submitted file prior to the time stamp you specify will be downloaded. All files, including .tar files, will download to the current directory as username.cpp.