Collaborative Editing: Working with the Ubuntu Desktop Course Files

This is a step-by-step guide for creating a branch of the Ubuntu Desktop Course and working on it. The Ubuntu Desktop course is hosted on Launchpad in a bazaar repository (https://launchpad.net/ubuntu-desktop-course). If you want to READ the Ubuntu Desktop Course files, you do not need to get the source files from Launchpad. This is for people who would like to update the files and submit their changes back to the project. You may download a PDF version of the Ubuntu Desktop Course, ready for printing or reading, from the main page for this project.

Step 1. Download and install Bazaar

To keep track of the changes in the Ubuntu Desktop Course, we are using Launchpad and Bazaar. If you prefer, you may contribute your requested changes through the Wiki tasks page. Bazaar is a "version control system." You can think of it as a big UNDO button for your own work, but also a relationship counselor for files. In other words: it is a tool that allows you to integrate changes made between many different authors, and also one that allows you to UNDO mistakes. The command line utility for Bazaar appears to be the most stable at this time; however, you may wish to try one of the other programs listed on http://bazaar-vcs.org/Download.

At this stage you might also update or replace screen shots. As long as the file name stays the same, it will automatically be included in your updates. If you need to add new screen shots, please consult the team before proceeding.

Step 4. Save your changes

First you must "commit" your changes to your local history for the project. Committing a change does not upload the changes to the main project. Commit after every logical change (for example: after the update of a paragraph or list). Use sensible commit messages. If you ever want to "undo" a change you will use these commit messages. The person who is integrating your changes will also use the commit message to determine if your change should be accepted.

Step 5. Tell Launchpad who you are

For the next step you will need tell Launchpad who you are. There is a detailed tutorial on https://help.launchpad.net/YourAccount/CreatingAnSSHKeyPair. You only need to do this step once, but it will take a few minutes to complete. ... Now that you have connected your Launchpad account to your computer, you must also tell Bazaar about your Launchpad account:

$ bzr launchpad-login <LAUNCHPADUSERNAME>

Step 6. Publish your branch

In this step you will upload your changes to the project. You will not overwrite anything! Don't panic! After this step you will make a request to have your changes merged into the main project. Someone will review your work before accepting the changes into the main project. From your branch directory use the following command:

$ bzr push lp:~YOURLAUNCHPADNAME/ubuntu-desktop-course/CODENAME

Of course you don't really need to use a "codename." This is the name of the branch that will be created for the Training Team to merge in your changes. You can be descriptive here (but using only letters and hyphens). For example, your CODENAME might be: revised-ch1. Please note that a CODENAME is really a "branch name."

Converting XML to PDF

If you are not using OpenOffice.org to make your changes, and you would like to create a PDF to proof read the course, you will need to install more tools. The following packages are required to convert XML to: docbook-xsl, xsltproc, dblatex, and make. You must also download the source files for the course from the Launchpad repository. Instructions are included in the previous section.

Installing packages with Synaptic

Navigate to System, Administration, Synaptic Package Manager

Using the search function find the packages to install (docbook-xsl, xsltproc, dblatex, and make).

Enable the necessary packages by placing a check mark next to each.

Apply the changes.

Installing packages from the command line

If you prefer, you can install the necessary packages from the command line. These steps are an alternative to using Synaptic. You do not need to use both methods.

$ sudo apt-get install docbook-xsl xsltproc dblatex make

Making the PDFs

Once you have the necessary packages you may use the "Makefile" to create PDFs. The following steps must be run from the command line.

Start translating in the language of your choice (note that if you are not a member of the Ubuntu Translators group for your language, you might need to contact them to review and accept your translation suggestions. You can also consider joining them)

Get back to the "Please choose customization action" window, select "Continue building" and klick on <OK>...

After a while you will find the remastered ISO-Image file as $HOME/tmp/remaster-new-files/livecd.iso (780 MByte).

Burn livecd.iso on a DVD(*) and then boot from this DVD...

You will see an "Ubuntu_Desktop_Course.pdf" icon on the desktop. Klick on the icon to open the Ubuntu Desktop Course.

(*)BE AWARE: If you want to burn livecd.iso on a CD the size of the file has to be less than 700 MByte. To achieve this select "Run package manager" in the "Please choose customization action" window of the uck-gui and remove some software packages you don't need.

HOWTO Add Drop-Shadow to Screen Shots

The current documentation recommends using GIMP for adding drop-shadow to screenshots manually. The script below adds drop-shadow to multiple files in batch, very quickly.

Gotchas

The script seems to barf if there are spaces in the filename.

You may need to logout and back in again after creating the bin folder, in order for it to be added to your PATH.

It appends the word 'shadow' in front of the filenames, which means you'll then need to rename them after. I'll work on changing that.

Installing the script

Install pngnq (a pre-requisite this script can use).

sudo apt-get install pngnq

Make a folder in your home directory called 'bin' to put the script in

Note: This folder has special significance in that if it exists it will be pre-pended onto the search path. This means if scripts/commands exist in this folder it will be possible to execute them from anywhere.

Download the shade.sh script attached to this page and save it to ~/bin.

Make sure it's executable.

Navigate to ~/bin in the file browser, right click shade.sh, select Permissions tab and choose 'Allow executing file as program'.

Using the script

Open a terminal (Applications --> Accessories --> Terminal)

Navigate to the folder containing the screenshots to have drop-shadow added ( cd ~/foldername )

Execute the shade script

shade.sh *.png

You should end up with new images prefixed with "shadow", which have the drop-shadow applied.