LocalizedCDImageTools

Differences between revisions 1 and 2
Revision 1 as of 2011-05-18 14:41:19
Size: 4030
Editor: p549B360F
Comment: initial spec
Revision 2 as of 2011-05-18 15:39:31
Size: 7029
Editor: p549B360F
Comment:
Deletions are marked like this. Additions are marked like this.
Line 12: Line 12:
Create a set of tools for providing these as ubuntu-l10n-<language> addon packages (as declarative as possible), and build CD images with this extra customization package. Create a set of tools for providing these as `ubuntu-l10n-`''language'' addon packages (as declarative as possible), and build CD images with this extra customization package. Through this spec, these packages will be referred to as '''loco packages'''.
Line 24: Line 24:
By providing an official method for localizing CD images we want to make these Loco efforts both more visible and also much easier to implement. By providing an official method for localizing CD images we want to make these Loco efforts both more visible and also much easier to implement. So far we have not made much use of the knowledge that Loco teams have, they are in a much better position than the core developers to know what should be adapted for their region.
Line 30: Line 30:
 * Li downloads the "Ubuntu Chinese Edition" from `cdimage.ubuntu.com` (note that this is only a strawman name, CD mirroring is not part of this spec). gfxboot, ubiquity, and the live session start in Simplified Chinese with the sunpinyin ibus input method ready and active. She opens Firefox and clicks on the "DWNews.com" bookmark in the toolbar (note that this is just an example), a popular Chinese news site. She opens the chat window and is able to add her QQ account.  * Li downloads the "Ubuntu Chinese Edition" from `cdimage.ubuntu.com` (note that this is only a strawman name, CD mirroring is not part of this spec). gfxboot, ubiquity, and the live session start in Simplified Chinese with the sunpinyin ibus input method ready and active. She opens Firefox and clicks on the "DWNews.com" (note that this is just an example) bookmark in the toolbar, a popular Chinese news site. She opens the chat window and is able to add her QQ account.
Line 32: Line 32:
 * Didier already has an official Ubuntu 11.10 CD. He chooses "French" in Ubiquity,  * Didier already has an official Ubuntu 11.10 CD. He chooses "French" in Ubiquity. Since it is connected to the Internet, Ubiquity installs the French specific localization settings automatically. (''Note: This might become an option in the UI''.)

 * Martin already has a 10.04 LTS installation which he just upgraded to 11.10. In software-center he selects the "Deutsche regionale Anpassungen" package ("German regional adaptions") and ends up with the same localizations than a fresh 11.10 install would have applied.
Line 36: Line 38:
== Assumptions == == Scope ==

This specification only deals with the mechanics of declaring, packaging, and shipping localizations. In particular, the following aspects are not covered:

 * CD mirroring/hosting
 * The actual customizations for any particular language.
 * QA for the localized images.

This is also limited to settings which can be customized by just adding an additional loco package (plus its dependencies). In some cases we might modify Ubuntu packages to look in additional data/override files/directories, but we don't support package removal or code changes with this system. If changes of that scope are desired, they need to happen with custom engineering, just as today.
Line 40: Line 50:
Locale specific browser bookmarks, Unity launchers, radio stations in the music player, pre-configured ibus modules, For the initial version, the following default values will get customizable with loco packages:
Line 42: Line 52:
 * locale and language
 * Keyboard layout
 * Firefox bookmarks
 * Unity launchers
 * Radio stations in Banshee and Rhythmbox
 * Default Firefox search engine

Workflow:

 * Install `ubuntu-loco-kit`.
 * Run `ubuntu-loco-template fr` to generate a skeleton `ubuntu-l10n-fr` source package. This will have a minimal `debian/` directory, empty data directories (e. g. `firefox`), and a README which points to the documentation.
 * The user adds the data as flat files (e. g. `firefox/bookmarks.txt` or `desktop/background.jpg`), and runs `dch` to add a changelog entry.
 * Running `dpkg-buildpackage` will generate `ubuntu-l10n-fr_`''version''`_all.deb` with the data files shipped in the right locations, and maintainer scripts to set them up.
 * This package can then be uploaded to the Ubuntu archive, or kept in a PPA, as desired.
