Fantastic to find your script as I'm following Mark Jaquith's deploy strategy using Capistrano (V3) and Search Replace DB as described here and your script makes it so easy, especially compared to having to use an option like WP_Migrate_DB Pro:
http://markjaquith.wordpress.com/2012/05/26/wordpress-skeleton/
As a result of using Capistrano to deploy WordPress, my Use Case may be slightly trickier than the current one SyncDb is based on, mainly because as part of the Capistrano deployment, everything WordPress is moved to a subdirectory (named /current) of public_html on my server.
To complicate things further, my site is Multisite WordPress based on subdirectories.
In either case, I'm running into problems bringing my site up on my staging server after using SyncDB. It looks like this is due to the replace commands only substituting the local URL for the server URL, as I also need to update the WP_SITEURL in the database to include a new subdirectory (see below for full description).
So let me describe what I'm trying to do as simply as possible:
Scenario
Local Server Environment (Macbook Pro)
Based on wp-skeleton at: https://github.com/markjaquith/WordPress-Skeleton
Local Site: example.dev
2 Multisite sites based on language: example.dev/en and example.dev/de
Apache Root directory is: ../example.dev/
WordPress core is in subdirectory: ../example.dev/wp
WP_SITEURL was defined manually in the Administration > Settings > General panel to be example.dev/wp so this value lives in the database and not in wp-config.php.
Staging Server Environment (Hosted Service Provider)
Staging Server: staging.example.com
Apache Root directory is ../staging.example.com/public_html
WordPress core is in subdirectory: ../staging.example.com/public_html/current/wp
Question
So I think the problem may be that the substitutions I see being made in SyncDB are only example.dev to staging.example.dev, leaving my database setup inconsistent with my code structure? What do you think?
If so, I need to make extra updates in my staging server DB to take account of WordPress core being moved from /wp to /current/wp?
Is there an easy way I can modify SyncDb to take account of this?