From 5f4c6dffbc4d045f13d75c333bc78ed9e154491a Mon Sep 17 00:00:00 2001 From: Josh Holtrop Date: Sun, 4 Aug 2013 15:44:22 -0400 Subject: [PATCH] update README and give some usage examples --- README.md | 17 +++++++++++++++-- 1 file changed, 15 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index c8bfbc1..59b99f3 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@ # Rscons -TODO: Write a gem description +Software construction library inspired by SCons and implemented in Ruby ## Installation @@ -18,7 +18,20 @@ Or install it yourself as: ## Usage -TODO: Write usage instructions here + RScons::Environment.new do |env| + env.Program('program', Dir['*.c']) + end + + main_env = RScons::Environment.new do |env| + env.build_dir('src', 'build/main') + env.Program('program', Dir['src/**/*.cc']) + end + + debug_env = main_env.clone do |env| + env.build_dir('src', 'build/debug') + env['CFLAGS'] = ['-g', '-O0'] + env.Program('program-debug', Dir['src/**/*.cc']) + end ## Contributing