* Switches the current directory to the repo root if needed. This is done so * that hard-coded paths within tasks can work predictably.
()
| 54 | * that hard-coded paths within tasks can work predictably. |
| 55 | */ |
| 56 | function startAtRepoRoot() { |
| 57 | const repoRoot = path.resolve(__dirname, '..', '..'); |
| 58 | if (repoRoot != process.cwd()) { |
| 59 | process.chdir(repoRoot); |
| 60 | log('Working directory changed to', magenta(path.basename(repoRoot))); |
| 61 | } |
| 62 | } |
| 63 | |
| 64 | /** |
| 65 | * 1. Updates root-level packages during local development. (Skipped during CI |
no test coverage detected