~silnrsi/smith/+git/designspacedocument-master:relative-paths

Last commit made on 2017-02-06
Get this branch:
git clone -b relative-paths https://git.launchpad.net/~silnrsi/smith/+git/designspacedocument-master

Branch merges

Branch information

Name:
relative-paths
Repository:
lp:~silnrsi/smith/+git/designspacedocument-master

Recent commits

6ba727b... by Erik <email address hidden>

More testcases for the relaive path processing.

1dd261f... by Erik <email address hidden>

Add comment.

6e724af... by Erik <email address hidden>

Clarified how designSpaceDocument object handles the filename and path attributes of the descriptors.

e102c5e... by Erik <email address hidden>

Tests to verify the handling of filename and path attrs.

13abae9... by Erik <email address hidden>

New "filename" attribute for source and instance descriptor objects that contains the relative path to the ufo.

So we have:
descriptor.filename: the path to the UFO, relative to the documentpath
descriptor.path: the resolved, absolute path to the UFO

This means we have to be aware of a couple of situations, described in updatePaths() and testPatgNameResolve().
Case 1: both filename and path attributes are None. Action: write the descriptor as is, without filename attr.
Case 2: filename attribute points somewhere, but the path attribute is None. So we can't actually verify if the UFO really exists, but we don't have to. Action: write the filename attribute as is. We could calculate a new path though.
Case 3: filename attribute is None, path attribute has a path. So there is no legacy value for filename that we need to look out for. Action: we can calculate a new relative path and store that in filename.
Case 4: filename and path attributes are not None, but they're in conflict, pointing to different places/ So the absolute path of the UFO and the absolute path of the document produce a different relative path than is stored in filename. One of them must be wrong.

When a new filename is set, make sure to set the path attribute to None and vice versa.

91d4b89... by Erik <email address hidden>

filename attr to store the actual string of the relative path. path attr to store the absolute path to the file (if we can find it)

146bcd0... by Erik <email address hidden>

Option to only process specific glyphnames in ufoProcessor.

659a79f... by Erik <email address hidden>

Store the designspace location in the instance lib.

9da2297... by Erik <email address hidden>

Forgot to check these in.

5ef9022... by Erik <email address hidden>

Adds a list for reporting problems that were small enough not to stop generating, but big enough not to ignore.