9 import fake_py2deb as py2deb
14 __appname__ = constants.__app_name__
15 __description__ = """Touch screen enhanced interface to the GoogleVoice phone service"
17 * Dialpad for quick call
18 * Checking voicemails, texts, call history
20 * Notification support for texts, voicemail, and/or missed calls
22 Homepage: http://gc-dialer.garage.maemo.org/
24 __author__ = "Ed Page"
25 __email__ = "eopage@byu.net"
26 __version__ = constants.__version__
27 __build__ = constants.__build__
30 * Sped up login time by delay loading contact list
31 * Sped up login when you do not have a cookie file (first launch)
32 * Ability to narrow down messages either by type or status
33 * Fremantle: Notification Support including testing of custom notifications
34 * UI Tweak: Cut down the number of times the login dialog is needlessly displayed
35 * Bug Fix: Switching to accounts tab when callback is blank
36 * Bug Fix: Corrupt cookie files prevent login
37 * Bug Fix: Logging in without credentials through cookies
38 * Debugging: Log contents now accessible through Ctrl+l
41 * Sped up various login cases
42 * Added descriptions to the callback numbers
43 * Collapsed conversations in the messages tab
44 * Give access to all of a contacts numbers when launching dialog from Recent or Messages tabs
45 * UI Tweak: Added more login status notifications
46 * UI Tweak: When no characters are entered, you can't send a text
47 * UI Tweak: Trying to consolidate dialogs by combining phone selection and SMS entry
48 * UI Tweak: Removed "Select" button from SMS Dialog
49 * UI Tweak: Increased the size of the SMS dialog
50 * UI Tweak: Disable "Dial" when a text has started to be entered
51 * UI Tweak: Move the sms history scroll bars around the whole sms conversation, giving more room to see with
52 * UI Tweak: Trying to be clearer by switching the login dialog from "Close" to "Cancel"
53 * UI Tweak: Remove auto-cancel of login after X attempts
54 * Bug Fix: Expanded the types of the Enter key that are supported for going to full screen
55 * Bug Fix: Random people were reporting login issues
56 * Bug Fix: Hardened against issues with grabbing possible callback numbers
57 * Bug Fix: Fremantle GTK doesn't allow TreeView rows to be selected, so row-activated handlers have to read their path
58 * Bug Fix: Fremantle PyMaemo doesn't provide a function Mer PyMaemo does, created a hack to be workable on both
59 * Bug Fix: Once PyMaemo supports thumb button sizes, setting that for all of the random buttons
60 * Bug Fix: When debugging hildonization, dialogs weren't closing
61 * Bug Fix: Not properly hildonizing some code
62 * Bug Fix: Attempting a hack to fix redirect issues for people
63 * Debugging: Improved logging output
64 * Debugging: Printing page when can't get a callback number
65 * Debugging: Included stuff to create all the debug files
68 * Fremantle Prep: Simplified menus in prep for no menu or the Fremantle App Menu
69 * Fremantle Prep: Implemented a work around for https://bugs.maemo.org/show_bug.cgi?id=4957
70 * Fremantle Prep: Switched to touch selectors for notification time, callback number, and contact addressbook
71 * Fremantle Prep: Making various widgets pannable rather than scrollable
72 * Fremantle Prep: CTRL-V added for paste for Dialpad
73 * Fremantle Prep: CTRL-Enter added for fullscreen
74 * UI Tweak: Phone selection and SMS Message dialogs now highlight the last message and are easier to scroll
75 * UI Tweak: Tweaked sizes of stuff on recent tab
76 * UI Tweak: Added notifcations for various things like login and dialing
77 * UI Tweak: Switch to accounts tab when logging in and callback is blank as a sublte hint to configure it
78 * UI Tweak: Switch to accounts tab on failed login to remind the user they are not logged in
79 * Packaging: Disables notifications on uninstall
80 * Packaging: Including a vastly improved py2deb for better packages (icons on package, etc)
81 * Debugging: Adding seperator between dialcentral launches in log
82 * Bug Fix: Made startup more error resistant
83 * Bug Fix: some dependencies for Diablo
84 * Bug Fix: Error on refreshing tabs when not logged in
85 * Bug Fix: #4471 Notification Checkbox Won't Stay Checked (hour roll over error)
86 * Bug Fix: Phone numbers in voicemails wouldn't appear
87 * Bug Fix: category for Fremantle/Diablo
88 * Bug Fix: needing to manually create "~/.dialcentral" due to earlier logging changes
89 * Bug Fix: dependencies for fremantle
90 * Bug Fix: Issues when trying to stack error messages
91 * Bug Fix: Python2.6 deprecates some stuff I did
92 * Bug Fix: On refreshing the Accounts tab, the callback number resets to the number from startup
95 * Contacts Tab remembers the last address book viewed on restart
96 * Applied some suggested changes for being more thumb friendly
97 * Messaging Dialog auto-scrolls to bottom
98 * Removed GrandCentral support
99 * Numbers can now be entered immediately, before login
100 * Bug Fix: Not clearing the entered number on sending an SMS
101 * Bug Fix: Disabling SMS button when logged off
102 * Bug Fix: Trying to make SMS and phone selection dialogs more readable
103 * Bug Fix: Adding some more thumb scrollbars
106 * "Back" button and tabs now visually indicate when they've entered a "hold" state
107 * Fixed the duplicate title on Maemo
108 * Removing some device connection observer code due to high bug to low benefit ratio
109 * Notification support
110 * 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
113 * Holding down a tab for a second will now force a refresh
114 * Fixed a bug dealing with overzealously refreshing the contacts tab
115 * Finding some undescriptive errors and made them more descriptive
116 * Swapped the order GrandCentral and GoogleVoice appear in login window
117 * Fixed the "Recent" and "Message" tabs, google changed things on me again
121 * Random performance improvements
124 * Fixed a voicemail transcripts due to a GoogleVoice change
127 * Added names to the recent tab for GoogleVoice
131 * Display of names for messages tab
132 * Condensed messages/recent's date column
135 * Added columns to recent view and messages view to help seperate messages
136 * Attempted refreshing session on dial/sms send
138 * Minor bug fixes as usual
141 * Switched to Force Refresh for when wanting to check for more messages
142 * Removed timeouts that forced refreshes on various tabs
143 * Added support for a settings file, fairly primitive right now
144 * Fixed Maemo Support
145 * Lots of major and minor bug fixes
148 * Experimenting with the tabs being on the side
149 * Now the phone selector is used always, even if there is just one phone number
150 * Added a Messages Tab, which displays SMS and Voicemail messages
151 * Added option to send SMS messages
154 * Fixed a login issue due to Google changing their webpage
157 * Misc Bug fixes and experiments
160 * Removed the much disliked contact source ID
161 * Added saving of callback number when using GoogleVoice
162 * Got proper formatting on things ("&" rather than "&")
165 0.9.2 - "Two heads are better than one"
166 * Adding of UI to switch between GC and GV
167 * Minimized flashing the dial button between grayed out and not on startup
170 0.9.1 - "Get your hands off that"
171 * GoogleVoice Support, what a pain
172 * More flexible CSV support. It now checks the header row for what column name/number are in
173 * Experimenting with faster startup by caching PYC files with the package
174 * Fixing of some bad error handling
175 * More debug output for when people run into issues
177 0.9.0 - "Slick as snot"
178 * Caching of contacts
179 * Refactoring to make working with the code easier
180 * Filesystem backed contacts but currently only supporting a specific csv format
181 * Gracefully handle lack of connection and connection transitions
182 * Gracefully handle failed login
183 * A tiny bit better error reporting
185 0.8.3 - "Extras Love"
186 * Version bump fighting the extras autobuilder, I hope this works
188 0.8.2 - "Feed is for horses, so what about feedback?"
190 * many more smaller fixes
193 * Thumb scrollbars ( Kudos Khertan )
195 0.8.0 - "Spit and polish"
196 * Addressbook support
197 * threaded networking for better interactivity
198 * Hold down back to clear number
199 * Standard about dialog
200 * many more smaller fixes
204 __postinstall__ = """#!/bin/sh -e
206 gtk-update-icon-cache -f /usr/share/icons/hicolor
207 rm -f ~/.dialcentral/dialcentral.log
210 __preremove__ = """#!/bin/sh -e
212 python /usr/lib/dialcentral/alarm_handler.py -d || true
216 def find_files(path):
217 for root, dirs, files in os.walk(path):
219 if file.startswith("src-"):
220 fileParts = file.split("-")
221 unused, relPathParts, newName = fileParts[0], fileParts[1:-1], fileParts[-1]
222 assert unused == "src"
223 relPath = os.sep.join(relPathParts)
224 yield relPath, file, newName
227 def unflatten_files(files):
229 for relPath, oldName, newName in files:
232 d[relPath].append((oldName, newName))
236 def build_package(distribution):
238 os.chdir(os.path.dirname(sys.argv[0]))
242 py2deb.Py2deb.SECTIONS = py2deb.SECTIONS_BY_POLICY[distribution]
243 p = py2deb.Py2deb(__appname__)
244 p.prettyName = constants.__pretty_app_name__
245 p.description = __description__
246 p.bugTracker = "https://bugs.maemo.org/enter_bug.cgi?product=Dialcentral"
247 #p.upgradeDescription = __changelog__.split("\n\n", 1)[0]
248 p.author = __author__
251 p.depends = ", ".join([
252 "python2.6 | python2.5",
253 "python-gtk2 | python2.5-gtk2",
254 "python-xml | python2.5-xml",
255 "python-dbus | python2.5-dbus",
257 maemoSpecificDepends = ", python-osso | python2.5-osso, python-hildon | python2.5-hildon"
259 "debian": ", python-glade2",
260 "chinook": maemoSpecificDepends,
261 "diablo": maemoSpecificDepends,
262 "fremantle": maemoSpecificDepends + ", python-glade2, python-alarm",
263 "mer": maemoSpecificDepends + ", python-glade2",
265 p.recommends = ", ".join([
269 "chinook": "communication",
270 "diablo": "user/network",
271 "fremantle": "user/network",
272 "mer": "user/network",
276 p.distribution = "chinook diablo fremantle mer debian"
277 p.repository = "extras"
278 p.changelog = __changelog__
279 p.postinstall = __postinstall__
280 p.preremove = __preremove__
282 "debian": "26x26-dialcentral.png",
283 "chinook": "26x26-dialcentral.png",
284 "diablo": "26x26-dialcentral.png",
285 "fremantle": "64x64-dialcentral.png", # Fremantle natively uses 48x48
286 "mer": "64x64-dialcentral.png",
288 p["/usr/bin"] = [ "dialcentral.py" ]
289 for relPath, files in unflatten_files(find_files(".")).iteritems():
290 fullPath = "/usr/lib/dialcentral"
292 fullPath += os.sep+relPath
294 "|".join((oldName, newName))
295 for (oldName, newName) in files
297 p["/usr/share/applications/hildon"] = ["dialcentral.desktop"]
298 p["/usr/share/icons/hicolor/26x26/hildon"] = ["26x26-dialcentral.png|dialcentral.png"]
299 p["/usr/share/icons/hicolor/64x64/hildon"] = ["64x64-dialcentral.png|dialcentral.png"]
300 p["/usr/share/icons/hicolor/scalable/hildon"] = ["scale-dialcentral.png|dialcentral.png"]
304 version="%s-%s" % (__version__, __build__),
305 changelog=__changelog__,
311 print "Building for %s finished" % distribution
314 if __name__ == "__main__":
315 if len(sys.argv) > 1:
321 if optparse is not None:
322 parser = optparse.OptionParser()
323 (commandOptions, commandArgs) = parser.parse_args()
326 commandArgs = ["diablo"]
327 build_package(commandArgs[0])