~azzar1/unity/add-show-desktop-key

« back to all changes in this revision

Viewing changes to doc/man/sample.rst

  • Committer: William Grant
  • Date: 2009-12-14 04:09:57 UTC
  • Revision ID: me@williamgrant.id.au-20091214040957-lpj8koijlkgs616n
So like Python, yet so unlike it, configobj's list syntax is Different®.

Show diffs side-by-side

added added

removed removed

Lines of Context:
45
45
* Creates data directories and subversion repositories for all users, backing
46
46
  up directories for any existing users.
47
47
 
48
 
The script is executed with the following command from the IVLE source
49
 
directory::
 
48
The script is executed with the following command::
50
49
 
51
50
    sudo ivle-loadsampledata examples/db/sample.sql
52
51
 
54
53
   installation. Be sure you wish to do this.
55
54
 
56
55
.. note:: The script may fail at the "dropping database" phase if Apache or
57
 
   another process are using the database. It is best to *restart* (not stop)
58
 
   Apache before executing the script (``sudo /etc/init.d/apache2 restart``).
 
56
   another process are using the database. It is best to stop Apache before
 
57
   executing the script.
59
58
 
60
59
   If the database exists, but is not properly initialised, then the script
61
60
   may fail. In this case, you should manually run ``ivle-mountallusers -u``,
64
63
   If there are any existing users (including sample users from previous runs
65
64
   of the script), their files and subversion repos will be moved out of the
66
65
   way to a backup location, ``/var/lib/ivle/jails-removed-<date>/``.
67
 
   If you run this script regularly, your ``/var/lib/ivle/`` will become full
68
 
   of these backups, so you may wish to remove them often. However, they are
69
 
   typically fairly small (a few hundred kilobytes each), because they only
70
 
   contain user content, not the full jail image.
71
66
 
72
67
What is included
73
68
================
112
107
 
113
108
* admin/password: This user has administrative rights over the entire system.
114
109
* lecturer/password: This is a normal user, but is enrolled as a lecturer in
115
 
  ivle-101 (2009 semester 1) and ivle-102 (2009 semester 2).
 
110
  100101 (2009 semester 1) and 100102 (2009 semester 2).
116
111
* tutor/password: This is a normal user, but is enrolled as a tutor in
117
 
  ivle-102 (2009 semester 2).
118
 
* studenta/password: This is a normal user, enrolled in ivle-101 (2009
119
 
  semester 1) and ivle-102 (2009 semester 2).
120
 
* studentb/password: This is a normal user, enrolled in ivle-102 (2009
121
 
  semester 2). This student has not yet accepted the Terms of Service, so does
122
 
  not have a jail created, etc.
 
112
  100102 (2009 semester 2).
 
113
* studenta/password: This is a normal user, enrolled in 100101 (2009 semester
 
114
  1) and 100102 (2009 semester 2).
 
115
* studentb/password: This is a normal user, enrolled in 100102 (2009 semester
 
116
  2). This student has not yet accepted the Terms of Service, so does not have
 
117
  a jail created, etc.
123
118
 
124
119
.. note:: For the first three users, the Subversion password is also
125
120
   "password". This means it is possible to access their SVN repository
130
125
   When studentb logs in for the first time, his SVN repository is created,
131
126
   and given a random password.
132
127
 
133
 
Files
134
 
-----
135
 
 
136
 
The repository for user "studenta" has a few sample files. All of the
137
 
directories must be checked out (using the Checkout button) before the files
138
 
can be seen from the IVLE application.
139
 
 
140
 
* :file:`stuff/Welcome to IVLE.html`: A simple web page, which can be
141
 
  displayed with the "Serve" command.
142
 
* :file:`stuff/hello.py`: A simple Python script, which can be executed with
143
 
  the "Serve" command. This file has a few edits in its revision history.
144
 
* :file:`ivle-102/mywork/phase1.html`: A file for a student's project
145
 
  submission.
146
 
* :file:`group1/phase2.html`: A file for a group project submission. This
147
 
  contains edits by both studenta and studentb, and is also accessible if
148
 
  logged in as studentb.
149
 
 
150
128
Projects
151
129
--------
152
130
 
153
 
The subject ivle-102 (2009 semester 2) has two project sets and three
154
 
projects. This demonstrates the relationship between project sets and
155
 
projects.
 
131
The subject 100102 has two project sets and three projects. This demonstrates
 
132
the relationship between project sets and projects.
156
133
 
157
134
The first project set is a solo project set (every student works by
158
135
themselves on all projects). It has one project in it.
162
139
two projects in it, demonstrating that the students get to keep their group
163
140
(including all of the group files) across the two projects in this set.
164
141
 
165
 
Projects 1 and 2 have their due date set in the year 3009, so they will always
166
 
be submittable. Project 3 was due in 2009, so it has already closed.
167
 
 
168
142
Finally, there is a single group for projects 2 and 3, which has the students
169
143
studenta and studentb enlisted.
170
144
 
171
 
Exercises
172
 
---------
173
 
 
174
 
There are two sample exercises, ``hello``, which prompts the user to write
175
 
a simple Hello world program, and ``factorial``, which prompts the user to
176
 
write a factorial function and tests its correctness.
177
 
 
178
 
Both exercises have realistic test suites, taking advantage of most of the
179
 
features of the IVLE exercise testing framework. For example, ``hello`` uses a
180
 
regular expression to test whether the user has got it almost right, and gives
181
 
them encouraging feedback.
182
 
 
183
 
Worksheets
184
 
----------
185
 
 
186
 
There is currently a single worksheet in the subject ivle-102 (2009 semester
187
 
2). It embeds the exercises ``hello`` and ``factorial``.
188
 
 
189
145
Updating the sample data
190
146
========================
191
147
 
199
155
Then check the diff. You may hand-edit the SQL file, but only for the purpose
200
156
of fixing up unsightly data -- it should be possible to reload from the script
201
157
and re-export with no diff.
202
 
 
203
 
If the contents of the Subversion repositories have changed, run this
204
 
command::
205
 
 
206
 
    svnadmin dump /var/lib/ivle/svn/repositories/<repo> > examples/userrepos/<dumpfile>