« November 2007 | Archives index | January 2008 »
December 28, 2007
Trim trailing newline (snippets, 938951f)
Make sure the abbreviated hash doesn't have a trailing newline.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 2:02 PM
Parenthesize arguments to silence Ruby warnings (snippets, e0435ce)
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 1:57 PM
Add README to distribution (Synergy, 7ae6b07)
A README is probably necessary given the number of important changes in the 3.5 release (principally the change of format from System Preferences pane to standalone application, and the new minimum system version requirement).
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 1:55 PM
Add LSMinimumSystemVersion to Info.plist (Synergy, 10c1f84)
The installer used to advise the user if the system did match the minimum requirements; now that this is a standalone application we instead rely on the system to do so thanks to the LSMinimumSystemVersion key in the Info property list.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 1:31 PM
Multiple fixes for Leopard (WOCommon, af7ad15)
Many tweaks and fixes related to Garbage Collection under Leopard, necessary to get the test suite building and running again.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 1:13 PM
Import WOPreferencePane class (WOCommon, b5411f2)
This was originally developed for Synergy 3.5, but the code is very generic and belongs in WOCommon.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 1:12 PM
December 27, 2007
Fix another WOMakeCollectable/NSMakeCollectable issue (WOCommon, 42aa205)
Another CFTypeRef which should have been id type.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 9:30 PM
Throw away WOBundle and WOBaseCore (WOCommon, cbbe594)
Apple deprecated some crucial API in Leopard and my options were as follows: ignore the deprecation warnings (thus making it impossible to insist on warning-free builds, and only deferring the inevitable moment when support is dropped entirely); switch to the new API (unfortunately not equivalent to the old API, and would have required a kludgey hack); or rip out the old code and forget about the functionality.
Rather than chase a moving target or balance on shakey ground (pick your metaphor) I decided to rip the old code out and forget about it. This means ripping out WOBundle and the entire WOBaseCore bundle; some of the necessary functionality in WOBaseCore has been migrated into other classes in WOCommon. On the bright side, this is a simplification, even if it does mean sacrificing some very useful functionality that proved itself pre-Leopard.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 9:15 PM
Fix syntax error in NSFileManager category (WOCommon, bda13fc)
This category hasn't actually been used for some time and so a syntax error had crept in.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 7:17 PM
Swap in NSMakeCollectable for WOMakeCollectable (WOCommon, 55f3d33)
Thus fixing a compiler warning (need id return type, not CFTypeRef).
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 7:13 PM
Remove deprecated method call in NSScanner lexing utilities (WOCommon, 18702b0)
"copy" is now recommended in favor of the deprecated "string" method, but in this case we don't even need to worry about that: just pass back the temporary string, even though it's mutable.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 7:04 PM
Don't let FileUtils.cd swallow the return value (snippets, 5652285)
Explicitly return the value from the block (the block itself) will evaluate to nil.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 6:05 PM
Use abbreviated SHA-1 hashes in nightlies (snippets, 3d6f550)
There is no need to show the full SHA-1 hash in the nightlies feed, so show the abbreviated one instead.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 5:56 PM
Close the application when last window is closed (Synergy, c7eb0af)
This provides a nicer user experience. If there are unsaved changes the user will already have seen/dismissed the "Apply"/"Don't Apply" sheet, so don't resurrect the window and show the sheet again.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 5:21 PM
Provide menu item for bringing preferences window on screen (Synergy, c2adcef)
Useful for when user dismisses preferences window and later decides that he/she wants it back.
An interesting case is when there are unapplied changes; if the user tries to close the window, clicks "Don't Apply", and then tries to quit the application then the window will come back on screen again and the sheet will be shown.
In order to support this repeated showing of the preferences window had to use the setReleasedWhenClosed: method. Note that I may later decide to auto-quit the application when the last window is closed.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 5:14 PM
Fix window closing and termination behaviour (Synergy, 52c8406)
The sheet callback logic was slightly broken when it came to distinguishing between application termination and window closing.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 4:31 PM
Use full path to zip in nightlies script (snippets, e562da6)
Without this the scp operation fails.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 3:55 PM
Make test for non-shallow clone silent (Synergy, 5ff6834)
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 3:43 PM
Don't produce release notes for nightlies (Synergy, bb1efed)
The nightly builds are made using shallow clones and so can't produce release notes during the build.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 3:37 PM
WOCFRelease function (WOPublic, 965f0f8)
Simple, NULL-safe wrapper for CFRelease.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 3:26 PM
Produce longer release notes if --long switch passed (buildtools, 6d4875b)
Note also that we just use "git log --pretty=format" rather than piping through "git shortlog".
There is a strange behavioural discrepancy here with newlines depending on whether the script is run interactively or via Xcode; work around it by just echo a blank line rather than trying to pass "\n".
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 3:14 PM
Produce detailed release notes during the build (Synergy, 74f817b)
In addition to the brief release notes already generated.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 3:13 PM
Replace calls to malloc with wmalloc (WOCommon, 62630a6)
This saves us a few lines of code and makes behaviour in the face of failed memory allocation more consistent.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 2:58 PM
Fix WOLog redefinition warning (WOCommon, 1e78769)
Now that WOLog is a macro rather than a global external, one of the definitions is redundant, so remove it.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 2:52 PM
Rewrapping in NSMutableString editing utilities (WOCommon, 2ca60b4)
Rewrap for better readability.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 2:51 PM
Header clean-up (WOCommon, dd2c5ea)
Trim the fat off the headers in various classes and categories.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 2:51 PM
Document required classes for WOLoginItem (WOCommon, def7804)
Code-level documentation.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 2:50 PM
Silence warnings about property mismatches (WOCommon, 617a1e6)
In the final version of Objetive-C 2.0 the property declaration and re-declaration semantics changed slightly; explicitly mention the "copy" attribute in the original declaration to silence the build warning.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 2:49 PM
Document required classes for WOLogManager (WOCommon, f1e601a)
Code-level documentation.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 2:48 PM
Remove deprecated methods (WOCommon, c5028f5)
From NSDictionary creation category. This commit also includes some minor re-wrapping close to the removed method (no substantive changes).
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 2:48 PM
Avoid uninitialized use of variable (Synergy, 26d81a6)
GCC warns here because in the event of an error the variable might be used prior to initialization. Fix by moving the initialize to the very top of the method body.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 2:44 PM
Add back NSHumanReadableCopyright (Synergy, d1c8738)
I was a little too quick to remove this key from my InfoPlist.strings files; it is used in the default About box.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 2:43 PM
Xcode project buzz (Synergy, ba00d75)
Xcode insists on adding/removing comments in the project.pbxproj file (no substantive changes made). Commit it to keep "git status" quiet.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 1:10 PM
Xcode project buzz (Synergy, ba00d75)
Xcode insists on adding/removing comments in the project.pbxproj file (no substantive changes made). Commit it to keep "git status" quiet.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 1:10 PM
Don't pass SVNREV during Synergy nightly build (snippets, c5d7094)
SVNREV is no longer used, so passing it is redundant.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 1:09 PM
Temporarily override PBXBuildsContinueAfterErrors (snippets, 14ccc04)
I like to have PBXBuildsContinueAfterErrors set to YES in my user defaults so as to catch the maximum number of errors possible in each build cycle.
But having this set doesn't work too well when building nightlies, where we want the first error to derail the build process as soon as possible.
So set up a temporary override from within the nightlies script to allow us to have the best of both worlds.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 12:55 PM
Teach nightlies script to find out latest Synergy archive name (snippets, f0162d1)
Read in the info written out by the distro.sh script.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 1:15 AM
Echo zip name to target build directory (Synergy, 0f767e7)
So that the nightly script can find out the name of the distribution archive without having to duplicate the logic of the distro.sh script.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 1:12 AM
Echo zip name to target build directory (Synergy, 0f767e7)
So that the nightly script can find out the name of the distribution archive without having to duplicate the logic of the distro.sh script.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 1:12 AM
December 26, 2007
Use short relative paths in zip archive (Synergy, c9bbb45)
Don't use absolute paths when preparing the zip archive (all the levels wind up in the extracted contents as well); instead keep the relative paths as short as possible by changing into the target build dir before preparing the archive.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 11:56 PM
Use short relative paths in zip archive (Synergy, c9bbb45)
Don't use absolute paths when preparing the zip archive (all the levels wind up in the extracted contents as well); instead keep the relative paths as short as possible by changing into the target build dir before preparing the archive.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 11:56 PM
Move sample files into subdirectory (Synergy, 9d5cbbf)
Move sample track change items, button sets etc into an "Extras" subdirectory to make it clearer where users should start the first time they extract the distribution archive.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 11:55 PM
Move sample files into subdirectory (Synergy, 9d5cbbf)
Move sample track change items, button sets etc into an "Extras" subdirectory to make it clearer where users should start the first time they extract the distribution archive.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 11:55 PM
New distribution script (Synergy, 1064c19)
Replace old installation script with new target and distro.sh script. Seeing as this is a simple drag-and-drop install now, just use a zip archive and avoid the complication of a disk image.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 11:46 PM
New distribution script (Synergy, 1064c19)
Replace old installation script with new target and distro.sh script. Seeing as this is a simple drag-and-drop install now, just use a zip archive and avoid the complication of a disk image.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 11:46 PM
Use new login API from WOCommon (Synergy, 257953e)
The new wrapper application updates the login items (formerly the job of the installer). Update the preference pane code to make use of the same method and avoid duplication; this allows us to rip out a sizeable hunk of old code.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 8:58 PM
Use new login API from WOCommon (Synergy, 257953e)
The new wrapper application updates the login items (formerly the job of the installer). Update the preference pane code to make use of the same method and avoid duplication; this allows us to rip out a sizeable hunk of old code.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 8:58 PM
Dispose of old "install" subfolder (Synergy, 6b5a178)
Most of the files previously in the "install" subfolder are no longer needed and so can be removed. The remaining important files (those to be included with the Synergy distribution) are moved to a new top-level subfolder, "distribution".
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 5:01 PM
Dispose of old "install" subfolder (Synergy, 6b5a178)
Most of the files previously in the "install" subfolder are no longer needed and so can be removed. The remaining important files (those to be included with the Synergy distribution) are moved to a new top-level subfolder, "distribution".
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 5:01 PM
Update Launch Services and login items at launch (Synergy, a93bd55)
Teach the new wrapper application to take on these two responsibilities that were previously handled by the installer.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 4:32 PM
Update Launch Services and login items at launch (Synergy, a93bd55)
Teach the new wrapper application to take on these two responsibilities that were previously handled by the installer.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 4:32 PM
December 24, 2007
Modernize UpdateStringsFiles.sh (buildtools, 460689f)
Make some tweaks to UpdateStringsFiles.sh to make it more generally suitable. In particular, the ability to specify separate source and resources folders means that we can use this script in the Synergy build process now (because the Synergy code base dates back a very long way now and doesn't follow the standard locations which you get when you set up a new project).
These changes basically make the UpdateStringsFile.sh script redundant, so remove it.
I am still not entirely happy with this script -- it is now showing its age -- despite the fact that it works. In the future will probably do some more refactoring to clean this up and correctly distribute responsibilities among this, the UpdateXibs.sh script, and possibly others.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 7:10 PM
Modernize localizable string update process (Synergy, e5f48d3)
Ditch old shell script build phases for updating strings in favor of just calling UpdateStringsFiles.sh from buildtools.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 7:08 PM
Modernize localizable string update process (Synergy, e5f48d3)
Ditch old shell script build phases for updating strings in favor of just calling UpdateStringsFiles.sh from buildtools.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 7:08 PM
Remove installer README documents (Synergy, 0f1a108)
These are no longer relevant as we no longer even have an installer.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 7:07 PM
Remove installer README documents (Synergy, 0f1a108)
These are no longer relevant as we no longer even have an installer.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 7:07 PM
Tweak property list keys to match latest documented behaviour (Synergy, 2b03b13)
Keep in line with latest recommendations in the Apple "Property List Key Reference". At the same time I used wincent-strings-util to regenerate all of the localized variants, which means that the key order and comments are now consistent across al localizations. I also added in the InfoPlist.strings files for localizations which were lacking them (at this stage untranslated).
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 4:47 PM
Tweak property list keys to match latest documented behaviour (Synergy, 2b03b13)
Keep in line with latest recommendations in the Apple "Property List Key Reference". At the same time I used wincent-strings-util to regenerate all of the localized variants, which means that the key order and comments are now consistent across al localizations. I also added in the InfoPlist.strings files for localizations which were lacking them (at this stage untranslated).
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 4:47 PM
Bump version number post-release (Wincent Strings Utility, fdb4707)
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 4:21 PM
Bump version number for second release candidate release (Wincent Strings Utility, 31f3bb5)
Now at 1.2-rc2.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 4:21 PM
Tweak some spec descriptions (Wincent Strings Utility, d295418)
Reviewing the output of "spec -f html" I noticed that a couple of the example descriptions aren't as accurate as they could be, so fix that.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 4:17 PM
Avoid unnecessary object instantiation (Wincent Strings Utility, 7fcfe27)
There is no need to create a new string object here; we can just return the string object returned to us by the system.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 4:17 PM
Support recursive substitution (Wincent Strings Utility, 93b954c)
In updating my apps to match the latest documentation in Apple's "Property List Key Reference" I noticed that it would be useful to be able to do recursive substitution when using the --info and --strings switches; that is, have one key refer to the value of another key in an InfoPlist.strings file rather than one in the Info.plist.
This commit therefore gets rid of the simplistic find-and-replace substitution that was previously implemented and replaces it with a proper recursive substitution mechanism that allows keys in a strings file to refer to other keys in the same file, using multiple levels of recursion if need be, and finally falling back to look-up in the Info.plist file.
The algorithm is smart enough to detect direct and indirect infinite recursion (self-referential subsitutions), allow repeated substitutions, and bail in the event that no suitable substitution can be found.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 4:17 PM
Add specs for missing command line switches (Wincent Strings Utility, 247c21e)
Test case where --strings is supplied without --info and vice versa.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 4:17 PM
Warn about C99 comments (Wincent Strings Utility, fdafc9e)
Although the scanner knows how to recognize both C99 (single-line, Objective-C-style comments) and traditional C commnets (multi-line comments) it is almost certainly an error for the former to be present in a plist or strings file, so issue a warning if found.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 4:17 PM
December 23, 2007
Change button set handling for installerless distribution (Synergy, 801a8fd)
The buttons sets which were formerly installed by the installer are now bundled inside the application. Minor code changes to allow the preference pane to share the button sets with the application.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 11:40 PM
Change button set handling for installerless distribution (Synergy, 801a8fd)
The buttons sets which were formerly installed by the installer are now bundled inside the application. Minor code changes to allow the preference pane to share the button sets with the application.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 11:40 PM
Re-fix export paths (snippets, 9c3facc)
Commit 1823803 didn't go far enough in fixing the relative path problem in the Synergy nightlies script. Not only were we missing the trailing "src" directory; we were also operating at the wrong depth.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 11:02 PM
Fail verbosely in check-series script (snippets, 2140413)
If the commit is bad because of a failed "make test", state as such.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 11:00 PM
Fix export paths for Synergy nightly (snippets, 1823803)
Synergy expects to find the WOCommon source at ../../WOCommon/src, not at ../../WOCommon, so adjust export path to match, and likewise for WOPublic.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 10:57 PM
Call mainViewDidLoad when showing preference pane (Synergy, 4a9cbcf)
Add missing call in WOPreferencePane class to ensure the preference pane gets properly initialized at load time.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 10:25 PM
Call mainViewDidLoad when showing preference pane (Synergy, 4a9cbcf)
Add missing call in WOPreferencePane class to ensure the preference pane gets properly initialized at load time.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 10:25 PM
Update shell script for new development language path (Synergy, a0adca5)
One of the shell script phases had a hard-coded development language path (English.lproj). Change it to work with the new development language (en.lproj).
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 10:07 PM
Update shell script for new development language path (Synergy, a0adca5)
One of the shell script phases had a hard-coded development language path (English.lproj). Change it to work with the new development language (en.lproj).
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 10:07 PM
Correct spelling error in comment (buildtools, 97d9623)
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 10:01 PM
Add localized xib references back to Xcode project (Synergy, 1cce708)
Now that the localized xibs are back in action again, add them back to the Xcode project.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 9:44 PM
Add localized xib references back to Xcode project (Synergy, 1cce708)
Now that the localized xibs are back in action again, add them back to the Xcode project.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 9:44 PM
Run UpdateXibs.sh and integrate old localization info (Synergy, 350ab66)
Set up the initial strings and untranslated.strings files using UpdateXibs.sh. In so far as is possible, I have tried to use the old localization info extracted from a previous release. In many cases this applies cleanly to the new xibs, but there are many where it does not, and these will still need to be updated by hand; even in the cases where the old strings applied cleanly any custom geometry will have to be added back in by hand because this did not carry across.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 9:30 PM
Run UpdateXibs.sh and integrate old localization info (Synergy, 350ab66)
Set up the initial strings and untranslated.strings files using UpdateXibs.sh. In so far as is possible, I have tried to use the old localization info extracted from a previous release. In many cases this applies cleanly to the new xibs, but there are many where it does not, and these will still need to be updated by hand; even in the cases where the old strings applied cleanly any custom geometry will have to be added back in by hand because this did not carry across.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 9:30 PM
Be more verbose (buildtools, 49ec906)
While trying to debug a failure case I noticed that it was possible for the script to terminate early (due to the "set -e") but for no error message to be printed to the standard error.
So be more verbose about what's happening, and install an exit trap to draw attention to an unexpected early exit.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 9:00 PM
Avoid stat calls (buildtools, c639a41)
Shave off some lines and clean up the code a little by avoiding the stat invocations and using the -nt and -ot test primaries instead.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 8:09 PM
Use $() rather than backticks (buildtools, 6c7aa3e)
$() is superior because it can be nested if need be.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 8:00 PM
Shell-script clean-up (buildtools, a1267f6)
Remove hard-coded paths in /usr/bin (trust PATH to lead to the selection of the right tool), use /bin/sh instead of /bin/bash in the shebang line, and quote some arguments which contain variables (paths are unlikely to contain spaces, but err on the safe side).
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 7:55 PM
Use close() function from Common.sh (buildtools, 85d1bcb)
The close_document_if_open() function here is redundant; use the equivalent close() function defined in Common.sh instead.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 7:42 PM
Update wincent-strings-util calls to use double-hyphen switches (buildtools, 7acf42a)
Keep in synch with wincent-strings-util 1.2-rc1+.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 7:39 PM
Use double-hyphens for all switches (Wincent Strings Utility, dea11de)
The NSUserDefaults standard for command-line switches uses only a single hyphen, which is a little unorthodox. Use more conventional double hyphens instead by inserting an additional hyphen in the default names.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 7:35 PM
Bump version number post-release (Wincent Strings Utility, 0bea285)
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 7:35 PM
Enhancements to UpdateXibs script (buildtools, 30cf542)
The script now performs multiple functions: creates/updates strings files in the base language if required; creates xibs in the target languages if required; creates/updates strings files in the target languages if required; merges new strings from the base language strings files into the target language strings files; extracts incremental strings files (containing new and untranslated strings in the target language); and combines incremental strings files with existing translations.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 7:19 PM
Color support (buildtools, 65e6ba8)
Use tput to test whether the current terminal supports basic color capabilities (bold, foreground color, reset). In itself these tests are not enough to determine whether it is appropriate to use color; for example, when run from inside Xcode or when output is redirected or piped elsewhere the tests will still pass but color may not be appropriate. So an additional test (test -t 1) for an open file descriptor is used to avoid emitting color output in these circumstances.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 6:47 PM
December 22, 2007
Bump version number for 1.2 release candidate 1 (Wincent Strings Utility, a2e8ae4)
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 10:00 PM
Add specs for -combine functionality (Wincent Strings Utility, e7ece84)
And based on usability assessment running the specs tweak the warning issued for duplicate keys to be a little more helpful (ie. explicitly mention that the same key was found in both files and that the value from the second file will take precedence).
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 10:00 PM
Add checks for duplicate keys within the same file (Wincent Strings Utility, c4a5cc7)
Emit error messages during parsing if duplicate keys found. This is a serious-enough problem to warrant issuing an error rather than a mere warning, but we continue processing anyway.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 10:00 PM
Favor member: over containsObject: (Wincent Strings Utility, 40c92d7)
The looser check done by member: (using isEqual:) is more appropriate here than the one done by containsObject: (an identity comparison done using pointer equality, I believe).
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 10:00 PM
Fix file mode on encode_spec.rb (Wincent Strings Utility, b3e8416)
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 10:00 PM
Add extract() specs and fix a bug (Wincent Strings Utility, 4e7b88d)
Add specs for the -extract switch and fix a bug discovered as a result.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 10:00 PM
Minor comment cleanup (Wincent Strings Utility, 5dd6388)
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 10:00 PM
Try multiple encodings in -info/-strings code path (Wincent Strings Utility, fb6f577)
Although we don't strictly need to parse the input file passed in using the -strings switch (as we're just doing a simple find and replace) parse it anyway because in this way we can hopefully get the encoding right on files which don't have BOMs.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 10:00 PM
Fix pending tests by using fallback encodings (Wincent Strings Utility, 3f897ce)
Instead of using the deprecated NSString stringWithContentsOfFile: method (not sure why no deprecation warnings were being issued) instead use stringWithContentsOfFile:encoding:error:. The problem with the former is that any strings file without a BOM was being interpreted using the normal C string encoding, which was incorrect and would in turn cause parsing to fail.
In this way we can explicitly try NSUTF16StringEncoding (should work for any file that has a BOM) and then fall back to NSUTF16LittleEndianStringEncoding and NSUTF16BigEndianStringEncoding if parsing fails.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 10:00 PM
Add specs for automatic addition of BOMs to output (Wincent Strings Utility, 36576bc)
Make sure that when the input file has no BOM, we automatically add one to the output stream.
At the moment these specs are marked as pending because the parse() function is choking on input files that don't have BOMs.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 10:00 PM
Add test case for CFStringCreateExternalRepresentation() bug (Wincent Strings Utility, f9236a6)
I've now created a basic test case demonstrating the CFStringCreateExternalRepresentation() bug; the Radar for the issue is 5661397.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 10:00 PM
Work around CFStringCreateExternalRepresentation() bug (Wincent Strings Utility, b02b784)
This commit adds some specs to test the operation of the -encode switch and in so doing has uncovered what looks to be a bug in the CFStringCreateExternalRepresentation() function.
The docs suggest that a BOM should be added to the beginning of the string, but in my testing this is not the case.
The workaround is to manually add the BOM, while double-checking to make sure that the system doesn't add one (just in case the behaviour of the system changes in the future).
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 10:00 PM
Allow explicit override of output encoding (Wincent Strings Utility, 6afbc3c)
This allows wincent-strings-util to be used as a general "clean up" tool for localizations. For example, a localization might be completed but have excess whitespace and be encoded with a different endianness (ie. the original version is sent to the localizer as little-endian but the localizer uses an editor which saves it in big-endian encoding).
To make performing diffs easier we can use wincent-strings-util to normalize these non-significant differences, hopefully making the task of integrating changes much easier.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 10:00 PM
Split specs into separate files (Wincent Strings Utility, d789a0b)
Break the specs up into multiple files to make them easier to maintain.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 10:00 PM
Run just-built copy by default (Wincent Strings Utility, 6646efa)
When run from inside an Xcode shell script phase the TARGET_BUILD_DIR environment variable enables us to find the just-built copy for testing purposes. The same effect can be achieved by manually exporting the environment variable and running the specs by hand from the command line.
When the environment variable is not set, fall back to just running whatever copy of wincent-strings-util happens to be found first in the PATH.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 10:00 PM
Move input files into subdirectory (Wincent Strings Utility, a9130ab)
Keep the spec directory cleaner by moving the input files into their own subdirectory.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 10:00 PM
December 21, 2007
Add specs for basic -merge use (Wincent Strings Utility, c09ab36)
Test some simple cases: merging using an untranslated, partially translated, and fully translated target localization.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 8:32 PM
Initial specs (Wincent Strings Utility, 46693cf)
This is an initial batch of specs written using RSpec. Seeing as this is such a simple tool there doesn't seem to be much sense in doing internal testing at the Objective-C level; instead just run the tool itself and make sure it does what it's supposed to do. RSpec is used despite the fact that wincent-strings-util has absolutely no Ruby in it, simply because it's a nice framework for doing this kind of thing.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 7:41 PM
Handle case where -base is supplied with no other options (Wincent Strings Utility, 06911e1)
Supplying -base without any options is legal; it just means that no transformation is applied to the input before outputting.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 7:41 PM
Remove unused variable (Wincent Strings Utility, f4c12e1)
Clean up unused variable lying around from previous version (when duplicate keys were considered an error during combining).
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 7:41 PM
Update man page for new features (Wincent Strings Utility, cf83d69)
Revise man page to document the new -extract and -combine switches.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 7:40 PM
Make duplicate keys a warning rather than an error (Wincent Strings Utility, 434fa5c)
Instead of disallowing duplicate keys during a combine operation, issue a warning and allow the "target" version to take precedence.
This facilitates a common workflow wherein a localization is incomplete and its strings file contains a number of key/value pairs that are unlocalized. In this case those pairs will be extracted with extract() and the partial strings file that results can be localized. When it comes time to integrate the partial file, it is necessary to allow those new strings to override the existing, unlocalized ones in the previous version of the localizations' string file.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 7:40 PM
Hook up new combine() and extract() functions (Wincent Strings Utility, 97d6426)
These two functions can be used to help with incremental localization.
The extract() function looks at a base strings file (in the development language) and compares it with a target strings file (in the target langauge). All strings which are new (not present in the target) or untranslated (present in the target but with the same value as in the base) are extracted. The output can then be sent to translators for translation.
The combine() function takes a partial strings file (of the kind produced by the extract() function) and integrates it with an existing file using a simple additive algorithm (not a merge). It is considered an error if there is any overlap in the keys in the two files.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 7:40 PM
Refactoring and new functions (Wincent Strings Utility, 127e31d)
This is part of a major clean-up to make way for some new functionality. The NSScanner category has been split off into a separate file, and a simple wrapper class has been added so as to eliminate the error-prone and tedious use of an NSDictionary to model an "entry".
In many places the code has been touched up for better readability.
The functions for handling the new options are in place but not hooked up yet.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 7:40 PM
Whitespace fixes (Wincent Strings Utility, e9cff5a)
Remove trailing whitespace.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 7:40 PM
Bump internal version number to 1.2 (Wincent Strings Utility, eb0a895)
This is not yet an official release, but when it becomes one it will be 1.2.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 7:40 PM
Add x86_64 info for what(1) (Wincent Strings Utility, fb6556c)
Although we don't produce an x86_64 build yet, make sure the what(1) output is ready for it if and when we do.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 7:40 PM
Move macro definitions to top of file (Wincent Strings Utility, 377a3e7)
These seem to confuse Xcode's function pop-up menu if they appear in the middle of a function body, so move them up out of the way.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 7:40 PM
Use note() when cloning xibs (buildtools, ca566a2)
When a new xib is created from scratch, notify with note() rather than with echo so that if the script is being run from within Xcode the notification will appear as a note in the build results window (so as to remind the user to add the new file to the project).
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 8:43 AM
December 20, 2007
First version of UpdateXibs.sh script (buildtools, 2e42c48)
At this stage it doesn't do much -- just check for the existence of target xib and strings files and creates them if they are missing -- but subsequently I will add incremental localization abilities.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 9:21 PM
Add die() function (buildtools, 670aded)
This just calls err() and exits immediately. Useful in situations should be fatal (aborting processing).
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 9:20 PM
Fix permissions (Synergy, 6a36f05)
Fix braindead permissions that somehow creeped into the old Subversion repository (executable bits set on non-executable files), and which therefore were migrated over to the new Git repository as well.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 9:08 PM
Fix permissions (Synergy, 6a36f05)
Fix braindead permissions that somehow creeped into the old Subversion repository (executable bits set on non-executable files), and which therefore were migrated over to the new Git repository as well.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 9:08 PM
Add some TODO comments in the Synergy Preferences controller (Synergy, 8e17063)
These are things that will need to be done prior to release: automatic updating of login items (if user preferences request it), and clean up of the now-redundant installation files in whole or in part (yet to be decided).
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 9:07 PM
Add some TODO comments in the Synergy Preferences controller (Synergy, 8e17063)
These are things that will need to be done prior to release: automatic updating of login items (if user preferences request it), and clean up of the now-redundant installation files in whole or in part (yet to be decided).
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 9:07 PM
Remove old pbproj bundle from SynergyReg subdirectory (Synergy, 2e2938d)
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 9:06 PM
Remove old pbproj bundle from SynergyReg subdirectory (Synergy, 2e2938d)
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 9:06 PM
Rename English.lproj to en.lproj (Synergy, 636b746)
For consistency with other projects and with Apple's recommendations. This renaming includes updating all Xcode project references, so the build should continue to work with no other modifications.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 8:53 PM
Rename English.lproj to en.lproj (Synergy, 636b746)
For consistency with other projects and with Apple's recommendations. This renaming includes updating all Xcode project references, so the build should continue to work with no other modifications.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 8:53 PM
Reference top-level nib objects for GC and clean localizations (Synergy, 28983e7)
Add top-level strong references to a couple more nibs to ensure that objects don't get inopportunely garbage-collected.
I would have liked to propagate this same change to the other nibs using ibtool but unfortunately there are quite a few errors (class mismatches) reported that prevent this from proceeding; so somewhere in the long history of these nibs they have gotten far enough out of sync with the authoritative English versions to make them unusable with ibtool.
So, for now I am temporarily removing the unsynchronizable nibs entirely; I will have to create new nibs (copies of the English nibs) and copy the strings across by hand from the older localizations that I have on file. This will be a lengthy and painful job, so it might be sometime before it gets completed.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 8:20 PM
Reference top-level nib objects for GC and clean localizations (Synergy, 28983e7)
Add top-level strong references to a couple more nibs to ensure that objects don't get inopportunely garbage-collected.
I would have liked to propagate this same change to the other nibs using ibtool but unfortunately there are quite a few errors (class mismatches) reported that prevent this from proceeding; so somewhere in the long history of these nibs they have gotten far enough out of sync with the authoritative English versions to make them unusable with ibtool.
So, for now I am temporarily removing the unsynchronizable nibs entirely; I will have to create new nibs (copies of the English nibs) and copy the strings across by hand from the older localizations that I have on file. This will be a lengthy and painful job, so it might be sometime before it gets completed.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 8:20 PM
Upgrade xibs to latest format (Synergy, b1b2b98)
Using "ibtool --upgrade".
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 7:42 PM
Upgrade xibs to latest format (Synergy, b1b2b98)
Using "ibtool --upgrade".
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 7:42 PM
Convert all nibs to xibs (Synergy, c797be5)
Use the nicer, SCM-friendly nib format that's new with Leopard and Xcode 3.0.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 7:29 PM
Convert all nibs to xibs (Synergy, c797be5)
Use the nicer, SCM-friendly nib format that's new with Leopard and Xcode 3.0.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 7:29 PM
Remove NSMenuExtra header (Synergy, d6cee75)
It's unused, so get rid of the clutter.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 6:46 PM
Remove NSMenuExtra header (Synergy, d6cee75)
It's unused, so get rid of the clutter.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 6:46 PM
Update release procedure and development notes (Synergy, 10bd7f6)
Lots has changed since these notes were originally written; there are still references to CVS in there, for example, and that was phased out a long time ago in favor of Subversion, then SVK and finally Git.
So prune the irrelevant bits.
This commit also includes a simple shell script for tagging releases in Git; seeing as each release should really be tagged in at least three repositories (Synergy itself, WOCommon and WOPublic), it's easier to do this with a single script.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 6:43 PM
Update release procedure and development notes (Synergy, 10bd7f6)
Lots has changed since these notes were originally written; there are still references to CVS in there, for example, and that was phased out a long time ago in favor of Subversion, then SVK and finally Git.
So prune the irrelevant bits.
This commit also includes a simple shell script for tagging releases in Git; seeing as each release should really be tagged in at least three repositories (Synergy itself, WOCommon and WOPublic), it's easier to do this with a single script.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 6:43 PM
Include build date in revision file (buildtools, c26297e)
But only update it when the Git HEAD commit changes, to avoid spurious recompiles in Xcode.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 6:06 PM
Update versioning and targets (Synergy, 38001f5)
Switch to a modern versioning technique in the build, like the one used in Synergy Advance. Basically, when building a package for release we update the build number based on the current Git commit; the version number and copyright years are automatically propagated through to the localized InfoPlist.strings files.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 6:03 PM
Update versioning and targets (Synergy, 38001f5)
Switch to a modern versioning technique in the build, like the one used in Synergy Advance. Basically, when building a package for release we update the build number based on the current Git commit; the version number and copyright years are automatically propagated through to the localized InfoPlist.strings files.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 6:03 PM
Use more appropriate Git commands (buildtools, abd6284)
Update git.rb to use commands which are a better match for the goals that git.rb is trying to achieve (ie. "git rev-parse --short" swapped in for "git show --pretty=format", "git diff --quiet" swapped in for "git status").
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 5:29 PM
Add custom icon for standalone preferences application (Synergy, 0bd5383)
This is the same as the standard Synergy icon.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 2:52 PM
Add custom icon for standalone preferences application (Synergy, 0bd5383)
This is the same as the standard Synergy icon.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 2:52 PM
Formatting fixes for main controller (Synergy, a77d906)
Minor rewrapping for readability, and remove some unnecessary braces.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 1:44 PM
Formatting fixes for main controller (Synergy, a77d906)
Minor rewrapping for readability, and remove some unnecessary braces.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 1:44 PM
Add built-in uninstaller for global installs (Synergy, 9d4a934)
In 0b7051e I added an uninstaller for local installs. This commit does the same for global installs (which require root privileges to uninstall).
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 1:42 PM
Add built-in uninstaller for global installs (Synergy, 9d4a934)
In 0b7051e I added an uninstaller for local installs. This commit does the same for global installs (which require root privileges to uninstall).
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 1:42 PM
Force strong references to top-level nib objects (Synergy, b2cc476)
Set up some phoney outlets to the top-level objects in the nib so as to create strong references to them and thus avoid having them garbage collected.
I am not entirely sure of all the cases in which this is required (I know that it is required for standalone controllers) so I have created outlets for all "real" (instantiated) top-level objects (at this stage that only means the controller and the MainMenu).
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 3:02 AM
Force strong references to top-level nib objects (Synergy, b2cc476)
Set up some phoney outlets to the top-level objects in the nib so as to create strong references to them and thus avoid having them garbage collected.
I am not entirely sure of all the cases in which this is required (I know that it is required for standalone controllers) so I have created outlets for all "real" (instantiated) top-level objects (at this stage that only means the controller and the MainMenu).
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 3:02 AM
Build-in uninstaller for old versions (Synergy, 0b7051e)
Now that we don't have an installer we still need a way to clean up old versions of the software, so build-in an uninstallation facility. This first implementation is for local (non-root) installs only. A subsequent commit will add global uninstall capability.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 1:41 AM
Build-in uninstaller for old versions (Synergy, 0b7051e)
Now that we don't have an installer we still need a way to clean up old versions of the software, so build-in an uninstallation facility. This first implementation is for local (non-root) installs only. A subsequent commit will add global uninstall capability.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 1:41 AM
December 19, 2007
Adjust "preferences" menu item (Synergy, 81aea3b)
Teach the app to look for the new standalone preferences app rather than the one installed in {~/,/}Library/PreferencePanes/.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 1:40 PM
Adjust "preferences" menu item (Synergy, 81aea3b)
Teach the app to look for the new standalone preferences app rather than the one installed in {~/,/}Library/PreferencePanes/.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 1:40 PM
More Objective-C 2.0 properties (Synergy, 3cc0406)
Convert more old accesors to use the new Objective-C 2.0 properties (WOSynergyFloaterController, WOSynergyFloaterView and SynergyController).
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 1:01 PM
Handle application and window closing (Synergy, cb9a22c)
Special handling for application and window closing if there are unsaved changes. To get this to actually work I also had to fix a bug in the loading code: we were instantiating an instance of WOPreferencePane rather than the subclass as specified by the NSPrincipalClass key in the bundle info property list.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 12:59 PM
Set-up top-level git ignore file (Wincent Strings Utility, 565e654)
Ignore the "index" directory created in the SRCROOT by Xcode 3.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 12:49 PM
Add installer package target (Wincent Strings Utility, b1c9b17)
At the same time the project bundle format was upgraded to the latest version of Xcode.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 12:48 PM
Initial version of standalone preferences application (Synergy, b499a72)
Now the Synergy prefPane is no longer loaded by the System Preferences and is instead hosted by a standalone application. This commit is an initial version of the application which loads the prefPane bundle and displays the window in the center of the screen on launch.
This change was made after a review of the Garbage Collection migration. Synergy's code is found in two places: inside the application itself and inside the preference pane (and the application is bundled inside the preference pane bundle). The application code has been converted to use Garbage Collection but the preference pane code could not be converted because the System Preferences application is compiled without GC support and the PreferencePanes framework against which the preference pane must link does not come in a GC-enabled version, at least as of Leopard.
This is problematic because some of the Synergy code is shared between the app and the preference pane; it is therefore necessary for the common code to be written using a reference-counting style (which largely negates the benefit of moving to GC) or using conditional compilation to produce two variants of the same code (which is an error-prone process).
So evaluating all this, it seems the best course of action is to host the preference pane in a standalone application. In order to do so I can no longer link against the PreferencePanes framework, so I've made a new class, WOPreferencePane, to stand in for NSPreferencePane, and a simple NSWindow subclass, WOPreferenceWindow, to load and display a single pane.
An additional benefit of this move is that from now on Synergy will not require an installer because as a standalone application it can be installed anywhere.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 11:38 AM
December 18, 2007
Bring up-to-date for new workflow (snippets, 69b16dc)
Rip out SVK/SVN conversion methods; replace "svn info" revision check with "git ls-remote" equivalent; update configuration to point at Git repositories; add WOPublic to all projects; add buildtools, WOCommon and WOPublic to the Synergy dependencies list; remove installer section from Synergy build procedure; update target names ("Release" instead of "Development"); add Growl repository to config list for Synergy Advance.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 1:19 PM
Update Exporter class for Git (snippets, 5bbd3c0)
Dispose of SVN and SVK subclasses seeing as they'll never be used again and place the Git-specific code directly in the Exporter class itself.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 12:33 PM
Remove sync options from nightlies script (snippets, fd897e6)
These were only really applicable under Subversion and SVK; now that everything is hosted in Git they're not really needed.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 12:28 PM
Add Leopard notes to nightlies script (snippets, 91dbeaa)
Add download links for Tiger versions of the software (the nightlies themselves are targetted for Leopard).
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 12:25 PM
Remove Synergy Jaguar target from nightlies script (snippets, 12afe37)
And rename the remaining Leopard target to "Synergy".
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 12:23 PM
Remove Subversion buzz (snippets, 2a44f5a)
Remove the Id keyword.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 12:15 PM
Export CLICOLOR (snippets, 6669a25)
Necessary for color ls listings.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 12:14 PM
Import nightlies script from Subversion repository (snippets, 1eda727)
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 11:58 AM
Modernize re-wrapping script (snippets, 5c90dea)
Although the original version of the script worked it was probably one of the first Ruby scripts I'd ever written, if not the first one. This is a re-write with a little more experience and (more standard Ruby idioms and some refactoring for ease of comprehension).
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 11:56 AM
Import unwrapping script from Subversion repo (snippets, 4a74ad8)
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 10:33 AM
December 16, 2007
Remove unused help classes (Synergy, c27254f)
WOHelp and WOSynergyHelp are no longer used.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 12:37 AM
December 15, 2007
Remove WOSingleton class and other cruft (Synergy, d48f69d)
Much the same as I did in WOCommon, remove the WOSingleton abstract class in favor of concrete per-class implementations. This is especially overdue in the case of Synergy as its WOSingleton was considerably less sophisticated than the version in WOCommon.
There is now only one class which requires singleton functionality and it now has it thanks to fast double-checked locks with memory barriers.
At the same time as removing WOSingleton, also removed some other cruft classes that had been lying arond for ages as part of an experimental refactoring which was abandoned.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 11:58 PM
Update embedded Growl framework to 1.1.2 (Synergy, bde3657)
This is based on a clean checkout of the 1.1.2 tag in the Growl repository. The only modification is that Garbage Collection has been enabled in the build settings.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 11:55 PM
Update usage notes (WOCommon, 0a1a3c0)
Remove information on Subversion externals and replace it with info on relative project locations.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 11:53 PM
Remove unused variable (Synergy, 3dc2d5c)
Recent refactoring makes this variable unused, so dump it.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 10:55 PM
Remove useless retain messages (WOCommon, 4a3f85d)
Remove a number of legacy retain calls which are now no-ops.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 10:53 PM
Remove no-op retains (Synergy, ae22fe7)
These don't belong in here under GC.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 10:47 PM
Fix new compile-time warnings with new GCC (Synergy, cbfc2de)
The new version of GCC issues some warnings where the old one didn't, so make some tweaks to ensure warning-free builds.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 8:20 PM
Set up top-level ignores for Xcode 3 (Synergy Advance, 30dbe51)
Ignore the "index" folder created in the SRCROOT by Xcode 3.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 6:02 PM
Code audit and cleanup for GC (WOCommon, c176086)
This is the other part of the GC audit. The number of lines changes here (nearly 400 insertions, 1000 deletions) is not as much as was the case in the Synergy codebase as the WOCommon code is more "modern" and there was less to do, but it's still a significant change.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 5:59 PM
Major code audit and clean-up for GC (Synergy, 584f867)
Have audited the entire codebase for GC problems and in the process have cleaned up a lot of the code (Objective-C 2.0 properties, shorter allocation patterns, fast enumeration and so forth). In all inserted just over 1200 lines and deleted over 2000.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 5:54 PM
Simplify WONotificationCenter class (WOCommon, a0dd82c)
Thanks to new API in Leopard we can replace about 150 lines of very complex code (that plays with threads, run loops, mach ports etc) with only 25 lines of very simple code. This should be a much more robust implementation with far fewer limitations.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 4:34 PM
Remove eager loading of shared WOLogManager instance (WOCommon, 611433c)
For faster startup times and greater simplicity, remove the eager loading of the shared WOLogManager instance.
I did consider instead eagerly loading a lightweight proxy which would allow the deferral of loading the real log manager until first use, but in the end this wasn't the simplest thing which would work (a macro).
The shared manager access already occurs via a thread-safe double-checked locking method with memory barriers, so it should be both fast and safe. In this light the macro is the sanest solution.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 3:20 PM
Use wmalloc in WOLoginItem class (WOCommon, 1d38ca6)
Saves a few lines of code; will later switch to wmalloc elsewhere in the codebase as well.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 12:58 PM
Explicitly check for ENOMEM (WOPublic, ab2ed1a)
POSIX allows the size argument to malloc to be 0 (in which case either a NULL pointer or a pointer to something that can safely be passed to free is returned). So in order to test for a failed allocation must explicitly check for ENOMEM.
Of course, I personally think that it would almost always be an error to ask malloc for zero bytes, but in that case the mistake will eventually be caught anyway, when the caller tries to write to the returned pointer.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 12:53 PM
Modernize NSTimer pausing category (Synergy, cd5a4ed)
Now that this code no longer needs to run on Jaguar we can replace the old-fashioned mutexes with @sychronized blocks.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 12:20 PM
December 13, 2007
Safety fixes for check-series script (snippets, 44b1750)
Now refuses to run if there are any staged or unstaged changes, and actually updates both index and working tree back to old HEAD upon finishing (previously we just manipulated the HEAD directly; this was a kludge and incorrect anyway because it didn't touch the index or working tree).
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 7:20 PM
check-series fix (snippets, 5c29711)
Although the script worked a warning was issued at runtime because an integer comparison (-ne) was used rather than a string comparison (!=).
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 10:44 AM
December 10, 2007
Update internal list when login items are added or removed (WOCommon, ff094c5)
Add a refreshList method (internal use only) which is called whenever we add or remove a login item.
This also moves some of the addition logic from WOLoginItemList into a new addToList: method in WOLoginItem; in this way each login item can keep track of its corresponding LS ref without breaking encapsulation.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 1:15 PM
Use WOMakeCollectable function where appropriate (WOCommon, 6eb9559)
There are a couple of places where the Apple docs don't mention the possibility of returning a NULL ref and where the code doesn't bother to check for such a ref. To be on the safe side, use WOMakeCollectable here rather than CFMakeCollectable.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 12:53 PM
Add WOMakeCollectable function (WOPublic, 1035d53)
It's not safe to pass NULL values to CFMakeCollectable, so this wrapper function performs a check before doing so. It can be used in places where an explicit check would only add clutter.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 12:48 PM
New version of login-tool (Synergy, a73dbe7)
Bundle the new version of login-tool (based on 10.5 Launch Services API) in the installer.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 12:09 PM
Add WOMemory.h (WOPublic, a1ddd30)
Start with a simple inline function, wmalloc, which encapsulates the "try to malloc memory and throw an exception on failure" pattern.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 12:06 PM
Replace WOLoginManager with WOLoginItemList (WOCommon, a89c217)
The new Launch Services API for managing login items is well suited to encapsulation in two classes: WOLoginItem (previously added) and WOLoginItemList (added in this commit). This makes all of the API previously implemented in the WOLoginManager class redundant, so remove the class.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 12:01 PM
Accept multiple add and remove arguments (login-tool, 0931d52)
Remove the limitation on the number of add and remove arguments that are accepted by the tool (previously only the last argument was used and previous arguments were silently discarded).
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 11:55 AM
Switch to new Launch Services code in WOCommon (login-tool, f0a9c33)
This is basically a total rewrite of the tool, throwing out all the old code and instead relying on the new code in WOCommon.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 11:42 AM
December 9, 2007
Myriad changes for GC (WOCommon, 38e4bea)
Although this is by no means complete, this commit makes myriad changes to many classes and categories for Garbage Collection. Autorelease pool release calls have been replaced with drain calls, no-op retains, releases and autoreleases have been removed, simpler initialization idioms have been used in many places, some variables have been renamed for clarity (where previously a temporary mutable object was created and then an immutable copy returned we now just return the mutable one), and convenience creation methods have been deprecated in favor of a simpler copy idiom.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 7:10 PM
Add new login API files to project (WOCommon, 9e5d357)
Adds references to the WOLoginItem class to the Xcode project.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 7:09 PM
Add WO_CF_RELEASE macro (WOCommon, d7abcf5)
Simple wrapper for CFRelease. Mostly useful in error-recovery situations where it may not be appropriate to use CFMakeCollectable (for example, where you may have a NULL reference and don't want the clutter of an explicit check).
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 7:07 PM
Update symbol macros for WOLoginItem (WOCommon, bd7521a)
Currently has no effect, but in place for the next time the symbols are updated.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 7:05 PM
Replace calls to WOParameterAssert (WOCommon, 6c0d040)
Replace a bunch of calls to WOParameterAssert with NSParameterAssert (follow-up on recent assertion/check enhancements).
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 6:59 PM
Add WOLoginItem class (WOCommon, 2d5855f)
As part of an OO wrapper for the new API added to Launch Services for accessing login items add a WOLoginItem class and methods to WOLoginManager for retrieving arrays of login items.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 6:43 PM
Use WOLoginManager API from WOCommon (login-tool, f7b4756)
Apple has a new API for managing login items in Leopard, so I'm writing an Object-Oriented wrapper for it and sticking it inside WOCommon. This commit is the first of an incremental transition to the WOCommon API; the first function to be converted is for the "list" command.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 6:39 PM
Objective-C 2.0 changes for WOAudioscrobbler class (Synergy, 4cff245)
- properties - remove retain/release/autorelease calls - use class extension (anonymous category) for private methods - C99 for loop syntax
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 3:01 PM
December 8, 2007
Clean up code comments in WOSysctl.c (Synergy, dc7cec2)
During a GC audit was scanning for the word "release" and a couple of false positives in code comments came up; remove them seeing as they are chatty and superfluous anyway.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 7:16 PM
GC changes for WODistributedNotification class (Synergy, e7e2333)
The autorelease calls are no longer needed, doubly so because this is a singleton class and was never released prior to GC anyway.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 6:38 PM
Readability improvements for WOHost class (WOCommon, 276897e)
These enabled by the move to GC; we can use the shorter, more readable "dictionary" method rather than "alloc/init".
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 6:31 PM
Add commit-msg hook (snippets, ad67256)
Very simple hook that does three things:
- warns if any line in the commit message exceeds a predefined width - warns if the commit hasn't been signed off - in the event of a warning advises the user that the hook can be bypassed with the --no-verify switch
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 6:26 PM
Add reminder to use WOAssert in NSTimer category (Synergy, d1202ae)
For now we explicitly check and throw an exception, but as this is intended to check programmer errors should really use an assert macro (which will only be active in debug builds).
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 5:18 PM
Remove irrelevant comment from WOKeyCaptureView (Synergy, 35ae835)
Remove comment that's no longer relevant under GC.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 3:50 PM
Remove NSLock from NSTimer category (Synergy, 492a094)
NSLock was required when the code had to run on Jaguar (because the @synchronized directive was not available); now this limitation is no longer applicable so replace the NSLock idiom with @synchronized.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 3:48 PM
NSTimer category updates for GC (Synergy, 137534a)
Remove comment about "leaking" singleton which no longer make any sense under Garbage Collection.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 3:44 PM
December 7, 2007
Use Doxygen deprecated directive in NSArray creation category (WOCommon, 1cde1da)
Rather than just including the deprecation notice in the body of the method documentation, use the specific Doxygen directive for that purpose.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 11:06 PM
GC changes to NSAttributedString creation category (WOCommon, 84bcfe4)
Under GC the attributedString method is effectively equivalent to sending a copy message, so mark the method as deprecated and advise callers to use copy instead.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 11:05 PM
Complete GC conversion of NSArrayController drag category (WOCommon, cc93f2a)
Commit 235882a was only an incomplete conversion of the NSArrayController drag category to GC; this commit removes the remaining release message which should have been taken out the first time.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 11:00 PM
GC conversion for NSArray creation category (WOCommon, 9f2709e)
Under GC the "array" method is effecively the same as the "copy" method, so mark it as deprecated and add code documentation advising callers to just do a copy instead.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 10:56 PM
GC conversion for NSAppleEventDescriptor creation category (WOCommon, d980fd5)
Remove autorelease calls.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 10:52 PM
Remove references to autorelease in code documentation (WOCommon, 1f3635b)
The code documentation for the CIImage tinting category makes reference to "autoreleased" objects which no longer makes sense under GC.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 10:50 PM
Prune development notes (Synergy, dc7ef44)
Remove section on login items (no longer relevant).
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 10:48 PM
More build setting cleanup (Synergy, 046d739)
Remove old version number settings and the disk image script that made use of them.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 10:46 PM
Switch to buildtools-based configuration (Synergy, 3d41f2f)
To make sure the Garbage Collection conversion is as consistent as possible, switch to a buildtools-based configuration, cleaning out as many custom build settings as possible at the same time (one of these is BASE_DIR, which has been replaced with SRCROOT).
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 10:41 PM
Add new build of login-tool (Synergy, a2cc769)
This is a Universal Binary and rewrite in Objective-C 2.0 (using GC) and the scripting bridge. This should hopefully fix the "not starting at login" issues, although there are known problems with Apple's implementation of login items under Leopard.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 10:10 PM
Add alternate methods for adding login items (login-tool, 62e266f)
It appears that System Events is broken on Leopard: telling it to add a new login item fails in all three ways that I tried to do so (using the scripting bridge, using raw Apple Events, and even trying from the Script Editor using the script that Apple itself documents as being the way to do it).
So this commit preprocesses the non-working solutions away and falls back to old-fashioned direct manipulation of the loginwindow.plist. This actually is supported by Apple and is listed in their docs as one of the ways of adding login items.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 4:52 PM
December 5, 2007
Whitespace fixes (login-tool, 740316b)
Blow away trailing whitespace and some bad indentation.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 2:23 PM
Lose unnecessary curly braces (login-tool, 7ec3aea)
For a readability improvement (less vertical real estate needed for function).
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 2:20 PM
Use scripting bridge for adding login items (login-tool, 6570a5a)
This appears to be a correct translation of the old code, and saves many lines. It doesn't work, however, so further troubleshooting will be required.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 2:15 PM
Use delete method provided by scripting bridge (login-tool, 02c231f)
This is slightly nicer and more concise than calling "removeObject:".
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 1:23 PM
Teach removal function to use Scripting Bridge (login-tool, 40fe8e7)
This cleans up the old code considerably.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 1:00 PM
Refactoring for further Scripting Bridge use (login-tool, 95ff01d)
Extract the initial set up of the scripting bridge into a separate function for easier reuse.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 12:35 PM
More efficient property iteration (login-tool, 436ebe2)
Rather than getting properties on each login item one by one (each property requiring an Apple Event round-trip) use the "properties" method in conjunction with the arrayByApplyingSelector: method to slurp down all the properties in a single transaction.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 12:23 PM
Teach login-tool to list info about configured login items (login-tool, c5f3beb)
As a way of testing the scripting bridge support, add this new, independent feature.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 12:09 PM
Add System Events target and header (login-tool, e0e0127)
The target consists of a shell script that updates the scripting bridge header for the System Events application. A copy of the header itself (as generated on 10.5.1) is included with this commit.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 11:56 AM
Return EXIT_FAILURE for unrecognized or illegal options (login-tool, 216f8a3)
Previously we returned EXIT_SUCCESS regardless.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 11:45 AM
Target clean-up (login-tool, 960ca1e)
Remove redundant phases from target (there are no headers to copy, no resource manager actions required, and we don't want to install the man page).
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 11:43 AM
Use shared configuration from buildtools (login-tool, 67c223b)
Note that at the same time upgraded the project bundle format to the latest version; this causes Xcode to create an "index" directory in the source root, so I added a top-level .gitignore file at the same time to ignore that.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 11:41 AM
Switch to GC (login-tool, 72eb109)
Switch to Objective-C 2.0 and Garbage Collection.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 11:34 AM
Modernization and clean-up (login-tool, 8790dd9)
Various clean-ups which don't alter the compiled code but improve the source:
- change date format in header for consistency with other projects - remove Subversion buzz - update and normalize copyright - rewrap to 132-columns for better readability - improve alignment for better readability - use C99 for loops - whitespace fixes (trailing whitespace, missing newline at end of file) - use EXIT_SUCCESS rather than 0
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 11:15 AM
Upgrade Xcode project bundle (login-tool, fdbb4cb)
For Xcode 3.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 11:06 AM
Initial import (login-tool, c0a7616)
Corresponding to revision 1 of the old Subversion repository.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 10:52 AM
Source git-completion in profile (snippets, 59685c7)
Assuming location of ~/.git-completion.sh.
Signed-off-by: Wincent Colaiuta <win@wincent.com>
Posted 8:43 AM
December 3, 2007
Install r125, 5 items changed
Minor corrections and tweaks to French localiation (for the "uninstaller" part)
Posted 9:59 AM


