9 import fake_py2deb as py2deb
14 __appname__ = constants.__app_name__
15 __description__ = "Touch screen enhanced interface to the GoogleVoice/GrandCentral phone service"
16 __author__ = "Ed Page"
17 __email__ = "eopage@byu.net"
18 __version__ = constants.__version__
19 __build__ = constants.__build__
22 * Fremantle Prep: Simplified menus in prep for no menu or the Fremantle App Menu
23 * Fremantle Prep: Implemented a work around for https://bugs.maemo.org/show_bug.cgi?id=4957
24 * Fremantle Prep: Switched to touch selectors for notification time, callback number, and contact addressbook
25 * Fremantle Prep: Making various widgets pannable rather than scrollable
26 * Fremantle Prep: CTRL-V added for paste for Dialpad
27 * Fremantle Prep: CTRL-Enter added for fullscreen
28 * UI Tweak: Phone selection and SMS Message dialogs now highlight the last message and are easier to scroll
29 * UI Tweak: Tweaked sizes of stuff on recent tab
30 * UI Tweak: Added notifcations for various things like login and dialing
31 * UI Tweak: Switch to accounts tab when logging in and callback is blank as a sublte hint to configure it
32 * UI Tweak: Switch to accounts tab on failed login to remind the user they are not logged in
33 * Packaging: Disables notifications on uninstall
34 * Packaging: Including a vastly improved py2deb for better packages (icons on package, etc)
35 * Debugging: Adding seperator between dialcentral launches in log
36 * Bug Fix: Made startup more error resistant
37 * Bug Fix: some dependencies for Diablo
38 * Bug Fix: Error on refreshing tabs when not logged in
39 * Bug Fix: #4471 Notification Checkbox Won't Stay Checked (hour roll over error)
40 * Bug Fix: Phone numbers in voicemails wouldn't appear
41 * Bug Fix: category for Fremantle/Diablo
42 * Bug Fix: needing to manually create "~/.dialcentral" due to earlier logging changes
43 * Bug Fix: dependencies for fremantle
44 * Bug Fix: Issues when trying to stack error messages
45 * Bug Fix: Python2.6 deprecates some stuff I did
46 * Bug Fix: On refreshing the Accounts tab, the callback number resets to the number from startup
49 * Contacts Tab remembers the last address book viewed on restart
50 * Applied some suggested changes for being more thumb friendly
51 * Messaging Dialog auto-scrolls to bottom
52 * Removed GrandCentral support
53 * Numbers can now be entered immediately, before login
54 * Bug Fix: Not clearing the entered number on sending an SMS
55 * Bug Fix: Disabling SMS button when logged off
56 * Bug Fix: Trying to make SMS and phone selection dialogs more readable
57 * Bug Fix: Adding some more thumb scrollbars
60 * "Back" button and tabs now visually indicate when they've entered a "hold" state
61 * Fixed the duplicate title on Maemo
62 * Removing some device connection observer code due to high bug to low benefit ratio
63 * Notification support
64 * Fixed a bug from 1.0.3 where once you refreshed a tab by holding on it, every tab would then be forced to refresh
67 * Holding down a tab for a second will now force a refresh
68 * Fixed a bug dealing with overzealously refreshing the contacts tab
69 * Finding some undescriptive errors and made them more descriptive
70 * Swapped the order GrandCentral and GoogleVoice appear in login window
71 * Fixed the "Recent" and "Message" tabs, google changed things on me again
75 * Random performance improvements
78 * Fixed a voicemail transcripts due to a GoogleVoice change
81 * Added names to the recent tab for GoogleVoice
85 * Display of names for messages tab
86 * Condensed messages/recent's date column
89 * Added columns to recent view and messages view to help seperate messages
90 * Attempted refreshing session on dial/sms send
92 * Minor bug fixes as usual
95 * Switched to Force Refresh for when wanting to check for more messages
96 * Removed timeouts that forced refreshes on various tabs
97 * Added support for a settings file, fairly primitive right now
99 * Lots of major and minor bug fixes
102 * Experimenting with the tabs being on the side
103 * Now the phone selector is used always, even if there is just one phone number
104 * Added a Messages Tab, which displays SMS and Voicemail messages
105 * Added option to send SMS messages
108 * Fixed a login issue due to Google changing their webpage
111 * Misc Bug fixes and experiments
114 * Removed the much disliked contact source ID
115 * Added saving of callback number when using GoogleVoice
116 * Got proper formatting on things ("&" rather than "&")
119 0.9.2 - "Two heads are better than one"
120 * Adding of UI to switch between GC and GV
121 * Minimized flashing the dial button between grayed out and not on startup
124 0.9.1 - "Get your hands off that"
125 * GoogleVoice Support, what a pain
126 * More flexible CSV support. It now checks the header row for what column name/number are in
127 * Experimenting with faster startup by caching PYC files with the package
128 * Fixing of some bad error handling
129 * More debug output for when people run into issues
131 0.9.0 - "Slick as snot"
132 * Caching of contacts
133 * Refactoring to make working with the code easier
134 * Filesystem backed contacts but currently only supporting a specific csv format
135 * Gracefully handle lack of connection and connection transitions
136 * Gracefully handle failed login
137 * A tiny bit better error reporting
139 0.8.3 - "Extras Love"
140 * Version bump fighting the extras autobuilder, I hope this works
142 0.8.2 - "Feed is for horses, so what about feedback?"
144 * many more smaller fixes
147 * Thumb scrollbars ( Kudos Khertan )
149 0.8.0 - "Spit and polish"
150 * Addressbook support
151 * threaded networking for better interactivity
152 * Hold down back to clear number
153 * Standard about dialog
154 * many more smaller fixes
158 __postinstall__ = """#!/bin/sh -e
160 gtk-update-icon-cache -f /usr/share/icons/hicolor
163 __preremove__ = """#!/bin/sh -e
165 python /usr/lib/dialcentral/alarm_handler.py -d || true
169 def find_files(path):
170 for root, dirs, files in os.walk(path):
172 if file.startswith("src-"):
173 fileParts = file.split("-")
174 unused, relPathParts, newName = fileParts[0], fileParts[1:-1], fileParts[-1]
175 assert unused == "src"
176 relPath = os.sep.join(relPathParts)
177 yield relPath, file, newName
180 def unflatten_files(files):
182 for relPath, oldName, newName in files:
185 d[relPath].append((oldName, newName))
189 def build_package(distribution):
191 os.chdir(os.path.dirname(sys.argv[0]))
195 py2deb.Py2deb.SECTIONS = py2deb.SECTIONS_BY_POLICY[distribution]
196 p = py2deb.Py2deb(__appname__)
197 p.description = __description__
198 p.upgradeDescription = __changelog__.split("\n\n", 1)[0]
199 p.author = __author__
202 p.depends = ", ".join([
203 "python2.6 | python2.5",
204 "python-gtk2 | python2.5-gtk2",
205 "python-xml | python2.5-xml",
206 "python-dbus | python2.5-dbus",
208 maemoSpecificDepends = ", python-osso | python2.5-osso, python-hildon | python2.5-hildon"
210 "debian": ", python-glade2",
211 "chinook": maemoSpecificDepends,
212 "diablo": maemoSpecificDepends,
213 "fremantle": maemoSpecificDepends + ", python-glade2",
214 "mer": maemoSpecificDepends + ", python-glade2",
216 p.recommends = ", ".join([
220 "chinook": "communication",
221 "diablo": "user/network",
222 "fremantle": "user/network",
223 "mer": "user/network",
227 p.distribution = "chinook diablo fremantle mer debian"
228 p.repository = "extras"
229 p.changelog = __changelog__
230 p.postinstall = __postinstall__
231 p.preremove = __preremove__
233 "debian": "26x26-dialcentral.png",
234 "chinook": "26x26-dialcentral.png",
235 "diablo": "26x26-dialcentral.png",
236 "fremantle": "64x64-dialcentral.png", # Fremantle natively uses 48x48
237 "mer": "64x64-dialcentral.png",
239 p["/usr/bin"] = [ "dialcentral.py" ]
240 for relPath, files in unflatten_files(find_files(".")).iteritems():
241 fullPath = "/usr/lib/dialcentral"
243 fullPath += os.sep+relPath
245 "|".join((oldName, newName))
246 for (oldName, newName) in files
248 p["/usr/share/applications/hildon"] = ["dialcentral.desktop"]
249 p["/usr/share/icons/hicolor/26x26/hildon"] = ["26x26-dialcentral.png|dialcentral.png"]
250 p["/usr/share/icons/hicolor/64x64/hildon"] = ["64x64-dialcentral.png|dialcentral.png"]
251 p["/usr/share/icons/hicolor/scalable/hildon"] = ["scale-dialcentral.png|dialcentral.png"]
255 version="%s-%s" % (__version__, __build__),
256 changelog=__changelog__,
262 print "Building for %s finished" % distribution
265 if __name__ == "__main__":
266 if len(sys.argv) > 1:
272 if optparse is not None:
273 parser = optparse.OptionParser()
274 (commandOptions, commandArgs) = parser.parse_args()
277 commandArgs = ["diablo"]
278 build_package(commandArgs[0])