subversion 1.5 and unexpected format errors with blank info
July 22nd, 2008
We use subversion at work, subversion 1.5 specifically. I was working on a project with a lot of externals and ran into the following error:
Unrecognized format for the relative external URL '' .Boy is that informative. After poking around and doing all sorts of re-organization of the externals I noticed that I had a dupe. Removing the duplicate external solved the problem. Hope that helps.git lost-found and no branch
June 30th, 2008
After a little hacking session and some unpleasant ruby 1.8.6 vs 1.8.7 fun, I ran into another interesting tidbit about git. As with most powerful tools it will gladly allow you to blast your foot off. Wouldn't ya know, my aim was well aligned with my feet a few moments ago. git checkout some/remote_branch. I thought I was switching over to a remote branch I'd created on another machine, so that I could test and work on this other machine. Little did I know that I had entered the "(no branch)" state. At this point I was pretty much gunning to create orphaned blobs, commits and other such items. After creating a few, I wanted to push those changes to the upstream server (github in this case) after merging them into the HEAD.
After checking out the master branch, I quickly found out that my little "(no branch)" wasn't reachable. A little poking around git rendered, git fsck --lost-found, which will identify orphaned commits and entities. Once you find the commit id you can checkout the master branch again and git merge my-lost-commit-id.
FastXML 0.1.93
May 6th, 2008
A long while ago I started work on a simple hpricot-like interface to libxml for ruby. I've finally push out an initial version, and it's available on the gem servers now just gem install fastxml. You can find the code on github.
Here's a sample of it's usage:
1 2 3 4 |
require 'fastxml' doc = FastXml( open( 'test.xml' ) ) (doc/"//a").each { |a| puts a.attr['href'] } |
Here's a simple synthetic benchmark. We just load a simple xml file attempt to do an xpath search. It's worth noting that the regular libxml binding is very speedy, because it doesn't actually match anything. Libxml annoyingly want's all xpath queries namespace qualified, that doesn't work out well if you have no root namespace.
(in /Users/segfault/Devel/fastxml)
ruby ./benchmarks/speedtest.rb
user system total real
fastxml.new 0.000000 0.000000 0.000000 ( 0.001211)
fastxml.to_s 0.000000 0.000000 0.000000 ( 0.000537)
fastxml.search 0.000000 0.000000 0.000000 ( 0.000315)
hpricot.new 0.020000 0.000000 0.020000 ( 0.021583)
hpricot.to_s 0.000000 0.000000 0.000000 ( 0.002366)
hpricot.search 0.000000 0.000000 0.000000 ( 0.000462)
libxml.new 0.000000 0.000000 0.000000 ( 0.001274)
libxml.to_s 0.000000 0.000000 0.000000 ( 0.000421)
libxml.search 0.000000 0.000000 0.000000 ( 0.000175)
REXML.new 0.020000 0.000000 0.020000 ( 0.018574)
REXML.to_s 0.010000 0.000000 0.010000 ( 0.003909)
REXML.xpath 0.000000 0.000000 0.000000 ( 0.001838)
me and my git-svn
April 3rd, 2008
I recently switched a bunch of my projects over to git. Why? All the cool kids are doing it, I figured I'd give it a shot. Either way I ran into a few bumps with the git-svn stuff. Everything went really well until I tried to push back my changes from git. I'd been committing changes to my repo and pushing them to github/hasno without issue. I ran into errors when I tried to git-svn dcommit.
Here's what I'm currently calling the right way, as usual ymmv:
-
init if you haven't done i already, check .git/config for an svn-remote entry...
git-svn init <repo url> -
pull the svn revision information. a bunch of info should scroll by matching svn revisions to git sha1 revisions.
git-svn fetch -
this will yeild a list of local & remote branches, you should see trunk in the list
git branch -a* master origin/HEAD origin/local-svn origin/master tags/release-0.1.23 tags/release-0.2.42 tags/release-0.2.44 tags/release-0.2.50 trunk
-
switch to a local branch based on the trunk remote branch
afaik you really don't want to be doing any of this type of stuff in a remote branchgit checkout -b local-svn trunk -
now we need to pull your local changes from your master branch to your local-svn branch
git merge master
it's worth noting that you could do agit rebase, but when I tried that I couldn't use git-svn dcommit -
go through and merge any conflicts. then
git commit. at this point you cangit dcommit
So if all that was how I got it working, what did I run into along the way... Well I'm glad you ask. Here's a list of errors and the reason for them afaik:
- Unable to determine upstream SVN information from HEAD history
- You have a recent commit that doesn't have any history in .git/ref/remote/svn or .git/svn. It also doesn't have the git-svn-id: key in the commit message.
- [svn-remote "svn"] unknown
- Did you manually create the svn-remote entry, or specify a different name? If so you need to pass that on to the commands, they seem to assume it's named svn.
- fatal: bad default revision 'refs/remotes/git-svn'
- Somethings amiss with your svn-remote entry in
.git/config
That's about it for me, if you've seen those errors and can add some detail or shed some light on a better way please do share. As of this moment ruby-hl7 is synched up.
uninformative messages (MSB3247,MSB4051)
February 29th, 2008
warning MSB3247: Found conflicts between different versions of the same dependent assembly.
Seriously how is that helpful? Guess what the solution is according to VS2k8:
Double-click the warning and then select "Yes" when you get the prompt, "Do you want to fix these conflicts by adding binding redirect records in the app.config file?"
That has to be the most pointless suggestion ever. This warning doesn't go away, nor is there any indication in the message as to the culprit. The XML it generates points at some candidates tho.
Now on to see why the same solution builds in VS2k8, but fails when using msbuild on the command line.
Solution file warning MSB4051: Project {ED0038FA-D90E-4C84-AE64- 245BC76D2406} is referencing a project with GUID {BF209BE8-334A-45E8-940E-CFEF0 DEE21EE}, but a project with this GUID was not found in the .SLN file.Apparently that means I'm missing an EndProject line. Wonder why that couldn't have been fixed or brought to my attention by studio...? It can also mean that there is indeed an invalid project guid reference in one of the subproject's csproj files. Double check the project list in the solution versus the