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
- `Created`: Date/time when the repository was created
120
+
121
+
## Field Configuration
122
+
123
+
You can customize which fields are included in the output by using a field configuration CSV file with the `-c` or `--config` option. This is useful when you only need specific fields and want to reduce the output size.
124
+
125
+
### Configuration File Format
126
+
127
+
Create a CSV file with the following format:
128
+
129
+
```csv
130
+
Field_Name,Should_Fetch
131
+
Org_Name,true
132
+
Repo_Name,true
133
+
Is_Empty,false
134
+
Last_Push,true
135
+
...
136
+
```
137
+
138
+
- `Field_Name`: The name of the field (must match exactly)
139
+
- `Should_Fetch`: `true` to include the field, `false` to exclude it
140
+
141
+
### Example Configuration File
142
+
143
+
A sample configuration file `fields-config.csv` is provided in the repository with all fields enabled. You can copy and modify it to suit your needs:
144
+
145
+
```shell
146
+
# Use custom field configuration
147
+
gh repo-stats -o my-org-name -c fields-config.csv
148
+
```
149
+
150
+
### Available Fields
151
+
152
+
| Field Name | Description |
153
+
|------------|-------------|
154
+
| `Org_Name` | Organization login |
155
+
| `Repo_Name` | Repository name |
156
+
| `Is_Empty` | Whether the repository is empty |
157
+
| `Last_Push` | Date/time when a push was last made |
158
+
| `Last_Update` | Date/time when an update was last made |
159
+
| `Latest_Commit_SHA` | SHA of the most recent commit |
160
+
| `Latest_Committed_At` | Date/time of the most recent commit |
161
+
| `Latest_Commit_Branch` | Branch of the most recent commit |
162
+
| `Default_Branch` | Default branch of the repository |
163
+
| `isFork` | Whether the repository is a fork |
164
+
| `isArchived` | Whether the repository is archived |
165
+
| `Repo_Size_mb` | Size of the repository in MB |
166
+
| `Record_Count` | Number of database records |
167
+
| `Collaborator_Count` | Number of collaborators |
168
+
| `Protected_Branch_Count` | Number of branch protection rules |
169
+
| `PR_Review_Count` | Number of pull request reviews |
170
+
| `Milestone_Count` | Number of milestones |
171
+
| `Issue_Count` | Number of issues |
172
+
| `PR_Count` | Number of pull requests |
173
+
| `PR_Review_Comment_Count` | Number of PR review comments |
174
+
| `Commit_Comment_Count` | Number of commit comments |
175
+
| `Issue_Comment_Count` | Number of issue comments |
176
+
| `Issue_Event_Count` | Number of issue events |
177
+
| `Release_Count` | Number of releases |
178
+
| `Project_Count` | Number of projects |
179
+
| `Branch_Count` | Number of branches |
180
+
| `Tag_Count` | Number of tags |
181
+
| `Discussion_Count` | Number of discussions |
182
+
| `Has_Wiki` | Whether wiki is enabled |
183
+
| `Full_URL` | Repository URL |
184
+
| `Migration_Issue` | Migration issue indicator |
185
+
| `Created` | Repository creation date |
186
+
187
+
**Note**: If no configuration file is specified or the file doesn't exist, all fields will be fetched by default.
0 commit comments