@pschroee/redmine-mcp 0.5.1 → 0.5.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -12,5 +12,7 @@ export interface JournalFormatOptions {
|
|
|
12
12
|
}
|
|
13
13
|
/**
|
|
14
14
|
* Format an array of journal entries as Markdown
|
|
15
|
+
* Entries are displayed in reverse chronological order (newest first)
|
|
16
|
+
* Note numbers are preserved (1 = oldest, highest = newest)
|
|
15
17
|
*/
|
|
16
18
|
export declare function formatJournals(journals: RedmineJournal[], lookup?: NameLookup, options?: JournalFormatOptions): string;
|
|
@@ -204,12 +204,16 @@ function formatJournalEntry(journal, index, lookup, options = {}) {
|
|
|
204
204
|
}
|
|
205
205
|
/**
|
|
206
206
|
* Format an array of journal entries as Markdown
|
|
207
|
+
* Entries are displayed in reverse chronological order (newest first)
|
|
208
|
+
* Note numbers are preserved (1 = oldest, highest = newest)
|
|
207
209
|
*/
|
|
208
210
|
export function formatJournals(journals, lookup = {}, options = {}) {
|
|
209
211
|
if (!journals || journals.length === 0) {
|
|
210
212
|
return "";
|
|
211
213
|
}
|
|
212
214
|
const header = `## History (${journals.length} entries)\n\n`;
|
|
213
|
-
|
|
215
|
+
// Format entries with their original indices (for note numbers), then reverse for display
|
|
216
|
+
const formattedEntries = journals.map((j, i) => formatJournalEntry(j, i, lookup, options));
|
|
217
|
+
const entries = formattedEntries.reverse().join("\n---\n\n");
|
|
214
218
|
return header + entries;
|
|
215
219
|
}
|
package/dist/server.js
CHANGED
|
@@ -3,7 +3,7 @@ import { registerTools } from "./tools/index.js";
|
|
|
3
3
|
export function createServer(redmineClient, toolGroups) {
|
|
4
4
|
const server = new McpServer({
|
|
5
5
|
name: "redmine-mcp",
|
|
6
|
-
version: "0.5.
|
|
6
|
+
version: "0.5.2",
|
|
7
7
|
});
|
|
8
8
|
registerTools(server, redmineClient, toolGroups);
|
|
9
9
|
return server;
|