permalink

25

Yeoman, At Your Service.

When kicking off a new application, we always seem to have libraries we need to manually find and add, boilerplate code that needs to be written and a thorough build and testing process we need to get setup. Today we’re excited to announce the launch of Yeoman – a project which hopes to simplify these steps in your developer workflow.

Package management

At the moment, adding and managing the libraries used in our applications is a very manual process for most developers. Take jQuery: navigate to the project page for the library, grab the latest version and then have to manually save or copy it into our project.

With Yeoman, this can be done using one line in your terminal: yeoman install jquery. That’s it. If you’re working on a Require.js/AMD project, we’ll even automatically wire up your configuration with the paths to the library you’ve just installed.

When jQuery releases a new version, we no longer have to go back to jQuery.com to fetch it. Simply run yeoman update jquery and you’ll have it.

Thanks to Jacob Thornton, Alex MacCaw and their team for working on the Bower registry solution that makes these libraries available. You should check it out.

Generators – scaffolds for your projects

What if you know what type of initial setup you want to start your app off with?

Maybe it’s a simple app that doesn’t require a framework or something more sophisticated that uses AngularJS, Backbone.js or another MVC framework. You might even want to include Twitter Bootstrap in there to give your app a sexy look from the get go.

Rather than manually putting together the same boilerplate for an app every time then write the basic boilerplate for your models, views and so on, you can simply use our generators to do this for you.

yeoman init angular gives you the ability to create new AngularJS apps (or even smaller components of an app like controllers, routes or directives).

yeoman init backbone lets you do the same for Backbone.js apps (you can also individually create models, views, collections and so on)

and we have generators available for many other frameworks (including Ember) out of the box too.

LiveReload Watch Process

In 2012, we shouldn’t have to manually be refreshing our pages whenever we make changes to our application. Whether its Markdown files, scripts or preprocessor files like CoffeeScript or Sass, Yeoman comes with a powerful LiveReload watch process that will automatically reload your app so you don’t have to.

Use yeoman server to kick off a new local server and watch as changes to your app result in an instant reload.

Kick-ass Build System

We all know and love using grunt. It’s by far our build tool of choice for most projects, which is why Yeoman uses it as a baseline for our build process.

On top of this, we’ve added a number of highly customized build tasks that work well within the Yeoman workflow and will help keep your apps fast. Project optimization, declarative handlers for grouping scripts and styles you’d like minified together, application cache generation and more are all supported.

In the future, we’re going to work on exposing our tasks so grunt users who may not wish to use Yeoman can also benefit from the work we’ve done.

And More.

To find out more about Yeoman, take a look at our docs or watch our brand new screencast about the project, please feel free to check out http://yeoman.io.

Feedback

Right now, we’re really interested in hearing what you think about Yeoman. If you have any comments we’d love to hear them and if you have any trouble installing the project or ideas for how we could improve it, feel free to reach out to us on GitHub.

Thanks

I’d like to extend my thanks to my team-mates Paul Irish, Sindre Sorhus, Mickael Daniel, Eric Bidelman and the rest of the open-source contributors that helped make Yeoman a reality. Thanks all!

25 Comments

  1. W00t! I’ve been waiting on this tool, the website/documentation looks great, and the package manager is a must! Having the ability to write our own scaffolds in a Node/JS env is also very compelling.

    I’m excited to try it ASAP and see how Yeoman can replace grunt-bbb in my node/jade/stylus configuration.

    Congrats to the team and thank you very much.

    • Yeoman is primarily targeted at developers creating web applications, however you could certainly create a site using `yeoman init` and even do a lot further with your own generators. I have a feeling there will be some tutorials covering exactly what you’re looking for in the next few weeks/months.

  2. Looks like a very helpful tool to have. Thanks to all the good people behind it.

    Where can I find a full list of out-of-the-box generators? I couldn’t find one on the yeoman website, and github is down so I can’t check there at the moment.

  3. Addy, what is the official stance on yeoman generating code for the persistance (sql, nosql, files, memory) layer? Is it coming in a future release? What are the options being explored?

    • The official stance is that we haven’t started exploring persistance just yet. We were considering taking a look at this in terms of client-side storage to begin with and later moving onto what Yeoman considers to be the complete stack. As we’ve mentioned before, we’re opting to be opinionated here but we’ll do our best to help facilitate flexibility for developers wishing to use different options/technologies.

  4. I’m also running in trouble on CentOS 5doing
    curl -L get.yeoman.io | bash
    % Total % Received % Xferd Average Speed Time Time Time Current
    Dload Upload Total Spent Left Speed
    100 906 100 906 0 0 75809 0 –:–:– –:–:– –:–:– 0
    bash: line 1: syntax error near unexpected token `<'
    bash: line 1: `’

  5. Hi Addy:

    1) Does the LiveReload work with Devices + Simulators/ Emulators when using Phonegap?

    2) Is the LiveReload able to not refresh the browser/device but just to replace a css file with the changed one and see results on the spot?

    3) Question #2 but with images and all assets?

    4) Does Yeoman support LESS / SCSS / SASS ?

  6. Hello Addy,

    first I want to say that yeoman superawesome!

    One question… Do you (or Yeoman team) plan to create generator (like BBB) but for next libs groups together: Backbone boilerplate using CoffeeScript with requirejs CS plugin and Mocha as test tool?

    Thanks and best regards,
    Milos

    • This sounds like something we’ll better support once we move to Grunt collections. In the mean time however, you can always adjust the existing generators to accept flags for CoffeeScript and so on support depending on the type of project you’re looking to create.

      • Thanks Addy for answer… Yes, this is something (similar) that I am doing right now… It will be really great to have this kind of generators in next release!

  7. A great idea, Addy, that would be even greater if there were some documentation that explains in depth the steps of creating a valid yeoman template including what is a template.

    Right now when you generate a template project using ‘$ yeoman init generator Awesome’ all you get is a skeleton project with an empty templates directory. Perhaps generating a basic starting template would be a good idea, as might some documentation that described the template apis.

    I’d like to create a template that uses Twitter Bootstrap and less but I’m left clueless. Point me in the right direction and I will share what I create as well as what I learned from the process with the rest of the community:)

    -
    Jeff
    http://adoseofjavascript.wordpress.com
    http://jefftschwartz.wordpress.com
    https://twitter.com/jefftschwartz

  8. Pingback: Bundling Front-end Resources with RequireJS | Capital Engineering

  9. Windows machines: through Chocolatey you can easily instlall Yeoman.
    Addy, too much spam comments – would be nice to add some plugins to blog them. There is also a lot of place to improve on the security in here.

Leave a Reply

Required fields are marked *.