Pro Yearly is on sale from $80 to $50! »

Contributing to Ember

Contributing to Ember

Confused about how the release process works? Curious what the heck feature flags are? Wondering which commit prefix you should use for your latest pull request? This talk answers these questions (and many more).

It includes insights into the release process, feature flagging, the build process, which commit prefixes to use, and how to create custom builds with features enabled by default.

0dfd10ad198ae5a87640da046a77a90a?s=128

Robert Jackson

March 25, 2014
Tweet

Transcript

  1. Contributing to Ember THE INSIDE SCOOP http://flic.kr/p/gQ8PaV

  2. Who the heck is this guy? • Ember Release Management

    Team • Frequent Ember.js Contributor • General OSS addict twitter: rwjblue github: rjackson
  3. About DockYard • Hosting WickedGoodEmber conference (register at wickedgoodember.com) •

    Contact us at dockyard.com.
  4. Why is Ember Awesome?

  5. Why is Ember Awesome? Collection of Concepts/Ideas (possibly the only

    JS “Framework”)
  6. Why is Ember Awesome? • Community • We need your

    ideas/contributions! • Current at 330+ Contributors
  7. Okay, how can I help? • Fix / Cleanup documentation

    • Report and/or Fix Bugs you Find • Submit new features
  8. Documentation https://flic.kr/p/5mgRqa

  9. Helping with Docs • Often, thankless. • THANK YOU! •

    Prefix Commit
  10. Commit Prefix - Docs • `[DOC] Fixed typo in blah.`

    • `[DOC beta] Fixed typo in blah.` • `[DOC release] Fixed typo in blah.`
  11. Bug-fixes https://flic.kr/p/2xvHcU

  12. Its messed up, lemme fix it • Add test showing

    regression • Fix issue • Prefix commit
  13. Commit Prefix - Bug-fixes • `[FEATURE ember-metal-zomg] Fix blah` •

    `[BUGFIX beta] Fix dummy` • Only severe regressions will be pulled into release channel.
  14. Unless its a security vuln... • Email security@emberjs.com • Work

    with the Core Team on a fix • Read the full policy at: emberjs.com/security
  15. Features https://flic.kr/p/4CrXVC

  16. Huh, what are features? • New API’s • Backwards compat

    changes to API’s • Hidden behind a feature flag
  17. What is a feature flag? It’s just an `if` block

    used by the build process.
  18. Why Feature Flags? • Keep releases stable • Allow faster

    iteration • Help ensure SemVer
  19. How does it work? • `defeatureify` processes builds • Can

    strip flagged code
  20. What is enabled? Check the `features.json` file.

  21. What does this mean? `true` `false` `null` Enable & remove

    flags Disable & remove Disable & leave
  22. Features in Channels Channel Flags In Build Canary Yes Beta

    No Release No
  23. Can I enable features in beta/release builds? YES!!! But you

    may not want to…
  24. YES, PLEASE DO!!! Testers welcome, the more the merrier! Can

    I enable features in canary builds?
  25. Awesome, how do I do it? EmberENV = { FEATURES:

    { 'query-params-new': true } };
  26. How can I contribute one? • Add to features.json (null

    value) • Add to FEATURES.md • Hide changes behind flags • Good tests (also behind flags) • Prefix commit
  27. Choosing flag name Package Name + Short Feature Name `ember-metal-zomg`

  28. Add to features.json • Add as last line • Set

    value to `null` • Rebase on EVERY change
  29. Add to FEATURES.md Add an entry with a clear description.

    Include PR link for further reading.
  30. Hide changes behind flags: if (Ember.FEATURES.isEnabled('ember-metal-zomg')){ // Your feature code

    here } else { // Code to execute when disabled }
  31. Check the “Enable Opt Features” check box in the QUnit

    UI. How do I run the tests?
  32. Commit Prefix - Features Use FEATURE + feature name: `[FEATURE

    ember-metal-zomg]`
  33. Merge me, pretty please? • Review takes time • Please

    be patient • Please be polite :D
  34. OK, its merged, now what? • Security Audit • Reviewed

    by Core Team • Go/No-Go Decision
  35. Release Cycle https://flic.kr/p/7JxoN6

  36. Process • 3 Channels • 6 Week Release Cycles

  37. Canary • New Features • Bugfixes • tldr; Everything

  38. Beta • Branched from Canary • Bug fixes • Doc

    updates • Weekly Releases
  39. Release • Branched from Beta • Doc updates • Major

    Regressions • Security Fixes
  40. Commit Prefix Recap https://flic.kr/p/7Zd6BJ

  41. Commit Prefix - Recap [DOC channel] Message. [BUGFIX channel] Message.

    [FEATURE feature-name] [SECURITY CVE-111-1111]
  42. [DOC channel] • Use for documentation changes. • Target affected

    channel.
  43. [BUGFIX channel] • Use for bug-fixes (duh). • Target affected

    channel • Only severe bugs will warrant new tag/release.
  44. [FEATURE feature-name] • Use for new features • Use for

    bug-fixes to features.
  45. [SECURITY CVE-000-0000] • Used exclusively by security team • Simultaneous

    publishing and release
  46. Contributions welcome! Seriously, I mean it. https://flic.kr/p/AApJr

  47. Thank You Knowing is half the battle...