Skip to content

Commit

Permalink
chore!: remove unmarked DEP0XXX handler (#685)
Browse files Browse the repository at this point in the history
The deprecation numbers are linted by the `test-doc` test suite, and
using `DEP0XXX` would be flagged as invalid before the PR can land.
  • Loading branch information
aduh95 committed Sep 24, 2023
1 parent 517a259 commit bdb85a9
Show file tree
Hide file tree
Showing 3 changed files with 0 additions and 95 deletions.
50 changes: 0 additions & 50 deletions lib/deprecations.js

This file was deleted.

21 changes: 0 additions & 21 deletions lib/landing_session.js
@@ -1,9 +1,5 @@
import os from 'node:os';

import {
getUnmarkedDeprecations,
updateDeprecations
} from './deprecations.js';
import {
runAsync, runSync, forceRunAsync
} from './run.js';
Expand Down Expand Up @@ -128,23 +124,6 @@ export default class LandingSession extends Session {
process.exit(1);
}

// Check for and maybe assign any unmarked deprecations in the codebase.
if (this.updateDeprecations !== 'yes') {
const unmarkedDeprecations = await getUnmarkedDeprecations();
const unmarkedDepCount = unmarkedDeprecations.length;
if (unmarkedDepCount > 0) {
cli.startSpinner('Assigning deprecation numbers to DEPOXXX items');

// Update items then stage files and amend the last commit.
await updateDeprecations(unmarkedDeprecations);
await runAsync('git', ['add', 'doc', 'lib', 'src', 'test']);
await runAsync('git', ['commit', '--amend', '--no-edit', ...this.gpgSign]);

cli
.stopSpinner(`Updated ${unmarkedDepCount} DEPOXXX items in codebase`);
}
}

cli.ok('Patches applied');
return commitInfo;
}
Expand Down
24 changes: 0 additions & 24 deletions lib/prepare_release.js
Expand Up @@ -9,10 +9,6 @@ import { runAsync, runSync } from './run.js';
import { writeJson, readJson } from './file.js';
import Request from './request.js';
import auth from './auth.js';
import {
getUnmarkedDeprecations,
updateDeprecations
} from './deprecations.js';
import {
getEOLDate,
getStartLTSBlurb,
Expand Down Expand Up @@ -279,26 +275,6 @@ export default class ReleasePreparation {
await this.updateREPLACEMEs();
cli.stopSpinner('Updated REPLACEME items in docs');

// Check for and maybe assign any unmarked deprecations in the codebase.
const unmarkedDeprecations = await getUnmarkedDeprecations();
const unmarkedDepCount = unmarkedDeprecations.length;
if (unmarkedDepCount > 0) {
if (unmarkedDepCount === 1) {
cli.startSpinner(
'Assigning deprecation number to DEPOXXX item');
await updateDeprecations(unmarkedDeprecations);
cli.stopSpinner('Assigned deprecation numbers to DEPOXXX items');
} else {
cli.warn(
'More than one unmarked DEPOXXX item - manual resolution required.');

await cli.prompt(
`Finished updating ${unmarkedDepCount} unmarked DEPOXXX items?`,
{ defaultAnswer: false });
cli.stopSpinner(`Finished updating ${unmarkedDepCount} DEPOXXX items`);
}
}

// Fetch date to use in release commit & changelogs.
const todayDate = new Date().toISOString().split('T')[0];
this.date = await cli.prompt('Enter release date in YYYY-MM-DD format:',
Expand Down

0 comments on commit bdb85a9

Please sign in to comment.