On Jan 18, 2007, at 8:31 PM, Ezra Zygmuntowicz wrote:

Hi~

On Jan 18, 2007, at 11:46 AM, Jamis Buck wrote:


Hey Ezra,

I really appreciate the offer. I'm afraid my ideas are still in the vague/proof-of-concept/experimenting state, but right now these are the things I know that I want to happen for Capistrano 2.0:

* Decouple the core from the standard recipes. This should slim the core stuff down quite a bit.

* Decouple the deployment method from the SCM, so you can use any SCM you want with any supported deployment method (e.g. "checkout", "export", "copy", "rsync", etc.)

* Get serious about the tests. Right now they're admittedly weaksauce. My testing-fu is quite challenged by the ssh requirement. It'd be lovely to have a "mock server" that ships with Net::SSH, which could be used to do testing with Net::SSH, but that's a tall order.

I've also been toying with the idea of having a minimal DSL for writing shell scripts, primarily so that capistrano's default recipes can work with non-POSIX shells (like csh and tcsh). This would have the happy side-effect of making it easier to write simple conditionals in scripts; currently it requires shell- script- fu as well as a knowledge of how capistrano is going to mangle the script when it runs it.


So this part sounds pretty fun to me ;) Can you perhaps show me a few examples of some DSL syntax you would like to see and what things should be supported?

I actually haven't spent a lot of time thinking about it, but the little I've sketched out has turned out something like this:

  run do |cmd|
    cmd.ln_nsf "foo", "bar"
    cmd.echo("some string") >> "/path/to/log.txt"
    cmd.if(~cmd.directory?("some/dir")) do
      cmd.mkdir_p "some/dir"
    end
  end

The idea is not to mimic every possible aspect of shell scripting--if people need some esoteric feature, they are more than welcome to drop down to raw shell script and do it themselves. Ultimately, what I'd like is for the DSL to be able to do everything that the standard recipes need to do, as well as the SCM modules, so that a translator can be written to emit both POSIX shell script, as well as csh/tcsh compatible scripts.

I'll leave it in your capable hands, Ezra. :) Thanks for the offer to help!

- Jamis

--~--~---------~--~----~------------~-------~--~----~
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at http://groups.google.com/group/capistrano
-~----------~----~----~----~------~----~------~--~---

Reply via email to