Skip to content

Phase 1: Populate reusedCode from USWDS and CMS Design System dependencies#125

Open
haseebmalik18 wants to merge 1 commit into
DSACMS:devfrom
haseebmalik18:DSACMS/haseeb/reusedCodeFromDependencies
Open

Phase 1: Populate reusedCode from USWDS and CMS Design System dependencies#125
haseebmalik18 wants to merge 1 commit into
DSACMS:devfrom
haseebmalik18:DSACMS/haseeb/reusedCodeFromDependencies

Conversation

@haseebmalik18

Copy link
Copy Markdown

Problem

The reusedCode field, which lists government software a project reuses, is left empty by the generator and has to be filled in by hand.

Solution

Detect government-made dependencies from package.json and requirements.txt and populate reusedCode automatically.

  • src/gov-dependencies.ts — curated map of gov dependencies; Phase 1 covers USWDS and the CMS Design System
  • helper.tsdetectReusedCode matches manifest deps against the map, and mergeReusedCode merges them into existing entries while keeping manual edits and avoiding duplicates on re-run
  • wired into getMetaData in main.ts

Scope

This PR is Phase 1: USWDS and the CMS Design System. Phase 2 grows the list using federal npm orgs, CISA .gov data, keywords, and SBOMs. Phase 3 cross-checks against the federal source-code inventory.

Test Plan

npm test and npm run lint pass. Added unit tests for parsing, detection, alias de-duplication, and merge.

Related: #124

@haseebmalik18 haseebmalik18 changed the title populate reusedCode with detected USWDS and CMS Design System depende… Populate reusedCode with detected USWDS and CMS Design System dependencies Jun 30, 2026
@haseebmalik18 haseebmalik18 changed the title Populate reusedCode with detected USWDS and CMS Design System dependencies Phase 1: Populate reusedCode from dependency files Jun 30, 2026
@haseebmalik18 haseebmalik18 changed the title Phase 1: Populate reusedCode from dependency files Phase 1: Populate reusedCode from USWDS and CMS Design System dependencies Jun 30, 2026
@haseebmalik18

Copy link
Copy Markdown
Author

@natalialuzuriaga

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant