Create your first web application
In three short steps you are now going to create a functioning 'Hello World' application. It will be finished in UploadApp.
Use appcfg.rb (appcft.rb.bat on windows) to make an application skeleton. This is where your configuration files will be. When you run appcfg.rb or dev_appserver.rb, always make sure that you are in this directory.
$ appcfg.rb generate_app hello
$ cd hello
And you have finished ... yep that's all you need for now.
To run your program, make sure you are still in the "hello" directory and type
hello $ dev_appserver.rb .
Watch as all of the extra files that you need are automatically copied into the right places.
Now have a look at
Your script has been used it two ways.
First, dev_appserver looked for any configuration information that you put into config.ru and generated all the xml configuration files. As you didn't put in any configuration information, it just used the defaults.
Second your script is called when a request is sent to your web application. It takes in an argument env, and returns the result 'Hello', tells your browser that it is text/html and that everything worked fine (code 200). Don't worry about the text/html and 200 stuff, the smart Ruby guys have made it even easier (next section).
Have a quick look at what is now in the hello directory to see all the work dev_appserver did for you.
One page to go - now we need to UploadApp!