tengine.sh

tengine.sh shell script is a simple quiz engine.
Download

tengine.sh Ranking & Summary

Advertisement

  • Rating:
  • License:
  • GPL
  • Price:
  • FREE
  • Publisher Name:
  • Kevin Waldron
  • Publisher web site:
  • http://www.zazzybob.com/sh_config.html

tengine.sh Tags


tengine.sh Description

tengine.sh shell script is a simple quiz engine. tengine.sh shell script is a simple quiz engine, primarily designed to be used as a login shell, so that prospective UNIX/Linux System Administrators can sit a technical quiz as part of their interview process.This README assumes that you'll be running tengine.sh as an interactive quiz, not via a login shell. If you want to set it up to run as a login shell for an interviewee, just add make the /usr/local/tengine/bin/tengine.sh script their login shell, and ensure that the interviewee's login account has read access to the entire tengine tree, and write access to the /usr/local/tengine/var/tmp directory, where the results files are stored.Functionality currently exists within tengine.sh for two types of questions - multiple choice, and fill-in-the-blank. InstallationAll steps to be performed as root: # pwd/usr/local# lstengine.tar.gz# gzip -dc ./tengine.tar.gz | tar xf -# rm tengine.tar.gz# lstengine Beneath the tengine directory, you'll find the following directory structure tengine |------ bin # contains the tengine.sh script |------ data # contains the question data | |------ 0001 # sample question directory | |------ 0002 # sample question directory |------ var |------ tmp # directory for temporary files and RESULTSBecause this script was primarily designed for use as a login shell, results are not given directly to the script user, but rather deposited in a file under /usr/local/tengine/var/tmp. Question FilesBeneath each question directory, you'll find four files. For example, in the 0001 directory, there are the following four files: 0001.h0001.q0001.a0001.cThe extensions for these files denote the following: h - headerq - questiona - answersc - correct answerThe header file is a four-line file formatted thusly: QUESTIONIDTYPEDIFFICULTYCATEGORYQUESTIONID can be anything you like, but I like to keep it the same as the question number directory. TYPE can be either MULTI for multiple choice, or BLANK for a "fill-in- the-blank" type question. DIFFICULTY is not currently used, and is for future development. CATEGORY is used to display the question category to the user. For example, 0001.h may contain: 0001BLANKEASYSystem ConfigurationThe question file contains the actual question that will be asked, such as: In which file is the default runlevel of the system defined?The answers file contains the possible answers, and is only relevant for multiple-choice questions. The correct answer file contains the correct answer, against which the users input is compared, for example, 0001.c should contain /etc/inittabFor a MULTI question, the answers file may be something like: a - ext2b - hsfsc - pcfsd - ufsand the correct answer file would contain the appropriate multiple choice response, such as a simple: aTake a look at the sample questions in the /usr/local/tengine/datadirectory tree for examples of this. NotesIf you want to use the script as a login shell, uncomment the NUM_TO_ASK value and set it to a value less than or equal to the number of questions currently under the data directory tree. If this variable is commented out, the user will be prompted for the number of questions that they wish to attempt. Results FilesWhen the user invokes tengine.sh, they'll be prompted for their Full Name. This is used when the results files are generated. An example results file, found under /usr/local/tengine/var/tmp could be something along the lines of: a - a/etc/inittab - /I/Dont/KnowKevin_Waldron: 1 answer correct out of 2 - 50%The format for question lines is correct_answer - answer_givenThe last line in the results file is a summary of the test. PerformanceThe way that questions are asked "randomly" will work a lot faster if there is a large pool of questions to choose from.


tengine.sh Related Software