Here is one way to do this
You need to create an event listener that listens to events under the node you are looking for (/etc/design)
http://blogs.adobe.com/experiencedelivers/experience-management/event_handling_incq/
If this event is triggered then call the following code to create version
var params = {};
params["path"] = path;
params["_charset_"] = "utf-8";
params["cmd"] = "createVersion";
params["comment"] = comment;
CQ.HTTP.post("/bin/wcmcommand", null, params);