Store version information

Bug #1023519 reported by Benji York
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
lpsetup
In Progress
High
Unassigned

Bug Description

We need lpsetup version information so future upgrade functionality can
use it to know what to do. Here are four incremental steps that can be
done:

- make init-host create /var/lib/lpsetup/[version]/; where "version" is
  the current lpsetup version number; this is a directory because we
  want to store information pertinent to each version inside.

- make /var/lib/lpsetup/[version]/originals/ hold original versions of
  modified files (as e.g.
  /var/lib/lpsetup/[version]/originals/etc/hosts)

- make easy to parse headers and footers in files we modify

- stash the argument data (namespace) values

This will be done in a time-box and will be considered done when at least
the first step is done and the allocated time has expired.

Related branches

Benji York (benji)
Changed in lpsetup:
assignee: nobody → Benji York (benji)
importance: Undecided → High
status: New → In Progress
Revision history for this message
Brad Crittenden (bac) wrote :

Adding snippets of IRC conversation here so it isn't lost:

gary_poster, benji: regarding versioning, it seems we need to keep track of 1) contents of deleted files, 2) names of modified files, and 3) names of added files on a per-version basis. when the version changes we can 1) restore the deleted files, 2) unmodify the ones we changed if we put fences around beginning and end of our changes, 3) remove the added files.

we cannot restore modified files to the original since the dev or system could've made other changes in the meantime. perhaps this is obvious and you've already noted it.

Benji York (benji)
Changed in lpsetup:
assignee: Benji York (benji) → nobody
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.