title: Build multi client project with requirejs and grunt
body: <p>I'm working on a project where the main code based should be used by a bunch of different client. So we have a requirejs project and my initial idea is to have simple <code>bootstrap.js</code> file that will require an <code>app.js</code> files that is different for every client.</p>
  
  <p><strong>bootstrap.js</strong></p>
  
  <pre><code>requirejs(['app'],function(app){
    //some initial code here
    app.start();
  }
  </code></pre>
  
  <p>So the project structure will be look like this:</p>
  
  <pre><code>|_bootstrap.js
  |_commonModules
    |_someModule.js
  |_client1
    |_app.js
    |_modules
      |_module.js
  |_client2
    |_app.js
    |_modules
      |_module.js
  </code></pre>
  
  <p>So my ideas is to compile the app for every client using requirejs' r compiler and set the path to app in every compilation to clientX/app.js by crearting a new build.js for every step like this:</p>
  
  <pre><code>({    
    paths: {
      "app": "client1/app"
    }
  }) 
  </code></pre>
  
  <p>So at the moment I have a grunt build task that is using a bunch of other tasks like uglify, usemin, md5 and so on. Can I create a new task that use this task but changing the requireJs settings for every client? Or is there a better way to achieve my goals?</p>