Line 45: Line 69:
This section should describe a plan of action (the "how") to implement the changes discussed. Could include subsections like: In the following sections, '''Source''' is the user-provided file in the loco package source, while '''Destination''' is where the loco binary package will ship it.
Line 47: Line 71:
=== UI Changes === The `ubuntu-loco-kit` package will provide a `dh_ubuntu_loco` debhelper program which will install all '''Source''' files into their destination location. With this, the logic can be maintained centrally in the `ubuntu-loco-kit` source, and the loco packages themselves only require a three-line boilerplate `debian/rules`. `ubuntu-loco-template` will create an appropriate `debian/control` with the language name in the package description etc. It will also provide a standard `debian/copyright` with no templating, which the user can customize manually if desired.
Line 49: Line 73:
Should cover changes required to the UI, or specific UI that is required to implement this === locale and language ===
Line 51: Line 75:
=== Code Changes === '''Source:''' `default/locale`
'''Destination:''' `/usr/share/pkgname/locale`
'''Behaviour:''' postinst snippet which puts it into /etc/default/locale, or updates it if that already exists.
Line 53: Line 79:
Code changes should include an overview of what needs to change, and in some cases even the specific details. `ubuntu-loco-template` pre-creates this file with sensible defaults.
Line 55: Line 81:
=== Migration === '''TODO:''' find out what needs to happen to pre-select language in gfxboot → Colin?
Line 57: Line 83:
Not necessary. === keyboard layout ===

'''Source:''' `default/keyboard`
'''Destination:''' grep out `XKB_{MODEL,LAYOUT,VARIANT,OPTIONS}=...` from `default/keyboard`, put the result into `/usr/share/pkgname/keyboard`.
'''Behaviour:''' postinst snippet which puts it into /etc/default/keyboard (wrapped in the standard commentary text), or updates it if that already exists.

`ubuntu-loco-template` pre-creates this file with sensible defaults.

'''TODO:''' find out what needs to happen to pre-select layout in gfxboot → Colin?

=== Firefox bookmarks ===

=== Unity launchers ===

=== Radio stations in Banshee and Rhythmbox ===

=== Default Firefox search engine ===
Line 61: Line 103:
It's important that we are able to test new features, and demonstrate them to users. Use this section to describe a short plan that anybody can follow that demonstrates the feature is working. This can then be used during testing, and to show off after release. Please add an entry to http://testcases.qa.ubuntu.com/Coverage/NewFeatures for tracking test coverage.

This need not be added or completed until the specification is nearing beta.
To be done when implementation is at beta.
Line 67: Line 107:
This should highlight any issues that should be addressed in further specifications, and not problems with the specification itself; since any specification with problems cannot be approved. None at the moment.
  • Launchpad Entry: desktop-o-loco-cds

  • Created: 2011-05-18

  • Contributors: Mark Shuttleworth, Didier Roche, Colin Watson, Kyle Nitzsche

  • Packages affected: ubiquity, cdimage, creation of new packages

Summary

Tools and a workflow to provide truly localized CD images. This goes beyond merely installing the right translations, we also want to provide localized default bookmarks, input methods, chat protocols, radio stations, or background images.

Create a set of tools for providing these as ubuntu-l10n-language addon packages (as declarative as possible), and build CD images with this extra customization package. Through this spec, these packages will be referred to as loco packages.

With this, concrete localization projects like desktop-o-qin-ubuntu-china will be a lot easier to implement.

Release Note

To be done when implementation is at beta.

Rationale

Our only action after the user chooses his locale is to install the matching language packs and support (dictionaries, etc.), but true localization goes way beyond that: Locos want to customize default bookmarks, locale specific chat protocols, or preconfigured ibus input method modules. Right now Locos both have to figure out how to customize these settings by themselves, which is not easy and also rather intrusive sometimes. Often these changes can't be preserved during upgrades, and there is only little QA and advertising happening on those images.

By providing an official method for localizing CD images we want to make these Loco efforts both more visible and also much easier to implement. So far we have not made much use of the knowledge that Loco teams have, they are in a much better position than the core developers to know what should be adapted for their region.

This also mitigates the eternal CD size resource conflicts on which language packs to ship on the official CD releases.

