-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
feat(config): Add TypeScript/JavaScript config file support with defineConfig helper #886
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
Show all changes
16 commits
Select commit
Hold shift + click to select a range
7409157
feat(config): Add JavaScript/TypeScript config file support with defi…
yamadashy a47265c
feat(config): Add TypeScript config file support with jiti
yamadashy 0dc6df2
refactor(config): Use switch statement for file type checking
yamadashy a506201
docs(config): Add installation requirement for TypeScript/JavaScript …
yamadashy 751c999
docs(config): Add comment explaining direct import in repomix.config.ts
yamadashy d5c0647
docs(config): Add timestamp examples for dynamic config values
yamadashy 6b1340d
docs(config): Fix misleading TypeScript benefits description
yamadashy 9547add
docs: Reset website docs
yamadashy f856920
docs(config): Consolidate JSON format entries in priority list
yamadashy 079ec27
refactor(config): Use jiti for both TypeScript and JavaScript config …
yamadashy 0077a91
docs(config): Reorder configuration sections to prioritize JSON
yamadashy dc886d9
docs(config): Remove 'Recommended' label from TypeScript section
yamadashy 4fd6457
docs(config): Simplify JavaScript Configuration section
yamadashy 4f21d32
docs(config): Remove duplicate benefit from TypeScript section
yamadashy ead0235
docs(config): Add schema validation section to README
yamadashy 5b707f5
docs(config): Add $schema to example configuration
yamadashy File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,60 @@ | ||
| // Note: Normally you would import from 'repomix', but since this is the repomix project itself, | ||
| // we import directly from the source index file. | ||
| // For your projects, use: import { defineConfig } from 'repomix'; | ||
| import { defineConfig } from './src/index.js'; | ||
|
|
||
| export default defineConfig({ | ||
| input: { | ||
| maxFileSize: 50000000, | ||
| }, | ||
| output: { | ||
| filePath: 'repomix-output.xml', | ||
| style: 'xml', | ||
| parsableStyle: false, | ||
| compress: false, | ||
| headerText: `This repository contains the source code for the Repomix tool. | ||
| Repomix is designed to pack repository contents into a single file, | ||
| making it easier for AI systems to analyze and process the codebase. | ||
|
|
||
| Key Features: | ||
| - Configurable ignore patterns | ||
| - Custom header text support | ||
| - Efficient file processing and packing | ||
|
|
||
| Please refer to the README.md file for more detailed information on usage and configuration. | ||
| `, | ||
| instructionFilePath: 'repomix-instruction.md', | ||
| fileSummary: true, | ||
| directoryStructure: true, | ||
| files: true, | ||
| removeComments: false, | ||
| removeEmptyLines: false, | ||
| topFilesLength: 5, | ||
| showLineNumbers: false, | ||
| includeEmptyDirectories: true, | ||
| truncateBase64: true, | ||
| // Display token count tree for files/directories with 50000+ tokens | ||
| // Can be boolean (true/false) or number (minimum token threshold) | ||
| tokenCountTree: 50000, | ||
| git: { | ||
| sortByChanges: true, | ||
| sortByChangesMaxCommits: 100, | ||
| includeDiffs: true, | ||
| includeLogs: true, | ||
| includeLogsCount: 50, | ||
| }, | ||
| }, | ||
| include: [], | ||
| ignore: { | ||
| useGitignore: true, | ||
| useDefaultPatterns: true, | ||
| // ignore is specified in .repomixignore | ||
| customPatterns: [], | ||
| }, | ||
| security: { | ||
| enableSecurityCheck: true, | ||
| }, | ||
| tokenCount: { | ||
| encoding: 'o200k_base', | ||
| }, | ||
| }); | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.