@pschroee/redmine-mcp 0.5.2 → 0.5.4

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.
@@ -13,6 +13,6 @@ export interface JournalFormatOptions {
13
13
  /**
14
14
  * Format an array of journal entries as Markdown
15
15
  * Entries are displayed in reverse chronological order (newest first)
16
- * Note numbers are preserved (1 = oldest, highest = newest)
16
+ * Note numbers match Redmine's numbering (1 = oldest, highest = newest)
17
17
  */
18
18
  export declare function formatJournals(journals: RedmineJournal[], lookup?: NameLookup, options?: JournalFormatOptions): string;
@@ -178,14 +178,13 @@ function formatDetail(detail, lookup, options = {}) {
178
178
  /**
179
179
  * Format a single journal entry as Markdown
180
180
  */
181
- function formatJournalEntry(journal, index, lookup, options = {}) {
181
+ function formatJournalEntry(journal, noteNumber, lookup, options = {}) {
182
182
  const lines = [];
183
183
  // Header with note number, date and user
184
- const noteNum = index + 1;
185
184
  const date = formatDate(journal.created_on);
186
185
  const user = journal.user.name;
187
186
  const privateTag = journal.private_notes ? " 🔒" : "";
188
- lines.push(`### #${noteNum} - ${date} - ${user}${privateTag}`);
187
+ lines.push(`### #${noteNumber} - ${date} - ${user}${privateTag}`);
189
188
  lines.push("");
190
189
  // Notes (if any)
191
190
  if (journal.notes && journal.notes.trim()) {
@@ -205,15 +204,15 @@ function formatJournalEntry(journal, index, lookup, options = {}) {
205
204
  /**
206
205
  * Format an array of journal entries as Markdown
207
206
  * Entries are displayed in reverse chronological order (newest first)
208
- * Note numbers are preserved (1 = oldest, highest = newest)
207
+ * Note numbers match Redmine's numbering (1 = oldest, highest = newest)
209
208
  */
210
209
  export function formatJournals(journals, lookup = {}, options = {}) {
211
210
  if (!journals || journals.length === 0) {
212
211
  return "";
213
212
  }
214
213
  const header = `## History (${journals.length} entries)\n\n`;
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));
214
+ // Format entries with correct note numbers (1 = oldest), then reverse for display (newest first)
215
+ const formattedEntries = journals.map((j, i) => formatJournalEntry(j, i + 1, lookup, options));
217
216
  const entries = formattedEntries.reverse().join("\n---\n\n");
218
217
  return header + entries;
219
218
  }
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.2",
6
+ version: "0.5.4",
7
7
  });
8
8
  registerTools(server, redmineClient, toolGroups);
9
9
  return server;
@@ -38,7 +38,7 @@ export function registerCoreTools(server, client) {
38
38
  inputSchema: {
39
39
  issue_id: z.number().describe("The issue ID"),
40
40
  include: z.string().optional().describe("Include: attachments, relations, journals, watchers, children, changesets, allowed_statuses"),
41
- include_description_diffs: z.boolean().optional().default(false).describe("Include full description diffs in history (can be verbose)"),
41
+ include_description_diffs: z.boolean().optional().default(true).describe("Include full description diffs in history (can be verbose)"),
42
42
  },
43
43
  }, async (params) => {
44
44
  // Fetch issue and enumerations in parallel
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pschroee/redmine-mcp",
3
- "version": "0.5.2",
3
+ "version": "0.5.4",
4
4
  "description": "MCP server for Redmine - full API access with configurable tool groups",
5
5
  "type": "module",
6
6
  "bin": {