Patrick (patrickwonders) wrote,

  • Mood:

Git, PHP, Lisp, Code, etc.

I keep my website under version control. I have since CVS was the only viable option. It's also been that long since I've made any major updates to my website layout. For posting to forums and blogs, I have been using a directory on my CSH website to hold all of the images that go with my posts. I have been wanting to fix all of these things. I want to ditch CVS. I want to revamp my website. I want to host my images on (at least when I'm posting on forums as user nklein).

Where I'm stuck on the version control stuff...

I used monotone all of last year for everything new. Earlier this year, I toyed with moving to subversion, but after monotone, I don't really want to centralize again. I started using git a few weeks back.

With the Lisp code that I've been writing lately, I have been pushing it to github. I want to move my git repositiories over to, too. At the same time, I want to revamp the hierarchy that's already on github. In particular, I have repositories com.nklein.util.general and com.nklein.util.vec-math. I created them with that scheme in hopes of using git-submodule to make a com.nklein.util project where I can just pull down both at once.

That sounds easy enough, right? But, it's not clear to me yet where I want the .gitmodules file to point. It should point to the globally accessible repository. Of course, I'm not sure yet how this affects people who clone their own copy of the vec-math and then want their clone of the superpackage to refer to their own vec-math. It seems like it should work until I push a change to the .gitmodules file and they pull again. Of course, my change would probably be adding another submodule rather than changing one that's already there. So, it may just work. But, it feels awkward.

Also, I'm not seeing a way to lock a submodule at a particular tag in the sub repository. I had also hoped to use submodules so that I can have projects like com.nklein.really-nifty-app that depend on com.nklein.util.general but where I don't have to update every really-nifty-app if I decide to refactor com.nklein.util.general in the future.

Are superprojects really worth using at all if the clone can't pick and choose where to get the submodules from? or if a superproject can't pick which tag of the submodule to use? I mean, eventually, I'd even like a superprojects like:

  • com.nklein.all-lisp
  • com.nklein.all-code
  • com.nklein.everything

Where I'm stuck on the website revamp...

URLs. I've got lots of links out there to particular URLs in my current site. I don't want to break these. I don't want to pretend they're fixed with nasty mod_rewrite rules. And, I kinda want to reorganize things a bit.

For each package on my website, I have a page describing it with links to tarballs for the latest versions and (when available) PDFs of the noweb from those versions. I'd like to keep this sort of thing. However, with the move to a more distributed version control system, I'd love it if I could have separate repositories for each project's web view and just submodule these into my main tree for the website. I have to get my head around how to organize all of this and how to organize what is sounding like ( 3 * nn + 1 ) repositories where nn is the number of projects: one for each project's source code, one for each projects source code + dependencies, one for the web page for the project, and one overall one for the whole website that submodules in the other web pages for each project.

Where I'm stuck on the image hosting...

Mostly, the image hosting thing is stuck on the whole stuff above. I can't really move the ones that already exist without breaking a ton of links. But, I think that the VCS stuff sorted out for the webite, the images will fall in line. Right now, I do this:

  • Create image
  • scp image to csh
  • Craft post to refer to image @ csh

I think this will just change to:

  • Create image
  • Commit it to VCS
  • Push it to
  • Craft post to refer to image @
Tags: code, git, website
  • Post a new comment


    default userpic

    Your reply will be screened