need the api key in Bdale's root too
[fw/altos] / Releasing
1 These are Bdale's notes on how to do a release.
2
3         git checkout master
4
5         - make sure the Google Maps API key is in the build chroot and root
6                 mkdir -p /var/cache/pbuilder/base.cow/opt/google /opt/google
7                 cp ~/altusmetrumllc/google-maps-api-key \
8                         /var/cache/pbuilder/base.cow/opt/google/maps-api-key
9                 ln -sf /home/bdale/altusmetrumllc/google-maps-api-key \
10                         /opt/google/maps-api-key
11
12         - make sure there is a doc/release-notes-<version>.xsl
13         - make sure that doc/altusmetrum.xsl has the right copyright year,
14           and add release to the revision history at the front (release notes
15           will be pulled in automatically)
16
17         - get a Google Maps API key and install it in
18           ~/altusmetrumllc/google-maps-api-key. If you don't have a
19           key, the app will still work, but downloading map tiles will
20           be slow, and you will only be able to download a limited
21           number per day.
22
23         - update the version in configure.ac
24         git log > ChangeLog
25         git commit -a
26
27         - make absolutely sure checked-out tree is "clean" 
28         - make absolutely sure the pdclib/ submodule is on the master branch,
29           up to date, and "clean"
30
31         - if this is an x.y release, then:
32                 git checkout -b branch-<version>
33                 git tag -a <version>
34                 - edit .git/gbp.conf to use branch-<version> as upstream
35
36         - if this is an x.y.z release, then:
37                 git checkout branch-<version>           # the x.y parts only
38                 git merge master
39                 git tag -a <version>                    # full x.y.z version
40
41         git checkout debian
42         git merge branch-<version>
43
44         - verify debian/changelog is "clean" ending in last release version
45         - craft a suitable debian/changelog entry, possibly using:
46         git-dch --release --new-version=<version>-1 --multimaint-merge
47
48         git commit -n debian/changelog -m "update changelog for Debian build"
49
50         - if this is a -1 release, then
51                 git-buildpackage --git-no-pristine-tar --git-submodules \
52                         --git-upstream-branch=branch-<version> \ # eg 1.3
53                         --git-upstream-tag=<version>             # eg 1.3.1
54                 pristine-tar commit \
55                         ../build-area/altos_<version>.orig.tar.gz \
56                         branch-<version>
57           else if this is not a -1 release
58                 git-buildpackage --git-submodules
59
60         git tag debian/<version>
61
62         - at this point we have packages in ~/debian/build-area/altos, now
63           we move on to the non-Debian part of the release process
64
65         make distclean
66
67         ./autogen.sh --with-fat-dir=/home/bdale/web/altusmetrum/AltOS/releases
68         make && make fat
69
70                 this pushes packages for each platform to web site
71
72         # store a stable copy of ARM binaries for production use
73         cp src/easymini-v1.0/*.elf \
74            src/telegps-v1.0/*.elf \
75            src/telemega-v1.0/*.elf \
76            src/telemetrum-v2.0/*.elf \
77            ~/altusmetrumllc/Binaries/
78         cp src/easymini-v1.0/flash-loader/*.elf \
79            src/telegps-v1.0/flash-loader/*.elf \
80            src/telemega-v1.0/flash-loader/*.elf \
81            src/telemetrum-v2.0/flash-loader/*.elf \
82            ~/altusmetrumllc/Binaries/loaders/
83         (cd ~/altusmetrumllc ; git add Binaries ; git commit -a) 
84
85         - copy the relevant release notes file from doc/ to 
86             /home/bdale/web/altusmetrum/AltOS/releases/<rev>
87
88         - create /home/bdale/web/altusmetrum/MicroPeak/releases/<rev>,
89           and move the MicroPeak installers from AltOS/releases to there
90                 
91         - create /home/bdale/web/altusmetrum/TeleGPS/releases/<rev>,
92           and move the MicroPeak installers from AltOS/releases to there
93                 
94         - go edit ~/web/altusmetrum/AltOS/releases/<rev>.mdwn, 
95           /home/bdale/web/altusmetrum/MicroPeak/releases/<rev>.mdwn, and
96           /home/bdale/web/altusmetrum/TeleGPS/releases/<rev>.mdwn, to 
97           include release date and explicit ref to dir contents so the 
98           web pages shows versioned links, commit and push
99
100         (cd doc ; make publish)
101
102                 this pushes fresh documents to the web site
103
104         sudo debian/rules clean
105         git push origin master branch-<version> debian pristine-tar
106         git push --tags
107
108                 push commits and leave the build tree in an uncluttered state
109
110 Testing before a release
111
112         To verify that a build works, the following need to be checked
113         on each platform:
114
115         1) Install package
116
117         2) Connect TM *and* TD devices. Verify that you can Monitor
118            Flight from the TD and Configure Telemetrum from the TM.
119
120         3) Replay Flight, using your favorite .eeprom file. Check
121            each tab, especially the 'Site Map' tab. Make sure the
122            sound works.
123
124         4) Graph Data. Graph a favorite .eeprom file. Make sure you
125            can zoom in on some region of the graph.