Skip to main content

Lack of posting

Sorry for the recent drought in posts. There is a problem between Blogger and Writely which stops me from publishing onto this blog. The Writely crew are on the job, and the recent acquisition by Google (told ye so) shouldn't make it any trickier for them to get it working again (Google also owns Blogger).

I've written a handful posts on Writely waiting to get out. Will release them gradually after the issue has been fixed.

Comments

Popular posts from this blog

Git-SVN Mirror without the annoying update-ref

This post is part of  a series on Git and Subversion . To see all the related posts, screencasts and other resources, please  click here .  So no sooner than I had done my git-svn presentation at JavaZone , I got word of a slightly different Git-SVN mirror setup that makes it a bit easier to work with: In short, my old recipe includes an annoying git update-ref step to keep the git-svn remote reference up to date with the central bare git repo. This new recipe avoids this, so we can simply use git svn dcommit   directly. So, longer version, with the details. My original recipe is laid out in five steps: Clone a fresh Git repo from Subversion. This will be our  fetching repo. Set up a  bare repo. Configure pushing from the fetching repo to bare repo In the shoes of a developer, clone the repo Set up an SVN remote in the developer's repo In the new approach, we redefine those last two steps: (See the original post for how to do the fir...

Git Stash Blooper (Could not restore untracked files from stash)

The other day I accidentally did a git stash -a , which means it stashes *everything*, including ignored output files (target, build, classes, etc). Ooooops.. What I meant to do was git stash -u , meaning stash modifications plus untracked new files. Anyhows, I ended up with a big fat stash I couldn't get back out. Each time I tried, I got something like this: .../target/temp/dozer.jar already exists, no checkout .../target/temp/core.jar already exists, no checkout .../target/temp/joda-time.jar already exists, no checkout .../target/foo.war already exists, no checkout Could not restore untracked files from stash No matter how I tried checking out different revisions (like the one where I actually made the stash), or using --force, I got the same error. Now these were one of those "keep cool for a second, there's a git way to fix this"situation. I figured: A stash is basically a commit. If we look at my recent commits using   git log --graph --...

Git-SVN Mirror for multiple branches

This post is part of  a series on Git and Subversion . To see all the related posts, screencasts and other resources, please  click here .  This extends the posts where I explained how to set up a git-svn mirror for a single directory. NOTE: If you just want to use Git against a SVN repo on your own, stop reading ,now, and stick to the git-svn basics. However, if you want a setup where you can share a Git repository with colleagues and friends while still interfacing with Subversion, keep reading. I'll show how to set up a git-svn mirror for a standard Subversion project with trunk , branches and tags . It's a bit like the single directory mirror, but in order to keep all branches in sync, it's a bit more fiddling. The good part is that this setup enables us to cherry-pick commits from one branch to the other. This is slightly smoother than using svn merge . First of all, let's repeat how our Subversion and Git-repositories look physically (roughly the sa...

Git tools for keeping patches on top of moving upstreams

At work, we maintain patches for some pretty large open source repositories that regularly release new versions, forcing us to update our patches to match. So far, we've been using basic Git operations to transplant our modifications from one major version of the upstream to the next. Every time we make such a transplant, we simply squash together the modifications we made in the previous version, and land it as one big commit into the next version. Those who are used to very stringent keeping of Git history may wrinkle their nose at this, but it is a pragmatic choice. Maintaining modifications on top of the rapidly changing upstream is a lot of work, and so far we haven't had the opportunity to figure out a more clever way to do it. Nor have we really suffered any consequences of not having an easy to read history of our modifications - it's a relatively small amount of patches, after all. With a recent boost in team size, we may have that opportunity. Also the need for be...

Git+SVN #5: Centralized Git-SVN Mirror

This post is part of  a series on Git and Subversion . To see all the related posts, screencasts and other resources, please  click here .  Another episode on how to live with Git and Subversion in parallel: Only a few days left till GearConf, where I will be repeating the exercise, adding all sorts of useful hints and tips on the way. NOTE : At the end of the cast, I presented this little shell-script that I normally use for committing: #! git update-ref refs/remotes/git-svn refs/remotes/origin/master git svn dcommit Some more background: git svn dcommit actually updates the refs/remotes/git-svn However, in the case that I first do a git pull from the bare repo, getting the new commits via the "pure" git command, no svn refs are updated! Example: Let's say bob commits a change. John then updates his repo: tfnico@flint:~/john/website/> git pull --rebase remote: Counting objects: 8, done. remote: Compressing objects: 100% (4/4), done. remote: ...