CSV Data Export
Relevant source files
The following files were used as context for generating this wiki page:
The CSV Data Export feature in Refined GitHub Projects allows users to download selected project items directly from the GitHub Projects V2 table view. This utility is designed to capture all visible fields, including standard metadata (Assignees, Labels) and custom project properties, into a portable format without requiring additional backend infrastructure.
Sources: README.md:99-100, CHANGELOG.md:154-155
Architecture and Implementation
The export system is integrated into the Bulk Actions Bar, which appears when items are selected in the GitHub Projects table view. Unlike many other bulk operations in this extension that rely on the sequential background queue to modify data, the CSV export focuses on data retrieval and local file generation.
Component Integration
The feature is accessible through the following interface elements:
- Bulk Actions Bar: Triggered by selecting items (e.g., via
⌘A/Ctrl+A). - Actions Menu: Accessible via the shortcut
⌘⇧Vspecifically for CSV export.
Sources: README.md:104-122, README.md:131-131
Data Flow for Export
The following diagram illustrates how the system prepares data for export by interacting with the GitHub DOM and GraphQL API.
The export process captures visible project rows and merges them with field definitions retrieved via the background script.
Sources: README.md:118-118, README.md:278-283, src/entries/background/helpers.ts:518-530
Data Mapping and Extraction
The export includes a comprehensive set of fields derived from the ProjectV2Item nodes. This includes content-specific details for Issues and Pull Requests as well as custom field values defined at the project level.
Exported Fields Summary
| Field Category | Data Points | Source File Reference |
|---|---|---|
| Core Metadata | Title, ID, Database ID, Number | src/lib/graphql/queries.ts:16-25 |
| Identity | Repository Name, Owner, Item Type | src/lib/graphql/queries.ts:26-28 |
| Project Fields | Status, Priority, Size, Estimates | README.md:104-105 |
| Custom Types | Single Select, Iteration, Date, Number | src/lib/graphql/queries.ts:35-64 |
| Relationships | Assignees, Labels, Parents | src/lib/graphql/queries.ts:29-32 |
Technical Execution
The system uses the GET_PROJECT_ITEM_DETAILS and GET_PROJECT_FIELDS queries to ensure that even fields not currently rendered in the immediate DOM view (but active in the project) can be included in the exported dataset.
Usage and Shortcuts
The CSV Data Export is optimized for speed, specifically designed to handle visible project rows without requiring the "extra API calls" usually associated with deep cloning or bulk editing.
- Keyboard Shortcut:
⌘⇧VorCtrl+Shift+V - Selection Support: Works with
⌘A(Select All) or individual checkbox selections. - Privacy: All processing happens locally; data is converted into a CSV blob in the browser and never sent to external servers.
Sources: README.md:131-131, README.md:154-154, README.md:213-217
Conclusion
CSV Data Export provides a critical bridge between GitHub's internal project management and external reporting tools. By leveraging the same background handlers and GraphQL queries used for bulk updates, it ensures data consistency across the exported report and the live project board.
Sources: README.md:118-118, CHANGELOG.md:154-155