You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: packages/cli/README.md
+63-26Lines changed: 63 additions & 26 deletions
Original file line number
Diff line number
Diff line change
@@ -92,13 +92,27 @@ If GitHub mode is enabled but the requirements are not met, MyCoder will provide
92
92
93
93
## Configuration
94
94
95
-
MyCoder is configured using a `mycoder.config.js` file in your project root, similar to ESLint and other modern JavaScript tools. This file exports a configuration object with your preferred settings.
95
+
MyCoder is configured using a configuration file in your project. MyCoder supports multiple configuration file locations and formats, similar to ESLint and other modern JavaScript tools.
96
96
97
-
You can create a `mycoder.config.js` file in your project root with your preferred settings.
97
+
### Configuration File Locations
98
98
99
-
Example configuration file:
99
+
MyCoder will look for configuration in the following locations (in order of precedence):
100
100
101
-
```javascript
101
+
1.`mycoder.config.js` in your project root
102
+
2.`.mycoder.config.js` in your project root
103
+
3.`.config/mycoder.js` in your project root
104
+
4.`.mycoder.rc` in your project root
105
+
5.`.mycoder.rc` in your home directory
106
+
6.`mycoder` field in `package.json`
107
+
7.`~/.config/mycoder/config.js` (XDG standard user configuration)
108
+
109
+
Multiple file extensions are supported: `.js`, `.ts`, `.mjs`, `.cjs`, `.json`, `.jsonc`, `.json5`, `.yaml`, `.yml`, and `.toml`.
110
+
111
+
### Creating a Configuration File
112
+
113
+
Create a configuration file in your preferred location:
114
+
115
+
```js
102
116
// mycoder.config.js
103
117
exportdefault {
104
118
// GitHub integration
@@ -116,10 +130,20 @@ export default {
116
130
temperature:0.7,
117
131
118
132
// Custom settings
133
+
// customPrompt can be a string or an array of strings for multiple lines
119
134
customPrompt:'',
135
+
// Example of multiple line custom prompts:
136
+
// customPrompt: [
137
+
// 'Custom instruction line 1',
138
+
// 'Custom instruction line 2',
139
+
// 'Custom instruction line 3',
140
+
// ],
120
141
profile:false,
121
142
tokenCache:true,
122
143
144
+
// Base URL configuration (for providers that need it)
145
+
baseUrl:'http://localhost:11434', // Example for Ollama
0 commit comments