From e591b149cc89cecabeea06549ff20f2778942fd8 Mon Sep 17 00:00:00 2001 From: Nick Colley Date: Tue, 29 May 2018 11:41:20 +0100 Subject: [PATCH 1/7] Update publishing title We no longer only publish one component --- docs/publishing.md | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/docs/publishing.md b/docs/publishing.md index 8834bd62df..8c63edb7f1 100644 --- a/docs/publishing.md +++ b/docs/publishing.md @@ -1,6 +1,4 @@ -# Publishing components - -### Publishing components manually (while in Alpha/Private beta) +# Publishing GOV.UK Frontend 1. Checkout **master** and pull latest changes. From 5365c7dd528ac2ea898cdf2d2790a94727d5aab2 Mon Sep 17 00:00:00 2001 From: Nick Colley Date: Tue, 29 May 2018 11:42:18 +0100 Subject: [PATCH 2/7] Explicitly call out the right package.json to update This can be confused with the project root package.json --- docs/publishing.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/publishing.md b/docs/publishing.md index 8c63edb7f1..159e158b04 100644 --- a/docs/publishing.md +++ b/docs/publishing.md @@ -7,7 +7,7 @@ 3. Update [`CHANGELOG.md`](../CHANGELOG.md) "Unreleased" heading with the new version number. This should be incremented based on [Semantic versioning](https://semver.org/) from the unreleased changes listed. -4. Update [`package.json`](../package/package.json) version with the new version number. +4. Update [`package/package.json`](../package/package.json) version with the new version number. This should be incremented based on [Semantic versioning](https://semver.org/) from the unreleased changes listed. 5. Save the changes. Do not commit. From deb52f1a8cb61338d05c7521fdc17b57424b1062 Mon Sep 17 00:00:00 2001 From: Nick Colley Date: Tue, 29 May 2018 11:44:09 +0100 Subject: [PATCH 3/7] Add step to ensure npm install is run before releasing --- docs/publishing.md | 34 ++++++++++++++++++---------------- 1 file changed, 18 insertions(+), 16 deletions(-) diff --git a/docs/publishing.md b/docs/publishing.md index 159e158b04..c6eacb1eb5 100644 --- a/docs/publishing.md +++ b/docs/publishing.md @@ -2,17 +2,19 @@ 1. Checkout **master** and pull latest changes. -2. Create and checkout a new branch (`release-[version-number]`). +2. Run `npm install` to ensure you have the latest dependencies installed. -3. Update [`CHANGELOG.md`](../CHANGELOG.md) "Unreleased" heading with the new version number. +3. Create and checkout a new branch (`release-[version-number]`). + +4. Update [`CHANGELOG.md`](../CHANGELOG.md) "Unreleased" heading with the new version number. This should be incremented based on [Semantic versioning](https://semver.org/) from the unreleased changes listed. -4. Update [`package/package.json`](../package/package.json) version with the new version number. +5. Update [`package/package.json`](../package/package.json) version with the new version number. This should be incremented based on [Semantic versioning](https://semver.org/) from the unreleased changes listed. -5. Save the changes. Do not commit. +6. Save the changes. Do not commit. -6. Run `npm run pre-release`. +7. Run `npm run pre-release`. This will: - copy files from `src/` to `package/` and run tests @@ -20,7 +22,7 @@ This will: - build "govuk-frontend" Sass and JavaScript files into `dist/` - commit all changes and push the branch to remote -7. (Optional) Test in [GOV.UK Design System](git@github.com:alphagov/govuk-design-system.git) +8. (Optional) Test in [GOV.UK Design System](git@github.com:alphagov/govuk-design-system.git) If you want to test your changes work correctly when used in the GOV.UK Design System you can use [npm link](https://docs.npmjs.com/cli/link) to test before publishing. @@ -35,16 +37,16 @@ This will: npm unlink ../govuk-frontend/package/ ``` -8. Create a pull request and copy the changelog text. +9. Create a pull request and copy the changelog text. When reviewing the PR, check that the version numbers have been updated and that the compiled assets use this version number. -9. Once the pull request is approved, merge to **master**. +10. Once the pull request is approved, merge to **master**. -10. Checkout **master** and pull the latest changes. +11. Checkout **master** and pull the latest changes. -11. Log into npm, using team [credentials](https://github.com/alphagov/design-system-team-credentials/tree/master/npm/govuk-patterns-and-tools). +12. Log into npm, using team [credentials](https://github.com/alphagov/design-system-team-credentials/tree/master/npm/govuk-patterns-and-tools). -12. Run `npm run release`. +13. Run `npm run release`. This will: - check that you're logged in to npm as the correct user. @@ -53,23 +55,23 @@ This will: - push the tag to remote origin - create a zip file of the `dist` directory -13. Create a release in the [Github interface](https://github.com/alphagov/govuk-frontend/releases/new) +14. Create a release in the [Github interface](https://github.com/alphagov/govuk-frontend/releases/new) - select the latest tag version - set "GOV.UK Frontend release v[version-number]" as the title - add release notes from changelog - attach the generated ZIP that is located at the root of the project - publish release -14. (Required for private beta) Grant "test" user access to any newly published package(s). +15. (Required for private beta) Grant "test" user access to any newly published package(s). ```bash npm access grant read-only govuk-frontend:test @govuk-frontend/[component-name] ``` -15. Log out from npm +16. Log out from npm ```bash npm logout ``` -16. Move Trello cards from "Next Frontend release" column to "Done". +17. Move Trello cards from "Next Frontend release" column to "Done". -17. Add Trello cards to "This Sprint" column for +18. Add Trello cards to "This Sprint" column for - Update the GOV.UK Design System to use the latest release - Update the GOV.UK Prototype Kit to use the latest release From 4be6a77d08e65f46a36bd8b6ac05faf092af60d6 Mon Sep 17 00:00:00 2001 From: Nick Colley Date: Tue, 29 May 2018 11:45:05 +0100 Subject: [PATCH 4/7] Add steps to `npm link` checking to ensure up-to-date --- docs/publishing.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/docs/publishing.md b/docs/publishing.md index c6eacb1eb5..da30a91af9 100644 --- a/docs/publishing.md +++ b/docs/publishing.md @@ -28,6 +28,8 @@ This will: ```bash cd ../govuk-design-system + git checkout master + npm install # note running `npm install` after `npm link` will destroy the link. npm link ../govuk-frontend/package/ ``` From bfac55a710722d717d2546598ac0a61c1eff92dd Mon Sep 17 00:00:00 2001 From: Nick Colley Date: Tue, 29 May 2018 11:46:10 +0100 Subject: [PATCH 5/7] Remove step to grant access, as only one package is published now --- docs/publishing.md | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/docs/publishing.md b/docs/publishing.md index da30a91af9..64231951ac 100644 --- a/docs/publishing.md +++ b/docs/publishing.md @@ -64,16 +64,12 @@ This will: - attach the generated ZIP that is located at the root of the project - publish release -15. (Required for private beta) Grant "test" user access to any newly published package(s). -```bash -npm access grant read-only govuk-frontend:test @govuk-frontend/[component-name] -``` -16. Log out from npm +15. Log out from npm ```bash npm logout ``` -17. Move Trello cards from "Next Frontend release" column to "Done". +16. Move Trello cards from "Next Frontend release" column to "Done". -18. Add Trello cards to "This Sprint" column for +17. Add Trello cards to "This Sprint" column for - Update the GOV.UK Design System to use the latest release - Update the GOV.UK Prototype Kit to use the latest release From a29afd30f6781653dca12ad7ebfb8de1155c9486 Mon Sep 17 00:00:00 2001 From: Nick Colley Date: Tue, 29 May 2018 11:49:39 +0100 Subject: [PATCH 6/7] Add emojis to CHANGELOG for consistency with releases --- CHANGELOG.md | 68 ++++++++++++++++++++++++++-------------------------- 1 file changed, 34 insertions(+), 34 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 156d079718..65cd7ed7e7 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -6,7 +6,7 @@ Note: We're not following semantic versioning yet, we are going to talk about th ## 0.0.30-alpha (Minor release) -Fixes: +πŸ”§ Fixes: - Update component readme files content ([PR #704](https://github.com/alphagov/govuk-frontend/pull/704)) @@ -14,7 +14,7 @@ Fixes: - Fix panel body element rendering with no text ([PR #707](https://github.com/alphagov/govuk-frontend/pull/707)) -New features: +πŸ†• New features: - Add override classes to set `display` property to `block`, `inline` and `inline-block` (PR [#694](https://github.com/alphagov/govuk-frontend/pull/654)) @@ -27,7 +27,7 @@ New features: - Add ability to pass explicit name value to checkbox items (PR [#719](https://github.com/alphagov/govuk-frontend/pull/719)) -Internal: +🏠 Internal: - Run tests in pre-release ([PR #706](https://github.com/alphagov/govuk-frontend/pull/706)) @@ -40,7 +40,7 @@ Internal: ## 0.0.29-alpha (Breaking release) -Breaking changes: +πŸ’₯ Breaking changes: - Restructure project to enable it to be published as a single package @@ -288,7 +288,7 @@ Breaking changes: ([PR #665](https://github.com/alphagov/govuk-frontend/pull/665)) -Fixes: +πŸ”§ Fixes: - Remove redundant font-family declaration from the button component – this will also fix an issue where the button uses New Transport when printed instead of @@ -306,7 +306,7 @@ Fixes: - Remove normalize from /dist builds (PR [#699](https://github.com/alphagov/govuk-frontend/pull/699)) -New features: +πŸ†• New features: - We're now using ES6 Modules and [rollup](https://rollupjs.org/guide/en) to distribute our JavaScript. (PR [#652](https://github.com/alphagov/govuk-frontend/pull/652)) - Checkboxes and Radios conditional reveal @@ -329,7 +329,7 @@ New features: To include global styles, you can set `$govuk-global-styles` variable to `true`. -Internal: +🏠 Internal: - Remove unused step in travis.yml file (PR [#690](https://github.com/alphagov/govuk-frontend/pull/690)) @@ -359,7 +359,7 @@ Missing files were: ## 0.0.27-alpha (Breaking release) -Breaking changes: +πŸ’₯ Breaking changes: - Removed an (undocumented) modifier `govuk-c-radio__item--inline` which made radio buttons inline, in favour of a new block-level modifier @@ -382,7 +382,7 @@ Breaking changes: (PR [#631](https://github.com/alphagov/govuk-frontend/pull/631)) - Rename captionSize table argument to captionClasses ([PR #643](https://github.com/alphagov/govuk-frontend/pull/643)) -Fixes: +πŸ”§ Fixes: - Link styles, as well as links within the back-link, breadcrumbs, button, error summary, footer and skip link components defend against the `a:link:focus` selector in GOV.UK Template, which was overriding focussed @@ -391,7 +391,7 @@ Fixes: - Fix table captions to allow heading classes (PR [#633](https://github.com/alphagov/govuk-frontend/pull/633)) -New features: +πŸ†• New features: - Add `govuk-main-wrapper--l` a variant of the main page wrapper to use when a design does not include back links, breadcrumbs or phase banners (PR [#602](https://github.com/alphagov/govuk-frontend/pull/602)) @@ -415,7 +415,7 @@ New features: Note: Our JavaScript work is ongoing. In the next release of GOV.UK Frontend both of our script will be modularised and split into common functions. This will allow you to use the polyfills in your bundler/build pipeline. For this reason, you might want to wait until the next release before adding these polyfill scripts into your project. -Internal: +🏠 Internal: - Update check script for new components and tweak docs (PR [#589](https://github.com/alphagov/govuk-frontend/pull/589)) - Listen for development server on different port for tests @@ -440,23 +440,23 @@ Internal: ## 0.0.26-alpha (Breaking release) -Breaking changes: +πŸ’₯ Breaking changes: - The error summary component now has a default bottom margin (PR [#583](https://github.com/alphagov/govuk-frontend/pull/583)) - Nest components correctly (PR [#584](https://github.com/alphagov/govuk-frontend/pull/584)) -Fixes: +πŸ”§ Fixes: - Make section break line 1px instead of 2px (PR [#585](https://github.com/alphagov/govuk-frontend/pull/585)) -New features: +πŸ†• New features: - Add footer component (PR [#569](https://github.com/alphagov/govuk-frontend/pull/569)) -Internal: +🏠 Internal: - Update pre-release step to check for new components (PR [#574](https://github.com/alphagov/govuk-frontend/pull/574)) @@ -467,19 +467,19 @@ Internal: ## 0.0.25-alpha (Breaking release) -Breaking changes: +πŸ’₯ Breaking changes: - The colour variable `$govuk-fuschia` has been replaced with a new variable with the correct spelling (`$govuk-fuchsia`) – thanks to [@charlesrt](https://github.com/charlesrt) for reporting. (PR [#571](https://github.com/alphagov/govuk-frontend/pull/571)) -New features: +πŸ†• New features: - The input macro now accepts a `type` which allows you to override the default type="text" (PR [#568](https://github.com/alphagov/govuk-frontend/pull/568)) -Fixes: +πŸ”§ Fixes: - The transparent outline has been removed from the button, as it already has a transparent border which is visible when overriding colours in the browser (PR [#552](https://github.com/alphagov/govuk-frontend/pull/552)) @@ -493,7 +493,7 @@ Fixes: match the previous implementation in Elements (PR [#568](https://github.com/alphagov/govuk-frontend/pull/568)) -Internal: +🏠 Internal: - The logic to determine button text colour automatically has been removed and replaced with a new variable $govuk-button-text-colour (PR [#552](https://github.com/alphagov/govuk-frontend/pull/552)) @@ -509,7 +509,7 @@ Internal: ## 0.0.24-alpha (Breaking release) -Breaking changes: +πŸ’₯ Breaking changes: - Namespace existing mixins and functions ( PR [#557](https://github.com/alphagov/govuk-frontend/pull/557)) - The class `.govuk-section-break__visible` has been renamed to @@ -518,14 +518,14 @@ Breaking changes: - Simplify `src/` folder structure, remove tree and string manipulations from gulp tasks (PR [#545](https://github.com/alphagov/govuk-frontend/pull/545)) -New features: +πŸ†• New features: - A new variable `$govuk-input-border-colour` has been introduced to define the border colour for inputs. The Input, Select and Textarea components have been updated to use it. (PR [#551](https://github.com/alphagov/govuk-frontend/pull/551)) -Fixes: +πŸ”§ Fixes: - Removes media query display on body from compiled CSS (PR [#560](https://github.com/alphagov/govuk-frontend/pull/560)) @@ -535,7 +535,7 @@ Fixes: borders, rather than relying on inheriting it (PR [#551](https://github.com/alphagov/govuk-frontend/pull/551)) -Internal: +🏠 Internal: - The 'prose scope' has been updated to extend only placeholder classes. The corresponding classes the prose scope extends have been updated to provide a @@ -552,7 +552,7 @@ Internal: ## 0.0.23-alpha (Breaking release) -Breaking changes: +πŸ’₯ Breaking changes: - Remove Cookie-banner and Previous-next components (PR [#488](https://github.com/alphagov/govuk-frontend/pull/488), PR [#523](https://github.com/alphagov/govuk-frontend/pull/523)) @@ -578,7 +578,7 @@ Breaking changes: avoid tying it to a particular colour. (PR [#525](https://github.com/alphagov/govuk-frontend/pull/525)) -New features: +πŸ†• New features: - Button hover colour now has a semantic Sass name: $govuk-button-hover-colour (PR [#406](https://github.com/alphagov/govuk-frontend/pull/406)) @@ -592,7 +592,7 @@ New features: `
`, adds margin (xl, l and m). There is also an option to make the `
` border visible or invisible. (PR [#483](https://github.com/alphagov/govuk-frontend/pull/483)) -Fixes: +πŸ”§ Fixes: - Remove double margin from Date input component (PR [#451](https://github.com/alphagov/govuk-frontend/pull/451)) @@ -608,7 +608,7 @@ Fixes: border for errors and a bottom margin. Add example of form errors to preview app (PR [#591](https://github.com/alphagov/govuk-frontend/pull/591)) -Internal: +🏠 Internal: - Replace Mocha/Chai with Jest, re-enable task tests, add back-link component. Special thanks to [@htmlandbacon](https://github.com/htmlandbacon) and [@tyom](https://github.com/tyom) for sharing their approaches. @@ -640,7 +640,7 @@ Internal: ## 0.0.22-alpha (Breaking release) -Breaking changes: +πŸ’₯ Breaking changes: - The link styles in the core layer no longer style `a` elements directly, but instead provide a `govuk-link` class which you will need to apply to links @@ -651,7 +651,7 @@ Breaking changes: - Rename `legal-text` argument accepted by `legal-text` component to `text` (PR [#431](https://github.com/alphagov/govuk-frontend/pull/432)) - Rename `legal-text` component to `warning-text` (PR [#431](https://github.com/alphagov/govuk-frontend/pull/432)) -New features: +πŸ†• New features: - The prose scope has been extended to style links, which means links within the scope do not need the `govuk-link` class applied. @@ -660,7 +660,7 @@ New features: class (`govuk-link--muted`). (PR [#427](https://github.com/alphagov/govuk-frontend/pull/427)) -Fixes: +πŸ”§ Fixes: - The error summary component allows users to pass HTML for an entry in the list again. (PR [#428](https://github.com/alphagov/govuk-frontend/pull/428)) @@ -675,7 +675,7 @@ Fixes: (PR [#427](https://github.com/alphagov/govuk-frontend/pull/427)) - Adjust `warning-text` icon by 1px for New Transport -Internal: +🏠 Internal: - Add prose scope example (PR [#429](https://github.com/alphagov/govuk-frontend/pull/429)) - Links within the review app and the examples have been updated to use the @@ -688,18 +688,18 @@ Internal: ## 0.0.21-alpha (Breaking release) Skipped 0.0.20-alpha due to difficulties with publishing. -Breaking changes: +πŸ’₯ Breaking changes: - Rename β€˜govuk-body-lede’ to β€˜govuk-body-lead’. (PR [#405](https://github.com/alphagov/govuk-frontend/pull/405)) - Pluralise radio component (PR [#388](https://github.com/alphagov/govuk-frontend/pull/388)) - Pluralise checkbox component (PR [#384](https://github.com/alphagov/govuk-frontend/pull/384)) -New features: +πŸ†• New features: - Add `width` classes, which were based on `form-control` classes that were specific to form control in Elements. (PR [#413](https://github.com/alphagov/govuk-frontend/pull/413)) -Fixes: +πŸ”§ Fixes: - Make buttons 40px high including box shadow (PR [#416](https://github.com/alphagov/govuk-frontend/pull/416)) - Fix focus outline style in Chrome and Safari (PR [#414](https://github.com/alphagov/govuk-frontend/pull/414)) From 7326eebd176ec6392f62c2f2e0ba2c358a0f0f1a Mon Sep 17 00:00:00 2001 From: Nick Colley Date: Tue, 29 May 2018 13:06:24 +0100 Subject: [PATCH 7/7] Update CHANGELOG --- CHANGELOG.md | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 65cd7ed7e7..d765b9070b 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,6 +4,11 @@ Note: We're not following semantic versioning yet, we are going to talk about th ## Unreleased +🏠 Internal: + +- Improve release steps, based on doing a release + ([PR #725](https://github.com/alphagov/govuk-frontend/pull/725)) + ## 0.0.30-alpha (Minor release) πŸ”§ Fixes: