UNPKG

can

Version:

MIT-licensed, client-side, JavaScript framework that makes building rich web applications easy.

714 lines (458 loc) 19.2 kB
<!DOCTYPE html> <!--#################################################################### THIS IS A GENERATED FILE -- ANY CHANGES MADE WILL BE OVERWRITTEN INSTEAD CHANGE: source: [object Object] @page guides/contributing/releases ######################################################################## --> <html lang="en"> <head> <meta charset="utf-8"> <title>CanJS - Releases</title> <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no"> <link rel="stylesheet" type="text/css" href="../../static/bundles/bit-docs-site/static.css"> <link rel="shortcut icon" sizes="16x16 24x24 32x32 48x48 64x64" href="/docs/images/canjs_favicon.ico"> <link rel="apple-touch-icon" sizes="57x57" href="../../../docs/images/canjs_favicon_57x57.png"> <link rel="apple-touch-icon-precomposed" sizes="57x57" href="../../../docs/images/canjs_favicon_57x57.png"> <link rel="apple-touch-icon" sizes="72x72" href="../../../docs/images/canjs_favicon_72x72.png"> <link rel="apple-touch-icon" sizes="114x114" href="../../../docs/images/canjs_favicon_114x114.png"> <link rel="apple-touch-icon" sizes="120x120" href="../../../docs/images/canjs_favicon_128x128.png"> <link rel="apple-touch-icon" sizes="144x144" href="../../../docs/images/canjs_favicon_144x144.png"> <link rel="apple-touch-icon" sizes="152x152" href="../../../docs/images/canjs_favicon_152x152.png"> <meta content="yes" name="apple-mobile-web-app-capable"> <meta name="apple-mobile-web-app-status-bar-style" content="white-translucent"> <script> (function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){ (i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o), m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m) })(window,document,'script','https://www.google-analytics.com/analytics.js','ga'); ga('create', 'UA-2302003-11', 'auto'); ga('send', 'pageview'); </script> </head> <body> <input type="checkbox" id="nav-trigger" class="nav-trigger"/> <label for="nav-trigger">Menu</label> <div id="everything"> <div id="left" class="column"> <div class="top-left"> <div class="brand"> <div class="logo"> <a href="../../../index.html" alt="CanJS"></a> <div class="dropdown project-dropdown"> <a href="https://donejs.com/">DoneJS</a> <a href="http://stealjs.com/">StealJS</a> <a href="http://jquerypp.com/">jQuery ++</a> <a href="https://funcunit.com/">FuncUnit</a> <a href="http://documentjs.com/">DocumentJS</a> </div> </div> <div class="version"> <div class="version-number"> 3.0.0 </div> <div class="dropdown version-dropdown"> <a href="https://v2.canjs.com">2.3.27</a> </div> </div> </div> <div class="search-bar"> <p> &nbsp; </p> </div> </div> <div class="bottom-left"> <div class="social-side-container"> <ul class="social-side"> <li> <a class="header-mobile github" href="https://github.com/canjs/canjs" target="_blank"><img class="social-icon-small" src="../../../docs/images/github.png">Github</a> </li> <li> <a class="header-mobile twitter" href="https://twitter.com/canjs" target="_blank"><img class="social-icon-small" src="../../../docs/images/twitter.png">Twitter</a> </li> </ul> <ul class="social-side"> <li> <a class="header-mobile" href="https://gitter.im/canjs/canjs" target="_blank">Chat</a> </li> <li> <a class="header-mobile" href="http://forums.donejs.com/c/canjs" target="_blank">Forum</a> </li> </ul> </div> <ul> <li class=" parent expanded"> <a class="page" href="../../guides.html" title="Welcome to CanJS! These guides are here to help you develop and improve your relationship with CanJS. After all, picking a JavaScript framework is a commitment. We want CanJS to be the framework you marry. This page helps you know how advance through the different stages of this relationship:"> Guides </a> <ul> <li> <span>introduction</span> <ul> <li class=" "> <a class="page" href="../mission.html" title="Learn about CanJS&#x27;s mission, why it matters, and how we&#x27;ve worked (and will keep working) to accomplish it."> Mission </a> </li> <li class=" "> <a class="page" href="../technical.html" title=""> Technical Highlights </a> </li> <li class=" "> <a class="page" href="../who-uses-canjs.html" title=""> Who uses CanJS? </a> </li> </ul> </li> <li> <span>experiment</span> <ul> <li class=" "> <a class="page" href="../chat.html" title="This guide walks through building real time chat application with CanJS&#x27;s Core libraries. It takes about 30 minutes to complete."> Chat Guide </a> </li> <li class=" "> <a class="page" href="../todomvc.html" title="This guide walks through building a slightly modified version of TodoMVC with CanJS&#x27;s Core libraries and can-fixture. It takes about 1 hour to complete."> TodoMVC Guide </a> </li> <li class=" "> <a class="page" href="../atm.html" title="This guide walks through building and testing an ATM application with CanJS&#x27;s Core libraries. It teaches how to do test driven development (TDD) and manage complex state. It takes about 2 hours to complete."> ATM Guide </a> </li> <li class=" "> <a class="page" href="../setup.html" title="CanJS is packaged in multiple ways so that it can fit into any development workflow. Learn how to setup CanJS in different environments."> Setting up CanJS </a> </li> </ul> </li> <li> <span>commitment</span> <ul> <li class=" "> <a class="page" href="../api.html" title="This page walks through how to use and understand CanJS&#x27;s API documentation."> API Guide </a> </li> <li class=" "> <a class="page" href="../examples.html" title=""> Examples </a> </li> <li class=" "> <a class="page" href="../../roadmap.html" title="Learn about CanJS&#x27;s future plans and how we make them, and how you can influence them."> Roadmap </a> </li> <li class=" "> <a class="page" href="../../migrate-3.html" title=""> Migrating to 3.0 </a> </li> </ul> </li> <li> <span>contribute</span> <ul> <li class=" "> <a class="page" href="bug-report.html" title="Learn how to submit a bug report."> Bug Report </a> </li> <li class=" "> <a class="page" href="code.html" title="Learn how contribute a code change to CanJS."> Code </a> </li> <li class=" "> <a class="page" href="documentation.html" title="Learn how to improve CanJS&#x27;s site and documentation."> Documentation </a> </li> <li class=" "> <a class="page" href="evangelism.html" title="Learn about resources that can help you spread the word about CanJS."> Evangelism </a> </li> <li class=" "> <a class="page" href="feature-suggestion.html" title="Learn how to suggest a feature."> Feature Suggestion </a> </li> <li class="current parent expanded"> <a class="page" href="releases.html" title="Release and hosting information for CanJS maintainers."> Releases </a> </li> </ul> </li> </ul> </li> <li class=" "> <a class="page" href="../../can-core.html" title="The best, most hardened and generally useful libraries in CanJS."> Core </a> </li> <li class=" "> <a class="page" href="../../can-ecosystem.html" title="Useful libraries that extend or add important features to the core collection."> Ecosystem </a> </li> <li class=" "> <a class="page" href="../../can-infrastructure.html" title="Utility libraries that power the core and ecosystem collection."> Infrastructure </a> </li> <li class=" "> <a class="page" href="../../can-legacy.html" title="Former libraries that we still accept patches for, but are not under active development."> Legacy </a> </li> </ul> </div> </div> <div id="right" class="column"> <div class="top-right"> <div class="top-right-top"> <ul class="top-right-bitovi"> <li class="dropdown"> <a href="http://bitovi.com" class="bitovi icon-bits">Bitovi</a> <ul class="dropdown-menu"> <li><a href="http://bitovi.com">Bitovi.com</a></li> <li><a href="http://bitovi.com/blog/">Blog</a></li> <li><a href="http://bitovi.com/consulting/">Consulting</a></li> <li><a href="http://bitovi.com/training/">Training</a></li> <li><a href="http://bitovi.com/open-source/">Open Source</a></li> </ul> </li> </ul> <div class="brand"> <div class="logo"> <a href="../../../index.html" alt="CanJS"></a> </div> </div> <ul class="top-right-links"> <li> <a href="https://gitter.im/canjs/canjs">Chat</a> </li> <li> <a href="http://forums.donejs.com/c/canjs">Forum</a> </li> <li> <a class="github-button nav-social" href="https://github.com/canjs/canjs" data-count-href="/canjs/canjs/stargazers" data-count-api="/repos/canjs/canjs#stargazers_count">Star</a> </li> <li> <a href="https://twitter.com/canjs" class="twitter-follow-button nav-social" data-show-count="true" data-show-screen-name="false">Follow @canjs</a><script async src="//platform.twitter.com/widgets.js" charset="utf-8"></script> </li> </ul> </div> <div class="breadcrumb"> <li><a href="../../../index.html">CanJS</a></li> / <li><a href="../../guides.html">Guides</a></li> / <li><a href="releases.html">Releases</a></li> <li class="breadcrumb-dropdown">/ <a> On this page</a> <ul class="on-this-page"></ul> </li> <div class="nav-toggle" title="Back to top"></div> </div> </div> <div class="bottom-right"> <article> <section class="title"> <div class="page-type"> <h1>Releases</h1> <div>page</div> </div> <section class="description"> <p>Release and hosting information for CanJS maintainers.</p> </section> </section> <section class="on-this-page-table"> </section> <section class="title-footer"> <ul class="title-links"> <!-- <li><a href="#">docco</a></li> --> <li><a href="//github.com/canjs/canjs/tree/v3.0.0/docs/can-guides/contribute/releases.md">source</a></li> <!-- <li><a href="#">download</a></li> --> <!-- <li><a href="#">tests</a></li> --> </ul> </section> <section class="body"> <p>For maintainers of CanJS and its submodules this guide describes</p> <ul> <li>How continuous integration is set up</li> <li>How dependencies are kept up to date</li> <li>How to make a releases of CanJS subprojects and the main package</li> <li>How to update the CanJS website</li> </ul> <h2>Continuous integration</h2> <h3>Travis CI</h3> <p>All repositories automatically run their tests in <a href="https://travis-ci.org/">Travis CI</a> using the <code>npm test</code> command (browser tests use Firefox as their target browser). If <code>npm test</code> is passing locally but not on Travis CI</p> <ul> <li>Try setting the <code>DEBUG=testee*</code> environment variable in <code>travis-ci.org/canjs/&lt;repository&gt;/settings</code> to get more information.</li> <li>Run the tests on an Ubuntu VM (e.g. <a href="https://www.virtualbox.org/wiki/Linux_Downloads">Ubuntu for Virtualbox</a>)</li> </ul> <h3>Saucelabs</h3> <p><a href="https://github.com/canjs/canjs">canjs/canjs</a> also runs the tests of all dependencies in the supported browsers on <a href="https://saucelabs.com">Saucelabs</a>:</p> <p><a href="https://saucelabs.com/u/canjs"><img src="https://saucelabs.com/browser-matrix/canjs.svg" alt="Sauce Test Status" /></a></p> <p>To view Saucelabs test runs and results, request an invite from a Saucelabs user that has access to the <code>canjs</code> Saucelabs project (existing users can send invites under <a href="https://saucelabs.com/beta/users/canjs">my account</a>). Saucelabs tests can be run locally via</p> <pre><code>npm run ci </code></pre> <h2>Updating dependencies</h2> <p>All CanJS repositories are set up with <a href="https://greenkeeper.io/">Greenkeeper</a>. Greenkeeper tracks dependencies and creates a branch for every new version coming in. This will trigger Travis CI to run the tests and if a dependency update breaks the tests or a breaking (major) version was released, it will create a pull request.</p> <p>Greenkeeper is free for open source projects and works on the CanJS organization level. To add a new project or change the status of an existing project:</p> <ul> <li>Install the command line via <code>npm install greenkeeper -g</code></li> <li>Run <code>greenkeeper login</code> to log in via GitHub</li> <li>For more information run <code>greenkeeper</code> or <code>greenkeeper start</code></li> <li>To enable a project, in the project folder run <code>greenkeeper enable</code></li> </ul> <h2>Making releases</h2> <p>All versions should follow the <a href="http://semver.org/">Semantic Versioning</a> guidelines in the form of <code>MAJOR.MINOR.PATCH</code> for</p> <ul> <li><code>MAJOR</code> version when you make incompatible API changes,</li> <li><code>MINOR</code> version when you add functionality in a backwards-compatible manner, and</li> <li><code>PATCH</code> version when you make backwards-compatible bug fixes.</li> </ul> <p>Before making any release please make sure that</p> <ul> <li>you have write access to the GitHub repository you want to publish</li> <li>have an <a href="https://www.npmjs.com">npm</a> account and are logged in on the CLI tool (<code>npm whoami</code>)</li> <li>your user is a collaborator on npm. You can ask an existing collaborator to add you. Existing collaborators can be listed via <code>npm owner ls &lt;packagename&gt;</code> or on the npm module page (e.g. <a href="https://www.npmjs.com/package/can-route">can-route</a>)</li> </ul> <h3>Releasing CanJS subprojects</h3> <p>All CanJS subprojects modules have the same structure which allows making releases through NPM scripts.</p> <p>To make a release:</p> <ul> <li>move to the <code>master</code> branch</li> <li>fetch all latest changes from the repository</li> <li>reinstall all Node modules in their latest version</li> </ul> <pre><code>git checkout master git fetch --all &amp;&amp; git rebase npm cache clean rm -rf node_modules npm install </code></pre> <p>Then run <code>npm run release:&lt;versiontype&gt;</code>. For example, to make a <code>PATCH</code> release:</p> <pre><code>npm run release:patch </code></pre> <p>This will run the tests, build, bump the version number accordingly and publish the module to <a href="https://www.npmjs.com/">npm</a>.</p> <h3>Releasing the CanJS main project</h3> <p>In <code>canjs/canjs</code> all dependencies are locked to their latest version. It uses Greenkeeper (see previous section) to receive a pull request whenever a new release has been made.</p> <p>When merging a Greenkeeper pull request, review the version number, run <code>npm install</code> to get the latest versions and then publish the main repository according to the version number change. For example, if the merged modules <code>MINOR</code> version changed run</p> <pre><code>npm run release:minor </code></pre> <h2>Updating canjs.com</h2> <p>canjs.com is hosted on <a href="https://pages.github.com/">GitHub pages</a> from the <a href="https://github.com/canjs/canjs/tree/gh-pages">canjs/canjs#gh-pages</a> branch. To generate and push a new version of the website, verify you have push access to that branch. Then get all latest changes via:</p> <pre><code>git checkout master git fetch --all &amp;&amp; git rebase npm cache clean rm -rf node_modules npm install </code></pre> <p>We also have to delete the local <code>gh-pages</code> branch:</p> <pre><code>git branch -D gh-pages </code></pre> <p>Then run</p> <pre><code>make </code></pre> <p>This wil generate and publish a new version of the website.</p> </section> <script type="text/javascript"> var docObject = {"src":{"path":"docs/can-guides/contribute/releases.md"},"description":"Release and hosting information for CanJS maintainers. \n","name":"guides/contributing/releases","title":"Releases","type":"page","parent":"guides/contribute","comment":" ","pathToRoot":"../../.."}; </script> </article> <footer><p>CanJS is part of <a href="http://donejs.com" target="_blank">DoneJS</a>. Created and maintained by the core <a href="https://donejs.com/About.html#section=section_Team" target="_blank">DoneJS team</a> and <a href="http://bitovi.com" target="_blank">Bitovi</a>. <strong>Currently 3.0.0.</strong></p></footer> </div> </div> </div> <script> steal = { instantiated: { "bundles/bit-docs-site/static.css!$css" : null } }; </script> <script type='text/javascript' data-main="bit-docs-site/static" src="../../static/node_modules/steal/steal.production.js"></script> <script async defer src="https://buttons.github.io/buttons.js"></script> </body> </html>