User stories

  • Li downloads the "Ubuntu Chinese Edition" from cdimage.ubuntu.com (note that this is only a strawman name, CD mirroring is not part of this spec). gfxboot, ubiquity, and the live session start in Simplified Chinese with the sunpinyin ibus input method ready and active. She opens Firefox and clicks on the "DWNews.com" (note that this is just an example) bookmark in the toolbar, a popular Chinese news site. She opens the chat window and is able to add her QQ account.

  • Didier already has an official Ubuntu 11.10 CD. He chooses "French" in Ubiquity. Since it is connected to the Internet, Ubiquity installs the French specific localization settings automatically. (Note: This might become an option in the UI.)

  • Martin already has a 10.04 LTS installation which he just upgraded to 11.10. In software-center he selects the "Deutsche regionale Anpassungen" package ("German regional adaptions") and ends up with the same localizations than a fresh 11.10 install would have applied.
  • Kyle prepares a customized version of Ubuntu for Compu1337, a large OEM. He prepares a compu1337-default-settings package as a copy of the ubuntu-l10n-template package, sticks in an appropriate background.jpg, and adds it to the project seeds. When booting the generated image, the default desktop background image shows a big Compu1337 logo.

Scope

This specification only deals with the mechanics of declaring, packaging, and shipping localizations. In particular, the following aspects are not covered:

  • CD mirroring/hosting
  • The actual customizations for any particular language.
  • QA for the localized images.

This is also limited to settings which can be customized by just adding an additional loco package (plus its dependencies). In some cases we might modify Ubuntu packages to look in additional data/override files/directories, but we don't support package removal or code changes with this system. If changes of that scope are desired, they need to happen with custom engineering, just as today.

Design

For the initial version, the following default values will get customizable with loco packages:

  • locale and language
  • Keyboard layout
  • Firefox bookmarks
  • Unity launchers
  • Radio stations in Banshee and Rhythmbox
  • Default Firefox search engine

Workflow:

  • Install ubuntu-loco-kit.

  • Run ubuntu-loco-template fr to generate a skeleton ubuntu-l10n-fr source package. This will have a minimal debian/ directory, empty data directories (e. g. firefox), and a README which points to the documentation.

  • The user adds the data as flat files (e. g. firefox/bookmarks.txt or desktop/background.jpg), and runs dch to add a changelog entry.

  • Running dpkg-buildpackage will generate ubuntu-l10n-fr_version_all.deb with the data files shipped in the right locations, and maintainer scripts to set them up.

  • This package can then be uploaded to the Ubuntu archive, or kept in a PPA, as desired.

Implementation

In the following sections, Source is the user-provided file in the loco package source, while Destination is where the loco binary package will ship it.

The ubuntu-loco-kit package will provide a dh_ubuntu_loco debhelper program which will install all Source files into their destination location. With this, the logic can be maintained centrally in the ubuntu-loco-kit source, and the loco packages themselves only require a three-line boilerplate debian/rules. ubuntu-loco-template will create an appropriate debian/control with the language name in the package description etc. It will also provide a standard debian/copyright with no templating, which the user can customize manually if desired.

locale and language

Source: default/locale Destination: /usr/share/pkgname/locale Behaviour: postinst snippet which puts it into /etc/default/locale, or updates it if that already exists.

ubuntu-loco-template pre-creates this file with sensible defaults.

TODO: find out what needs to happen to pre-select language in gfxboot → Colin?

keyboard layout

Source: default/keyboard Destination: grep out XKB_{MODEL,LAYOUT,VARIANT,OPTIONS}=... from default/keyboard, put the result into /usr/share/pkgname/keyboard. Behaviour: postinst snippet which puts it into /etc/default/keyboard (wrapped in the standard commentary text), or updates it if that already exists.

ubuntu-loco-template pre-creates this file with sensible defaults.

TODO: find out what needs to happen to pre-select layout in gfxboot → Colin?

Firefox bookmarks

Unity launchers

Radio stations in Banshee and Rhythmbox

Default Firefox search engine

Test/Demo Plan

To be done when implementation is at beta.

Unresolved issues

None at the moment.


CategorySpec

DesktopTeam/Specs/Oneiric/LocalizedCDImageTools (last edited 2011-10-29 18:06:45 by CPE-58-168-95-140)