From 62ea82b73e00c5bcf865cfe8b051decc3f721286 Mon Sep 17 00:00:00 2001 From: Lance Ball Date: Sun, 1 Oct 2017 17:02:08 -0400 Subject: [PATCH] doc: add 'git clean -xfd' to backport guide When changing from a recent version, e.g. 8.x to an older branch like 6.x test artifacts sometimes hang around and cause failures. Using `git clean` will prevent that from happening. PR-URL: https://github.com/nodejs/node/pull/15715 Reviewed-By: James M Snell Reviewed-By: Gibson Fahnestock Reviewed-By: Refael Ackermann --- doc/guides/backporting-to-release-lines.md | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/doc/guides/backporting-to-release-lines.md b/doc/guides/backporting-to-release-lines.md index 9f48d940cd128f..07da834e14d0ce 100644 --- a/doc/guides/backporting-to-release-lines.md +++ b/doc/guides/backporting-to-release-lines.md @@ -44,6 +44,11 @@ cd $NODE_DIR git fetch upstream v6.x-staging:v6.x-staging -f # Assume we want to backport PR #10157 git checkout -b backport-10157-to-v6.x v6.x-staging +# Ensure there are no test artifacts from previous builds +# Note that this command deletes all files and directories +# not under revision control below the ./test directory. +# It is optional and should be used with caution. +git clean -xfd ./test/ ``` 4. After creating the branch, apply the changes to the branch. The cherry-pick