From 31b6580a66e10ae90ccd5c54d2db845b16a8f871 Mon Sep 17 00:00:00 2001 From: Rich Trott Date: Wed, 23 Dec 2015 11:32:25 -0800 Subject: [PATCH 01/15] tools: implement no-unused-vars for eslint MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit PR-URL: https://github.com/nodejs/node/pull/4536 Reviewed-By: Rod Vagg Reviewed-By: Michaël Zasso Reviewed-By: Colin Ihrig --- .eslintrc | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.eslintrc b/.eslintrc index bf3fc3378f2d92..33a7919d88c9ef 100644 --- a/.eslintrc +++ b/.eslintrc @@ -84,6 +84,8 @@ rules: # list: https://github.com/eslint/eslint/tree/master/docs/rules#variables ## disallow use of undefined variables (globals) no-undef: 2 + ## disallow declaration of variables that are not used in the code + no-unused-vars: [2, {"args": "none"}] # Custom rules in tools/eslint-rules require-buffer: 2 From 54e4c09ffcae82b46bcff68bff2ef7f9c62d30ee Mon Sep 17 00:00:00 2001 From: Richard Sun Date: Tue, 5 Jan 2016 03:12:56 -0800 Subject: [PATCH 02/15] doc: fix numbering in stream.markdown PR-URL: https://github.com/nodejs/node/pull/4538 Reviewed-By: Colin Ihrig --- doc/api/stream.markdown | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/doc/api/stream.markdown b/doc/api/stream.markdown index 9ab35254bad21b..76d96233ac4bde 100644 --- a/doc/api/stream.markdown +++ b/doc/api/stream.markdown @@ -723,7 +723,7 @@ To implement any sort of stream, the pattern is the same: [`util.inherits`][] method is particularly helpful for this.) 2. Call the appropriate parent class constructor in your constructor, to be sure that the internal mechanisms are set up properly. -2. Implement one or more specific methods, as detailed below. +3. Implement one or more specific methods, as detailed below. The class to extend and the method(s) to implement depend on the sort of stream class you are writing: From 5d6e1c2fce13e45b8d7db80f6770bd003bf8f8d0 Mon Sep 17 00:00:00 2001 From: cjihrig Date: Tue, 5 Jan 2016 12:52:20 -0500 Subject: [PATCH 03/15] doc: bring releases.md up to date Refs: https://github.com/nodejs/node/issues/3254 PR-URL: https://github.com/nodejs/node/pull/4540 Reviewed-By: James M Snell --- doc/releases.md | 166 +++++++++++++++++++++++++++++++----------------- 1 file changed, 107 insertions(+), 59 deletions(-) diff --git a/doc/releases.md b/doc/releases.md index 57e95c266f4ff6..53aa4d53fb9157 100644 --- a/doc/releases.md +++ b/doc/releases.md @@ -50,19 +50,42 @@ Notes: - Dates listed below as _"YYYY-MM-DD"_ should be the date of the release **as UTC**. Use `date -u +'%Y-%m-%d'` to find out what this is. - Version strings are listed below as _"vx.y.z"_. Substitute for the release version. -### 1. Ensure that HEAD Is Stable +### 1. Cherry-picking from `master` and other branches -Run a **[node-test-pull-request](https://ci.nodejs.org/job/node-test-pull-request/)** test run to ensure that the build is stable and the HEAD commit is ready for release. +Create a new branch named _"vx.y.z-proposal"_, or something similar. Using `git cherry-pick`, bring the appropriate commits into your new branch. To determine the relevant commits, use [`branch-diff`](https://github.com/rvagg/branch-diff) and [`changelog-maker`](https://github.com/rvagg/changelog-maker/) (both are available on npm and should be installed globally). These tools depend on our commit metadata, as well as the `semver-minor` and `semver-major` GitHub labels. One drawback is that when the `PR-URL` metadata is accidentally omitted from a commit, the commit will show up because it's unsure if it's a duplicate or not. -### 2. Produce a Nightly Build _(optional)_ +Carefully review the list of commits looking for errors (incorrect `PR-URL`, incorrect semver, etc.). Commits labeled as semver minor or semver major should only be cherry-picked when appropriate for the type of release being made. Previous release commits and version bumps do not need to be cherry-picked. -If there is a reason to produce a test release for the purpose of having others try out installers or specifics of builds, produce a nightly build using **[iojs+release](https://ci.nodejs.org/job/iojs+release/)** and wait for it to drop in . Follow the directions and enter a proper length commit SHA, enter a date string, and select "nightly" for "disttype". +### 2. Update `src/node_version.h` -This is particularly recommended if there has been recent work relating to the OS X or Windows installers as they are not tested in any way by CI. +Set the version for the proposed release using the following macros, which are already defined in `src/node_version.h`: -### 3. Update the _CHANGELOG.md_ +``` +#define NODE_MAJOR_VERSION x +#define NODE_MINOR_VERSION y +#define NODE_PATCH_VERSION z +``` -Collect a formatted list of commits since the last release. Use [changelog-maker](https://github.com/rvagg/changelog-maker) (available from npm: `npm install changelog-maker -g`) to do this. +Set the `NODE_VERSION_IS_RELEASE` macro value to `1`. This causes the build to be produced with a version string that does not have a trailing pre-release tag: + +``` +#define NODE_VERSION_IS_RELEASE 1 +``` + +**Also consider whether to bump `NODE_MODULE_VERSION`**: + +This macro is used to signal an ABI version for native addons. It currently has two common uses in the community: + +* Determining what API to work against for compiling native addons, e.g. [NAN](https://github.com/rvagg/nan) uses it to form a compatibility-layer for much of what it wraps. +* Determining the ABI for downloading pre-built binaries of native addons, e.g. [node-pre-gyp](https://github.com/mapbox/node-pre-gyp) uses this value as exposed via `process.versions.modules` to help determine the appropriate binary to download at install-time. + +The general rule is to bump this version when there are _breaking ABI_ changes and also if there are non-trivial API changes. The rules are not yet strictly defined, so if in doubt, please confer with someone that will have a more informed perspective, such as a member of the NAN team. + +**Note** that it is current TSC policy to bump major version when ABI changes. If you see a need to bump `NODE_MODULE_VERSION` then you should consult the TSC. Commits may need to be reverted or a major version bump may need to happen. + +### 3. Update `CHANGELOG.md` + +Collect a formatted list of commits since the last release. Use [`changelog-maker`](https://github.com/rvagg/changelog-maker) to do this. ``` $ changelog-maker --group @@ -74,10 +97,10 @@ Note that changelog-maker counts commits since the last tag and if the last tag $ changelog-maker --group --start-ref v2.3.1 ``` -The _CHANGELOG.md_ entry should take the following form: +The `CHANGELOG.md` entry should take the following form: ``` -## YYYY-MM-DD, Version x.y.z, @releaser +## YYYY-MM-DD, Version x.y.z (Release Type), @releaser ### Notable changes @@ -95,55 +118,46 @@ See https://github.com/nodejs/node/labels/confirmed-bug for complete and current ### Commits -* Include the full list of commits since the last release here +* Include the full list of commits since the last release here. Do not include "Working on X.Y.Z+1" commits. ``` -### 4. Update _src/node_version.h_ +The release type should be either Stable, LTS, or Maintenance, depending on the type of release being produced. -The following macros should already be set for the release since they will have been updated directly following the last release. They shouldn't require changing: +### 4. Create Release Commit -``` -#define NODE_MAJOR_VERSION x -#define NODE_MINOR_VERSION y -#define NODE_PATCH_VERSION z -``` - -However, the `NODE_VERSION_IS_RELEASE` macro needs to be set to `1` for the build to be produced with a version string that does not have a trailing pre-release tag: +The `CHANGELOG.md` and `src/node_version.h` changes should be the final commit that will be tagged for the release. When committing these to git, use the following message format: ``` -#define NODE_VERSION_IS_RELEASE 1 -``` +YYYY-MM-DD, Version x.y.z (Release Type) -**Also consider whether to bump `NODE_MODULE_VERSION`**: +Notable changes: -This macro is used to signal an ABI version for native addons. It currently has two common uses in the community: +* Copy the notable changes list here, reformatted for plain-text +``` -* Determining what API to work against for compiling native addons, e.g. [NAN](https://github.com/rvagg/nan) uses it to form a compatibility-layer for much of what it wraps. -* Determining the ABI for downloading pre-built binaries of native addons, e.g. [node-pre-gyp](https://github.com/mapbox/node-pre-gyp) uses this value as exposed via `process.versions.modules` to help determine the appropriate binary to download at install-time. +### 5. Propose Release on GitHub -The general rule is to bump this version when there are _breaking ABI_ changes and also if there are non-trivial API changes. The rules are not yet strictly defined, so if in doubt, please confer with someone that will have a more informed perspective, such as a member of the NAN team. +Push the release branch to `nodejs/node`, not to your own fork. This allows release branches to more easily be passed between members of the release team if necessary. -**Note** that it is current TSC policy to bump major version when ABI changes. If you see a need to bump `NODE_MODULE_VERSION` then you should consult the TSC. Commits may need to be reverted or a major version bump may need to happen. +Create a pull request targeting the correct release line. For example, a v5.3.0-proposal PR should target v5.x, not master. Paste the CHANGELOG modifications into the body of the PR so that collaborators can see what is changing. These PRs should be left open for at least 24 hours, and can be updated as new commits land. -### 5. Create Release Commit +If you need any additional information about any of the commits, this PR is a good place to @-mention the relevant contributors. -The _CHANGELOG.md_ and _src/node_version.h_ changes should be the final commit that will be tagged for the release. +This is also a good time to update the release commit to include `PR-URL` metadata. -When committing these to git, use the following message format: +### 6. Ensure that the Release Branch is Stable -``` -YYYY-MM-DD node.js vx.y.z Release +Run a **[node-test-pull-request](https://ci.nodejs.org/job/node-test-pull-request/)** test run to ensure that the build is stable and the HEAD commit is ready for release. -Notable changes: +Perform some smoke-testing. We have [citgm](https://github.com/nodejs/citgm) for this. You can also manually test important modules from the ecosystem. Remember that node-gyp and npm both take a `--nodedir` flag to point to your local repository so that you can test unreleased versions without needing node-gyp to download headers for you. -* Copy the notable changes list here, reformatted for plain-text -``` +### 7. Produce a Nightly Build _(optional)_ -### 6. Push to GitHub +If there is a reason to produce a test release for the purpose of having others try out installers or specifics of builds, produce a nightly build using **[iojs+release](https://ci.nodejs.org/job/iojs+release/)** and wait for it to drop in . Follow the directions and enter a proper length commit SHA, enter a date string, and select "nightly" for "disttype". -Note that it is not essential that the release builds be created from the Node.js repository. They may be created from your own fork if you desire. It is preferable, but not essential, that the commits remain the same between that used to build and the tagged commit in the Node.js repository. +This is particularly recommended if there has been recent work relating to the OS X or Windows installers as they are not tested in any way by CI. -### 7. Produce Release Builds +### 8. Produce Release Builds Use **[iojs+release](https://ci.nodejs.org/job/iojs+release/)** to produce release artifacts. Enter the commit that you want to build from and select "release" for "disttype". @@ -153,44 +167,62 @@ All release slaves should achieve "SUCCESS" (and be green, not red). A release w You can rebuild the release as many times as you need prior to promoting them if you encounter problems. -Note that you do not have to wait for the ARM builds if they take longer than the others. It is only necessary to have the main Linux (x64 and x86), OS X .pkg and .tar.gz, Windows (x64 and x86) .msi and .exe, source, headers and docs (both produced currently by an OS X slave). That is, the slaves with "arm" in their name don't need to have finished to progress to the next step. However, **if you promote builds _before_ ARM builds have finished, you must repeat the promotion step for the ARM builds when they are ready**. +If you have an error on Windows and need to start again, be aware that you'll get immediate failure unless you wait up to 2 minutes for the linker to stop from previous jobs. i.e. if a build fails after having started compiling, that slave will still have a linker process that's running for another couple of minutes which will prevent Jenkins from clearing the workspace to start a new one. This isn't a big deal, it's just a hassle because it'll result in another failed build if you start again! + +ARMv7 takes the longest to compile. Unfortunately ccache isn't as effective on release builds, I think it's because of the additional macro settings that go in to a release build that nullify previous builds. Also most of the release build machines are separate to the test build machines so they don't get any benefit from ongoing compiles between releases. You can expect 1.5 hours for the ARMv7 builder to complete and you should normally wait for this to finish. It is possible to rush a release out if you want and add additional builds later but we normally provide ARMv7 from initial promotion. -### 8. Tag and Sign the Release Commit +You do not have to wait for the ARMv6 / Raspberry PI builds if they take longer than the others. It is only necessary to have the main Linux (x64 and x86), OS X .pkg and .tar.gz, Windows (x64 and x86) .msi and .exe, source, headers and docs (both produced currently by an OS X slave). **If you promote builds _before_ ARM builds have finished, you must repeat the promotion step for the ARM builds when they are ready**. -Tag the release as vx.y.z and sign **using the same GPG key that will be used to sign SHASUMS256.txt**. +### 9. Test the Build + +Jenkins collects the artifacts from the builds, allowing you to download and install the new build. Make sure that the build appears correct. Check the version numbers, and perform some basic checks to confirm that all is well with the build before moving forward. + +### 10. Tag and Sign the Release Commit + +Once you have produced builds that you're happy with, create a new tag. By waiting until this stage to create tags, you can discard a proposed release if something goes wrong or additional commits are required. Once you have created a tag and pushed it to GitHub, you ***should not*** delete and re-tag. If you make a mistake after tagging then you'll have to version-bump and start again and count that tag/version as lost. + +Tag summaries have a predictable format, look at a recent tag to see, `git tag -v v5.3.0`. The message should look something like `2015-12-16 Node.js v5.3.0 (Stable) Release`. + +Create a tag using the following command: ``` -$ git tag -sm 'YYYY-MM-DD node.js vz.y.x Release' +$ git tag -sm 'YYYY-MM-DD Node.js vx.y.z (Release Type) Release' ``` -Push the tag to GitHub. +The tag **must** be signed using the GPG key that's listed for you on the project README. + +Push the tag to the repo before you promote the builds. If you haven't pushed your tag first, then build promotion won't work properly. Push the tag using the following command: ``` -$ git push origin +$ git push ``` -### 9. Set Up For the Next Release +### 11. Set Up For the Next Release -Edit _src/node_version.h_ again and: +On release proposal branch, edit `src/node_version.h` again and: * Increment `NODE_PATCH_VERSION` by one * Change `NODE_VERSION_IS_RELEASE` back to `0` -Commit this change with: +Commit this change with the following commit message format: ``` -$ git commit -am 'Working on vx.y.z' # where 'z' is the incremented patch number +Working on vx.y.z # where 'z' is the incremented patch number + +PR-URL: ``` This sets up the branch so that nightly builds are produced with the next version number _and_ a pre-release tag. -### 10. Promote and Sign the Release Builds +Merge your release branch into the stable branch that you are releasing from (not master). -**It is important that the same individual who signed the release tag be the one to promote the builds as the SHASUMS256.txt file needs to be signed with the same GPG key!** +Cherry-pick the release commit to `master`. After cherry-picking, edit `src/node_version.h` to ensure the version macros contain whatever values were previously on `master`. `NODE_VERSION_IS_RELEASE` should be `0`. -When you are confident that the build slaves have properly produced usable artifacts and uploaded them to the web server, you can promote them to release status. This is done by interacting with the web server via the _dist_ user. +### 12. Promote and Sign the Release Builds -The _tools/release.sh_ script should be used to promote and sign the build. When run, it will perform the following actions: +**It is important that the same individual who signed the release tag be the one to promote the builds as the SHASUMS256.txt file needs to be signed with the same GPG key!** + +Use `tools/release.sh` to promote and sign the build. When run, it will perform the following actions: **a.** Select a GPG key from your private keys. It will use a command similar to: `gpg --list-secret-keys` to list your keys. If you don't have any keys, it will bail. (Why are you releasing? Your tag should be signed!) If you have only one key, it will use that. If you have more than one key it will ask you to select one from the list. Be sure to use the same key that you signed your git tag with. @@ -204,20 +236,36 @@ The _tools/release.sh_ script should be used to promote and sign the build. When **f.** Output an ASCII armored version of your public GPG key using a command similar to: `gpg --default-key YOURKEY --armor --export --output /path/to/SHASUMS256.txt.gpg`. This does not require your password and is mainly a convenience for users, although not the recommended way to get a copy of your key. -**g.** Upload the SHASUMS256.txt\* files back to the server into the release directory. +**g.** Upload the SHASUMS256.txt files back to the server into the release directory. -If you didn't wait for ARM builds in the previous step before promoting the release, you should re-run _tools/release.sh_ after the ARM builds have finished. That will move the ARM artifacts into the correct location. You will be prompted to re-sign SHASUMS256.txt. +If you didn't wait for ARM builds in the previous step before promoting the release, you should re-run `tools/release.sh` after the ARM builds have finished. That will move the ARM artifacts into the correct location. You will be prompted to re-sign SHASUMS256.txt. -### 11. Check the Release +### 13. Check the Release Your release should be available at and . Check that the appropriate files are in place. You may want to check that the binaries are working as appropriate and have the right internal version strings. Check that the API docs are available at . Check that the release catalog files are correct at and . -### 12. Announce +### 14. Create a Blog Post + +There is an automatic build that is kicked off when you promote new builds, so within a few minutes nodejs.org will be listing your new version as the latest release. However, the blog post is not yet fully automatic. + +Create a new blog post by running the [nodejs.org release-post.js script](https://github.com/nodejs/nodejs.org/blob/master/scripts/release-post.js). This script will use the promoted builds and changelog to generate the post. Run `npm serve` to preview the post locally before pushing to the [nodejs.org](https://github.com/nodejs/nodejs.org) repo. + +* You can add a short blurb just under the main heading if you want to say something important, otherwise the text should be publication ready. +* The links to the download files won't be complete unless you waited for the ARMv6 builds. Any downloads that are missing will have `*Coming soon*` next to them. It's your responsibility to manually update these later when you have the outstanding builds. +* The SHASUMS256.txt.asc content is at the bottom of the post. When you update the list of tarballs you'll need to copy/paste the new contents of this file to reflect those changes. +* Always use pull-requests on the nodejs.org repo. Be respectful of that working group, but you shouldn't have to wait for PR sign-off. Opening a PR and merging it immediately _should_ be fine. +* Changes to `master` on the nodejs.org repo will trigger a new build of nodejs.org so your changes should appear in a few minutes after pushing. + +### 15. Announce + +The nodejs.org website will automatically rebuild and include the new version. You simply need to announce the build, preferably via Twitter with a message such as: + +> v5.3.0 of @nodejs is out @ https://nodejs.org/dist/latest/ changelog @ https://github.com/nodejs/node/blob/master/CHANGELOG.md#2015-12-16-version-530-stable-cjihrig … something here about notable changes -The nodejs.org website will automatically rebuild and include the new version. You simply need to announce the build, preferably via twitter with a message such as: +### 16. Cleanup -> v2.3.2 of @official_iojs is out @ https://nodejs.org/dist/latest/ changelog @ https://github.com/nodejs/node/blob/master/CHANGELOG.md#2015-07-01-version-232-rvagg … something here about notable changes +Close your release proposal PR and remove the proposal branch. -### 13. Celebrate +### 17. Celebrate _In whatever form you do this..._ From 8cb88408e4d0cfd24504b955ef7c78efd12febc1 Mon Sep 17 00:00:00 2001 From: Brian White Date: Tue, 5 Jan 2016 23:46:05 -0500 Subject: [PATCH 04/15] doc: add missing backtick for readline PR-URL: https://github.com/nodejs/node/pull/4549 Reviewed-By: Colin Ihrig --- doc/api/readline.markdown | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/doc/api/readline.markdown b/doc/api/readline.markdown index 5d98f501f68c65..05a52cd25cc390 100644 --- a/doc/api/readline.markdown +++ b/doc/api/readline.markdown @@ -247,7 +247,7 @@ Clears the screen from the current position of the cursor down. ## readline.createInterface(options) -Creates a readline `Interface` instance. Accepts an `options Object that takes +Creates a readline `Interface` instance. Accepts an `options` Object that takes the following values: - `input` - the readable stream to listen to (Required). From 719b145ae92b6b227d003b1ba7d6a1c80bb55b60 Mon Sep 17 00:00:00 2001 From: Myles Borins Date: Thu, 7 Jan 2016 16:38:15 -0800 Subject: [PATCH 05/15] doc: add Myles Borins to Release Team Adds Myles Borins and his public key to the README PR-URL: https://github.com/nodejs/node/pull/4578 Reviewed-By: Colin Ihrig Reviewed-By: Evan Lucas --- README.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/README.md b/README.md index 3df9b93dd39d66..8f2ada16767835 100644 --- a/README.md +++ b/README.md @@ -444,6 +444,7 @@ Releases of Node.js and io.js will be signed with one of the following GPG keys: * **Jeremiah Senkpiel** <fishrock@keybase.io> `FD3A5288F042B6850C66B31F09FE44734EB7990E` * **James M Snell** <jasnell@keybase.io> `71DCFD284A79C3B38668286BC97EC7A07EDE3FC1` * **Rod Vagg** <rod@vagg.org> `DD8F2338BAE7501E3DD5AC78C273792F7D83545D` +* **Myles Borins** <thealphanerd@keybase.io> `792807C150954BF0299B289A38CE40DEEE898E15` The full set of trusted release keys can be imported by running: @@ -454,6 +455,7 @@ gpg --keyserver pool.sks-keyservers.net --recv-keys 0034A06D9D9B0064CE8ADF6BF174 gpg --keyserver pool.sks-keyservers.net --recv-keys FD3A5288F042B6850C66B31F09FE44734EB7990E gpg --keyserver pool.sks-keyservers.net --recv-keys 71DCFD284A79C3B38668286BC97EC7A07EDE3FC1 gpg --keyserver pool.sks-keyservers.net --recv-keys DD8F2338BAE7501E3DD5AC78C273792F7D83545D +gpg --keyserver pool.sks-keyservers.net --recv-keys 792807C150954BF0299B289A38CE40DEEE898E15 ``` See the section above on [Verifying Binaries](#verifying-binaries) for From a28e51a96cd6c1422fe67ee1f013381533b39997 Mon Sep 17 00:00:00 2001 From: Evan Lucas Date: Thu, 7 Jan 2016 18:41:16 -0600 Subject: [PATCH 06/15] doc: add Evan Lucas to Release Team Adds Evan Lucas and his public key to the README for releases PR-URL: https://github.com/nodejs/node/pull/4579 Reviewed-By: Colin Ihrig Reviewed-By: Myles Borins --- README.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/README.md b/README.md index 8f2ada16767835..c4bba4ed380d2e 100644 --- a/README.md +++ b/README.md @@ -445,6 +445,7 @@ Releases of Node.js and io.js will be signed with one of the following GPG keys: * **James M Snell** <jasnell@keybase.io> `71DCFD284A79C3B38668286BC97EC7A07EDE3FC1` * **Rod Vagg** <rod@vagg.org> `DD8F2338BAE7501E3DD5AC78C273792F7D83545D` * **Myles Borins** <thealphanerd@keybase.io> `792807C150954BF0299B289A38CE40DEEE898E15` +* **Evan Lucas** <evanlucas@me.com> `B9AE9905FFD7803F25714661B63B535A4C206CA9` The full set of trusted release keys can be imported by running: @@ -456,6 +457,7 @@ gpg --keyserver pool.sks-keyservers.net --recv-keys FD3A5288F042B6850C66B31F09FE gpg --keyserver pool.sks-keyservers.net --recv-keys 71DCFD284A79C3B38668286BC97EC7A07EDE3FC1 gpg --keyserver pool.sks-keyservers.net --recv-keys DD8F2338BAE7501E3DD5AC78C273792F7D83545D gpg --keyserver pool.sks-keyservers.net --recv-keys 792807C150954BF0299B289A38CE40DEEE898E15 +gpg --keyserver pool.sks-keyservers.net --recv-keys B9AE9905FFD7803F25714661B63B535A4C206CA9 ``` See the section above on [Verifying Binaries](#verifying-binaries) for From 5143719c39cdbf4c02c5f0962e6a9d0ad327bddc Mon Sep 17 00:00:00 2001 From: Minwoo Jung Date: Fri, 8 Jan 2016 21:13:33 +0900 Subject: [PATCH 07/15] doc: fix description about the latest-codename fix description about the latest LTS release download page to make it clear PR-URL: https://github.com/nodejs/node/pull/4583 Reviewed-By: Rod Vagg Reviewed-By: Colin Ihrig Reviewed-By: James M Snell --- README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index c4bba4ed380d2e..0de5a9e75a7562 100644 --- a/README.md +++ b/README.md @@ -54,8 +54,8 @@ Binaries, installers, and source tarballs are available at , listed under their version strings. The [latest](https://nodejs.org/download/release/latest/) directory is an alias for the latest Stable release. The latest LTS release from an LTS -line is available in the form: latest-lts-_codename_. For example: - +line is available in the form: latest-_codename_. For example: + **Nightly** builds are available at , listed under their version From 367a13ddb26d4d3d2faa9289d429303786f1980e Mon Sep 17 00:00:00 2001 From: Sequoia McDowell Date: Fri, 8 Jan 2016 13:22:23 -0500 Subject: [PATCH 08/15] doc: label http.IncomingMessage as a Class `Server`, `ServerResponse` etc. were marked as classes, this one class was overlooked. PR-URL: https://github.com/nodejs/node/pull/4589 Fixes: https://github.com/nodejs/node/issues/4576 Reviewed-By: James M Snell Reviewed-By: Colin Ihrig Reviewed-By: Roman Reiss --- doc/api/http.markdown | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/doc/api/http.markdown b/doc/api/http.markdown index f62b248f63d5fe..5540dc6c1d4675 100644 --- a/doc/api/http.markdown +++ b/doc/api/http.markdown @@ -781,7 +781,7 @@ should be used to determine the number of bytes in a given encoding. And Node.js does not check whether Content-Length and the length of the body which has been transmitted are equal or not. -## http.IncomingMessage +## Class: http.IncomingMessage An `IncomingMessage` object is created by [`http.Server`][] or [`http.ClientRequest`][] and passed as the first argument to the `'request'` From 80ad9520dc9d44d5e9c6a9f20fc731d3cdb43ed7 Mon Sep 17 00:00:00 2001 From: Sequoia McDowell Date: Fri, 8 Jan 2016 13:27:44 -0500 Subject: [PATCH 09/15] doc: document http's server.listen return value The server method returns `self` in order to allow chaining. PR-URL: https://github.com/nodejs/node/pull/4590 Fixes: https://github.com/nodejs/node/issues/4571 Reviewed-By: James M Snell Reviewed-By: Roman Reiss --- doc/api/http.markdown | 2 ++ 1 file changed, 2 insertions(+) diff --git a/doc/api/http.markdown b/doc/api/http.markdown index 5540dc6c1d4675..3904dd29d4d485 100644 --- a/doc/api/http.markdown +++ b/doc/api/http.markdown @@ -506,6 +506,8 @@ Listening on a file descriptor is not supported on Windows. This function is asynchronous. The last parameter `callback` will be added as a listener for the `'listening'` event. See also [`net.Server.listen()`][]. +Returns `server`. + ### server.listen(path[, callback]) Start a UNIX socket server listening for connections on the given `path`. From d9768a4c0fb4789f5f2e5c7ed8bfe884898c4aa5 Mon Sep 17 00:00:00 2001 From: Robert Jefe Lindstaedt Date: Sun, 10 Jan 2016 17:18:49 +0100 Subject: [PATCH 10/15] doc: adds usage of readline line-by-line parsing In order to make developers aware of node-core built-in functionality, which might replace module APIs, we should add an example of readline`s interface usage. SEO will eventually aid this goal, since it is well searched on Q&A sites. PR-URL: https://github.com/nodejs/node/pull/4609 Reviewed-By: Roman Reiss Reviewed-By: James M Snell > --- doc/api/readline.markdown | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/doc/api/readline.markdown b/doc/api/readline.markdown index 05a52cd25cc390..a83b492b0b5621 100644 --- a/doc/api/readline.markdown +++ b/doc/api/readline.markdown @@ -232,6 +232,22 @@ line interface: process.exit(0); }); +## Example: Read File Stream Line-by-Line + +A common case for `readline`'s `input` option is to pass a filesystem readable +stream to it. This is how one could craft line-by-line parsing of a file: + + const readline = require('readline'); + const fs = require('fs'); + + const rl = readline.createInterface({ + input: fs.createReadStream('sample.txt') + }); + + rl.on('line', function (line) { + console.log('Line from file:', line); + }); + ## readline.clearLine(stream, dir) Clears current line of given TTY stream in a specified direction. From 47e83957560aef9688982e17c9c82896f29b526d Mon Sep 17 00:00:00 2001 From: Roman Reiss Date: Mon, 11 Jan 2016 16:27:03 +0100 Subject: [PATCH 11/15] doc: update stylesheet to match frontpage - Changed colors to match frontpage as close as possible. - Links are slightly more horizontally padded as compared before to accomodate for the hover effect. - Slightly reduced the scroll indication height on the TOC. - The main content is now offset using margin instead of the previous border hack. - remove empty footer that was rendering a dark bar on the bottom of each page without any content. PR-URL: https://github.com/nodejs/node/pull/4621 Reviewed-By: Jeremiah Senkpiel Reviewed-By: James M Snell Reviewed-By: Brian White --- doc/api_assets/style.css | 68 ++++++++++++++++++++++------------------ doc/template.html | 3 -- 2 files changed, 38 insertions(+), 33 deletions(-) diff --git a/doc/api_assets/style.css b/doc/api_assets/style.css index 6f26c3a0c71075..4c8d64ab5579c3 100644 --- a/doc/api_assets/style.css +++ b/doc/api_assets/style.css @@ -11,26 +11,28 @@ body { font-size: 62.5%; margin: 0; padding: 0; - color: #3a3a3a; - background: #fcfefa; + color: #333; + background: #fff; } #content { font-size: 1.8em; } -a { - color: #FE5210; +a, +a:link, +a:active { + color: #80bd01; text-decoration: none; -} - -a:visited { - color: #FE7110; + border-radius: 2px; + padding: .1em .2em; + margin: -.1em 0; } a:hover, a:focus { - color: #FFA158; + color: #fff; + background-color: #80bd01; } strong { @@ -170,7 +172,6 @@ dd + dt.pre { } h1, h2, h3, h4, h5, h6 { - color: #301004; text-rendering: optimizeLegibility; font-weight: 700; position: relative; @@ -280,7 +281,7 @@ code.pre { } #intro a { - color: #333; + color: #ddd; font-size: 1.25em; font-weight: bold; } @@ -296,7 +297,6 @@ hr { } #toc h2 { - color: #C73E09; margin-top: 0; font-size: 1.0em; line-height: 0; @@ -339,12 +339,14 @@ p code, li code { font-size: 0.9em; color: #040404; - background-color: #f2f5f0; - padding: 0.2em 0.4em; + background-color: #f0f0f0; + padding: .1em .2em; + border-radius: 2px; } a code { color: inherit; + background: inherit; } span.type { @@ -360,12 +362,13 @@ span.type { #column1.interior { width: 702px; - border-left: 234px solid #f2f5f0; + margin-left: 234px; padding-left: 2.0em; } #column2.interior { width: 234px; + background: #333; position: fixed; height: 100%; overflow-y: scroll; @@ -377,8 +380,8 @@ span.type { bottom: 0; left: 0; width: 234px; - height: 5em; - background: linear-gradient(rgba(242,245,240, 0), rgba(242,245,240, 1)); + height: 4em; + background: linear-gradient(rgba(242,245,240, 0), rgba(51, 51, 51, 1)); pointer-events: none; } @@ -386,9 +389,9 @@ span.type { list-style: none; margin-left: 0em; margin-top: 1.25em; - background: #f2f5f0; + background: #333; margin-bottom: 0; - padding-bottom: 4em; + padding-bottom: 3em; } #column2 ul li { @@ -403,19 +406,24 @@ span.type { } #column2 ul li a { - color: #7a7a7a; + color: #ccc; + border-radius: 0; } -#column2 ul li a.active { - color: #533; - border-bottom: 1px solid #533; +#column2 ul li a.active, +#column2 ul li a.active:hover, +#column2 ul li a.active:focus { + color: #80bd01; + border-radius: 0; + border-bottom: 1px solid #80bd01; + background: none; } -#footer { - padding: 0; - min-height: 24px; - background: #333; - color: white; +#intro a:hover, +#column2 ul li a:hover, +#column2 ul li a:focus { + color: #fff; + background: none; } span > .mark, @@ -455,7 +463,7 @@ td > *:last-child { font-size: 2.1em; } #column1.interior { - border-left: 0; + margin-left: 0; padding-left: 0.5em; padding-right: 0.5em; width: auto; @@ -473,7 +481,7 @@ td > *:last-child { font-size: 2.4em; } #column1.interior { - border-left: 0; + margin-left: 0; padding-left: 0.5em; padding-right: 0.5em; width: auto; diff --git a/doc/template.html b/doc/template.html index f9f27d0dc267b4..dec3f50670226e 100644 --- a/doc/template.html +++ b/doc/template.html @@ -42,9 +42,6 @@

Table of Contents

- - From 500477c3a98c4fc9e4a713f90122991a715fa412 Mon Sep 17 00:00:00 2001 From: Myles Borins Date: Mon, 11 Jan 2016 18:01:31 -0800 Subject: [PATCH 12/15] doc: add branch-diff example to releases.md Useful to have for reference, especially for onboarding PR-URL: https://github.com/nodejs/node/pull/4636 Reviewed-By: Colin Ihrig Reviewed-By: James M Snell --- doc/releases.md | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/doc/releases.md b/doc/releases.md index 53aa4d53fb9157..2f55c2d8188538 100644 --- a/doc/releases.md +++ b/doc/releases.md @@ -54,6 +54,12 @@ Notes: Create a new branch named _"vx.y.z-proposal"_, or something similar. Using `git cherry-pick`, bring the appropriate commits into your new branch. To determine the relevant commits, use [`branch-diff`](https://github.com/rvagg/branch-diff) and [`changelog-maker`](https://github.com/rvagg/changelog-maker/) (both are available on npm and should be installed globally). These tools depend on our commit metadata, as well as the `semver-minor` and `semver-major` GitHub labels. One drawback is that when the `PR-URL` metadata is accidentally omitted from a commit, the commit will show up because it's unsure if it's a duplicate or not. +For a list of commits that could be landed in a patch release on v5.x + +``` +$ branch-diff v5.x master --exclude-label semver-major,semver-minor,dont-land-on-v5.x --simple +``` + Carefully review the list of commits looking for errors (incorrect `PR-URL`, incorrect semver, etc.). Commits labeled as semver minor or semver major should only be cherry-picked when appropriate for the type of release being made. Previous release commits and version bumps do not need to be cherry-picked. ### 2. Update `src/node_version.h` From ed427a69fbfcbbc43f1faf4c096694e227f9c7e3 Mon Sep 17 00:00:00 2001 From: Myles Borins Date: Tue, 12 Jan 2016 16:07:29 -0800 Subject: [PATCH 13/15] docs: fix npm command in releases.md PR-URL: https://github.com/nodejs/node/pull/4656 Reviewed-By: Colin Ihrig Reviewed-By: Rod Vagg Reviewed-By: James M Snell --- doc/releases.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/doc/releases.md b/doc/releases.md index 2f55c2d8188538..daa325b0bce351 100644 --- a/doc/releases.md +++ b/doc/releases.md @@ -254,7 +254,7 @@ Your release should be available at and Date: Tue, 12 Jan 2016 16:22:25 -0800 Subject: [PATCH 14/15] docs: update gpg key for Myles Borins Original key did not have personal information associated with it. The new key rectifies this problem PR-URL: https://github.com/nodejs/node/pull/4657 Reviewed-By: Colin Ihrig Reviewed-By: Rod Vagg Reviewed-By: James M Snell --- README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 0de5a9e75a7562..c534c64fbe29a7 100644 --- a/README.md +++ b/README.md @@ -444,7 +444,7 @@ Releases of Node.js and io.js will be signed with one of the following GPG keys: * **Jeremiah Senkpiel** <fishrock@keybase.io> `FD3A5288F042B6850C66B31F09FE44734EB7990E` * **James M Snell** <jasnell@keybase.io> `71DCFD284A79C3B38668286BC97EC7A07EDE3FC1` * **Rod Vagg** <rod@vagg.org> `DD8F2338BAE7501E3DD5AC78C273792F7D83545D` -* **Myles Borins** <thealphanerd@keybase.io> `792807C150954BF0299B289A38CE40DEEE898E15` +* **Myles Borins** <myles.borins@gmail.com> `C4F0DFFF4E8C1A8236409D08E73BC641CC11F4C8` * **Evan Lucas** <evanlucas@me.com> `B9AE9905FFD7803F25714661B63B535A4C206CA9` The full set of trusted release keys can be imported by running: @@ -456,7 +456,7 @@ gpg --keyserver pool.sks-keyservers.net --recv-keys 0034A06D9D9B0064CE8ADF6BF174 gpg --keyserver pool.sks-keyservers.net --recv-keys FD3A5288F042B6850C66B31F09FE44734EB7990E gpg --keyserver pool.sks-keyservers.net --recv-keys 71DCFD284A79C3B38668286BC97EC7A07EDE3FC1 gpg --keyserver pool.sks-keyservers.net --recv-keys DD8F2338BAE7501E3DD5AC78C273792F7D83545D -gpg --keyserver pool.sks-keyservers.net --recv-keys 792807C150954BF0299B289A38CE40DEEE898E15 +gpg --keyserver pool.sks-keyservers.net --recv-keys C4F0DFFF4E8C1A8236409D08E73BC641CC11F4C8 gpg --keyserver pool.sks-keyservers.net --recv-keys B9AE9905FFD7803F25714661B63B535A4C206CA9 ``` From 0cac16410c28d3e9cb69be168c4e6c499a9ce8ec Mon Sep 17 00:00:00 2001 From: Rich Trott Date: Tue, 29 Dec 2015 18:56:29 -0800 Subject: [PATCH 15/15] test: remove unused modules Many tests use require() to import modules that subsequently never gets used. This removes those imports and, in a few cases, removes other unused variables from tests. --- test/addons/at-exit/test.js | 2 +- test/internet/test-dns-ipv4.js | 2 -- test/internet/test-dns-ipv6.js | 2 -- test/message/2100bytes.js | 1 - test/parallel/test-cluster-eaddrinuse.js | 1 - test/parallel/test-cluster-worker-forced-exit.js | 1 - test/parallel/test-crypto-certificate.js | 1 - .../parallel/test-dgram-send-callback-buffer-length.js | 2 -- test/parallel/test-dgram-udp4.js | 3 +-- test/parallel/test-domain-multi.js | 1 - test/parallel/test-eval-require.js | 2 -- .../test-event-emitter-listeners-side-effects.js | 1 - test/parallel/test-fs-readdir.js | 1 - test/parallel/test-listen-fd-cluster.js | 1 - test/parallel/test-listen-fd-server.js | 1 - test/parallel/test-readline-keys.js | 3 +-- test/parallel/test-tls-legacy-onselect.js | 10 ---------- test/parallel/test-zlib-dictionary.js | 1 - test/parallel/test-zlib-flush-drain.js | 1 - test/parallel/test-zlib-write-after-flush.js | 1 - test/pummel/test-dtrace-jsstack.js | 3 --- test/pummel/test-http-client-reconnect-bug.js | 1 - test/pummel/test-keep-alive.js | 1 - test/pummel/test-timer-wrap2.js | 3 +-- test/pummel/test-tls-securepair-client.js | 4 ---- test/sequential/test-child-process-execsync.js | 1 - test/sequential/test-regress-GH-1697.js | 3 +-- test/sequential/test-stdout-close-catch.js | 1 - 28 files changed, 5 insertions(+), 50 deletions(-) diff --git a/test/addons/at-exit/test.js b/test/addons/at-exit/test.js index 32264a6604eeb6..c94453cb3b05a4 100644 --- a/test/addons/at-exit/test.js +++ b/test/addons/at-exit/test.js @@ -1,3 +1,3 @@ 'use strict'; require('../../common'); -var binding = require('./build/Release/binding'); +require('./build/Release/binding'); diff --git a/test/internet/test-dns-ipv4.js b/test/internet/test-dns-ipv4.js index 04befca6370e1e..bdca60d1b4fd5d 100644 --- a/test/internet/test-dns-ipv4.js +++ b/test/internet/test-dns-ipv4.js @@ -3,9 +3,7 @@ var common = require('../common'); var assert = require('assert'), dns = require('dns'), net = require('net'), - isIP = net.isIP, isIPv4 = net.isIPv4; -var util = require('util'); var expected = 0, completed = 0, diff --git a/test/internet/test-dns-ipv6.js b/test/internet/test-dns-ipv6.js index 27547edcd84b46..d7c50a1e86b656 100644 --- a/test/internet/test-dns-ipv6.js +++ b/test/internet/test-dns-ipv6.js @@ -3,9 +3,7 @@ var common = require('../common'); var assert = require('assert'), dns = require('dns'), net = require('net'), - isIP = net.isIP, isIPv6 = net.isIPv6; -var util = require('util'); var expected = 0, completed = 0, diff --git a/test/message/2100bytes.js b/test/message/2100bytes.js index 03aca7a6626bce..0f696806be03fe 100644 --- a/test/message/2100bytes.js +++ b/test/message/2100bytes.js @@ -1,6 +1,5 @@ 'use strict'; require('../common'); -var util = require('util'); console.log([ '_______________________________________________50', diff --git a/test/parallel/test-cluster-eaddrinuse.js b/test/parallel/test-cluster-eaddrinuse.js index 6ff68252d9d867..3821551f00a32c 100644 --- a/test/parallel/test-cluster-eaddrinuse.js +++ b/test/parallel/test-cluster-eaddrinuse.js @@ -5,7 +5,6 @@ var common = require('../common'); var assert = require('assert'); -var cluster = require('cluster'); var fork = require('child_process').fork; var net = require('net'); diff --git a/test/parallel/test-cluster-worker-forced-exit.js b/test/parallel/test-cluster-worker-forced-exit.js index 76f5cc69a9f716..ef9f7728bad3a2 100644 --- a/test/parallel/test-cluster-worker-forced-exit.js +++ b/test/parallel/test-cluster-worker-forced-exit.js @@ -2,7 +2,6 @@ require('../common'); var assert = require('assert'); var cluster = require('cluster'); -var net = require('net'); var SENTINEL = 42; diff --git a/test/parallel/test-crypto-certificate.js b/test/parallel/test-crypto-certificate.js index 8286d58d1e44ca..9814b395552e9f 100644 --- a/test/parallel/test-crypto-certificate.js +++ b/test/parallel/test-crypto-certificate.js @@ -11,7 +11,6 @@ var crypto = require('crypto'); crypto.DEFAULT_ENCODING = 'buffer'; var fs = require('fs'); -var path = require('path'); // Test Certificates var spkacValid = fs.readFileSync(common.fixturesDir + '/spkac.valid'); diff --git a/test/parallel/test-dgram-send-callback-buffer-length.js b/test/parallel/test-dgram-send-callback-buffer-length.js index a34c5e2eb6b8db..80c2d23e42ef55 100644 --- a/test/parallel/test-dgram-send-callback-buffer-length.js +++ b/test/parallel/test-dgram-send-callback-buffer-length.js @@ -2,9 +2,7 @@ var common = require('../common'); var assert = require('assert'); -var fs = require('fs'); var dgram = require('dgram'); -var callbacks = 0; var client, timer, buf, len, offset; diff --git a/test/parallel/test-dgram-udp4.js b/test/parallel/test-dgram-udp4.js index 5b1ede414eb1a1..58c8b69839ffe6 100644 --- a/test/parallel/test-dgram-udp4.js +++ b/test/parallel/test-dgram-udp4.js @@ -2,8 +2,7 @@ var common = require('../common'); var assert = require('assert'); -var fs = require('fs'), - dgram = require('dgram'), server, client, +var dgram = require('dgram'), server, client, server_port = common.PORT, message_to_send = 'A message to send', timer; diff --git a/test/parallel/test-domain-multi.js b/test/parallel/test-domain-multi.js index e5f9f6748b178e..ac01d66deee544 100644 --- a/test/parallel/test-domain-multi.js +++ b/test/parallel/test-domain-multi.js @@ -4,7 +4,6 @@ var common = require('../common'); var assert = require('assert'); var domain = require('domain'); -var events = require('events'); var caughtA = false; var caughtB = false; diff --git a/test/parallel/test-eval-require.js b/test/parallel/test-eval-require.js index f966b5a98c80ba..4e2ddf42b6dffa 100644 --- a/test/parallel/test-eval-require.js +++ b/test/parallel/test-eval-require.js @@ -2,8 +2,6 @@ var common = require('../common'); var assert = require('assert'); var spawn = require('child_process').spawn; -var path = require('path'); -var fs = require('fs'); var options = { cwd: common.fixturesDir diff --git a/test/parallel/test-event-emitter-listeners-side-effects.js b/test/parallel/test-event-emitter-listeners-side-effects.js index 8f40d88f34486e..5b9f2f3ddf0f41 100644 --- a/test/parallel/test-event-emitter-listeners-side-effects.js +++ b/test/parallel/test-event-emitter-listeners-side-effects.js @@ -2,7 +2,6 @@ require('../common'); var assert = require('assert'); -var events = require('events'); var EventEmitter = require('events').EventEmitter; var assert = require('assert'); diff --git a/test/parallel/test-fs-readdir.js b/test/parallel/test-fs-readdir.js index b08f42b5c23f85..9a9b85ecaccd2c 100644 --- a/test/parallel/test-fs-readdir.js +++ b/test/parallel/test-fs-readdir.js @@ -2,7 +2,6 @@ const common = require('../common'); const assert = require('assert'); -const path = require('path'); const fs = require('fs'); const readdirDir = common.tmpDir; diff --git a/test/parallel/test-listen-fd-cluster.js b/test/parallel/test-listen-fd-cluster.js index f6d00c72a0f78c..c321f699d7a89d 100644 --- a/test/parallel/test-listen-fd-cluster.js +++ b/test/parallel/test-listen-fd-cluster.js @@ -4,7 +4,6 @@ var assert = require('assert'); var http = require('http'); var net = require('net'); var PORT = common.PORT; -var spawn = require('child_process').spawn; var cluster = require('cluster'); console.error('Cluster listen fd test', process.argv[2] || 'runner'); diff --git a/test/parallel/test-listen-fd-server.js b/test/parallel/test-listen-fd-server.js index d51d51ee8eb4de..3e0fa521f75334 100644 --- a/test/parallel/test-listen-fd-server.js +++ b/test/parallel/test-listen-fd-server.js @@ -4,7 +4,6 @@ var assert = require('assert'); var http = require('http'); var net = require('net'); var PORT = common.PORT; -var spawn = require('child_process').spawn; if (common.isWindows) { console.log('1..0 # Skipped: This test is disabled on windows.'); diff --git a/test/parallel/test-readline-keys.js b/test/parallel/test-readline-keys.js index 5cac38a1d7db42..e026c0b583cd9e 100644 --- a/test/parallel/test-readline-keys.js +++ b/test/parallel/test-readline-keys.js @@ -1,6 +1,5 @@ 'use strict'; require('../common'); -var EventEmitter = require('events').EventEmitter; var PassThrough = require('stream').PassThrough; var assert = require('assert'); var inherits = require('util').inherits; @@ -16,7 +15,7 @@ inherits(FakeInput, PassThrough); var fi = new FakeInput(); var fo = new FakeInput(); -var rli = new Interface({ input: fi, output: fo, terminal: true }); +new Interface({ input: fi, output: fo, terminal: true }); var keys = []; fi.on('keypress', function(s, k) { diff --git a/test/parallel/test-tls-legacy-onselect.js b/test/parallel/test-tls-legacy-onselect.js index 6f1e9a91a8344c..d3b20d5d8a4cef 100644 --- a/test/parallel/test-tls-legacy-onselect.js +++ b/test/parallel/test-tls-legacy-onselect.js @@ -9,18 +9,8 @@ if (!common.hasCrypto) { var tls = require('tls'); var net = require('net'); -var fs = require('fs'); - var success = false; -function filenamePEM(n) { - return require('path').join(common.fixturesDir, 'keys', n + '.pem'); -} - -function loadPEM(n) { - return fs.readFileSync(filenamePEM(n)); -} - var server = net.Server(function(raw) { var pair = tls.createSecurePair(null, true, false, false); pair.on('error', function() {}); diff --git a/test/parallel/test-zlib-dictionary.js b/test/parallel/test-zlib-dictionary.js index d190ff51a57e63..f8ce5bfbe87df4 100644 --- a/test/parallel/test-zlib-dictionary.js +++ b/test/parallel/test-zlib-dictionary.js @@ -4,7 +4,6 @@ require('../common'); const assert = require('assert'); const zlib = require('zlib'); -const path = require('path'); var spdyDict = new Buffer([ 'optionsgetheadpostputdeletetraceacceptaccept-charsetaccept-encodingaccept-', diff --git a/test/parallel/test-zlib-flush-drain.js b/test/parallel/test-zlib-flush-drain.js index 26285c04739a25..f04dac9f0699ac 100644 --- a/test/parallel/test-zlib-flush-drain.js +++ b/test/parallel/test-zlib-flush-drain.js @@ -2,7 +2,6 @@ require('../common'); const assert = require('assert'); const zlib = require('zlib'); -const path = require('path'); const bigData = new Buffer(10240).fill('x'); diff --git a/test/parallel/test-zlib-write-after-flush.js b/test/parallel/test-zlib-write-after-flush.js index 53fa715a673f7e..fa70c5f14dee6c 100644 --- a/test/parallel/test-zlib-write-after-flush.js +++ b/test/parallel/test-zlib-write-after-flush.js @@ -2,7 +2,6 @@ require('../common'); var assert = require('assert'); var zlib = require('zlib'); -var fs = require('fs'); var gzip = zlib.createGzip(); var gunz = zlib.createUnzip(); diff --git a/test/pummel/test-dtrace-jsstack.js b/test/pummel/test-dtrace-jsstack.js index 513cbeb0ee7f96..b558dd28020c07 100644 --- a/test/pummel/test-dtrace-jsstack.js +++ b/test/pummel/test-dtrace-jsstack.js @@ -2,7 +2,6 @@ require('../common'); var assert = require('assert'); var os = require('os'); -var util = require('util'); if (os.type() != 'SunOS') { console.log('1..0 # Skipped: no DTRACE support'); @@ -13,7 +12,6 @@ if (os.type() != 'SunOS') { * Some functions to create a recognizable stack. */ var frames = [ 'stalloogle', 'bagnoogle', 'doogle' ]; -var expected; var stalloogle = function(str) { expected = str; @@ -35,7 +33,6 @@ var doogle = function() { var spawn = require('child_process').spawn; var prefix = '/var/tmp/node'; -var corefile = prefix + '.' + process.pid; /* * We're going to use DTrace to stop us, gcore us, and set us running again diff --git a/test/pummel/test-http-client-reconnect-bug.js b/test/pummel/test-http-client-reconnect-bug.js index bd852e45f19410..12a6fecc7050e8 100644 --- a/test/pummel/test-http-client-reconnect-bug.js +++ b/test/pummel/test-http-client-reconnect-bug.js @@ -3,7 +3,6 @@ var common = require('../common'); var assert = require('assert'); var net = require('net'), - util = require('util'), http = require('http'); var errorCount = 0; diff --git a/test/pummel/test-keep-alive.js b/test/pummel/test-keep-alive.js index c2ec7fd81f1691..46190555b27263 100644 --- a/test/pummel/test-keep-alive.js +++ b/test/pummel/test-keep-alive.js @@ -5,7 +5,6 @@ var common = require('../common'); var assert = require('assert'); var spawn = require('child_process').spawn; var http = require('http'); -var path = require('path'); var url = require('url'); if (common.isWindows) { diff --git a/test/pummel/test-timer-wrap2.js b/test/pummel/test-timer-wrap2.js index 9f62bd95d01974..87497b2685f5d3 100644 --- a/test/pummel/test-timer-wrap2.js +++ b/test/pummel/test-timer-wrap2.js @@ -1,9 +1,8 @@ 'use strict'; require('../common'); -var assert = require('assert'); // Test that allocating a timer does not increase the loop's reference // count. var Timer = process.binding('timer_wrap').Timer; -var t = new Timer(); +new Timer(); diff --git a/test/pummel/test-tls-securepair-client.js b/test/pummel/test-tls-securepair-client.js index aaf8e628d6a2bc..3d33ef8f21623f 100644 --- a/test/pummel/test-tls-securepair-client.js +++ b/test/pummel/test-tls-securepair-client.js @@ -17,9 +17,7 @@ var join = require('path').join; var net = require('net'); var assert = require('assert'); var fs = require('fs'); -var crypto = require('crypto'); var tls = require('tls'); -var exec = require('child_process').exec; var spawn = require('child_process').spawn; test1(); @@ -47,8 +45,6 @@ function test(keyfn, certfn, check, next) { // EADDRINUSE. var PORT = common.PORT + 5; - var connections = 0; - keyfn = join(common.fixturesDir, keyfn); var key = fs.readFileSync(keyfn).toString(); diff --git a/test/sequential/test-child-process-execsync.js b/test/sequential/test-child-process-execsync.js index 0bc4e02c65edb8..205485c9ebbc48 100644 --- a/test/sequential/test-child-process-execsync.js +++ b/test/sequential/test-child-process-execsync.js @@ -1,7 +1,6 @@ 'use strict'; var common = require('../common'); var assert = require('assert'); -var os = require('os'); var execSync = require('child_process').execSync; var execFileSync = require('child_process').execFileSync; diff --git a/test/sequential/test-regress-GH-1697.js b/test/sequential/test-regress-GH-1697.js index ff5754f357dfc1..ba7f90ecf00951 100644 --- a/test/sequential/test-regress-GH-1697.js +++ b/test/sequential/test-regress-GH-1697.js @@ -1,8 +1,7 @@ 'use strict'; var common = require('../common'); var net = require('net'), - cp = require('child_process'), - util = require('util'); + cp = require('child_process'); if (process.argv[2] === 'server') { // Server diff --git a/test/sequential/test-stdout-close-catch.js b/test/sequential/test-stdout-close-catch.js index f0ecf9a7c4b725..470fa9843cb9de 100644 --- a/test/sequential/test-stdout-close-catch.js +++ b/test/sequential/test-stdout-close-catch.js @@ -3,7 +3,6 @@ var common = require('../common'); var assert = require('assert'); var path = require('path'); var child_process = require('child_process'); -var fs = require('fs'); var testScript = path.join(common.fixturesDir, 'catch-stdout-error.js');