Catching "File Saved" or CMD-W Signal?

Hey,

How does git/svn know to to finish committing your changes after you
close the commit message (assuming you open it in TextMate or
something)?

I would like to create something similar, where you run a command, it
opens a file for you to fill in the blanks, and when you save and close
it, the process finishes, how would I do that?

Thanks so much,
Lance

It spawns the child process (editor) and when it quits it checks the
status code of the process. If it was successful it continues with the
commit.

It spawns the child process (editor) and when it quits it checks the
status code of the process. If it was successful it continues with the
commit.

Thanks, that’s how it works!

Anyone have a quick snippet to make that happen? How does it know when
it quits, and how does it continue the process, that seems like I’d need
to look through a lot of blogs :stuck_out_tongue:

Thanks,
Lance

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs