Skip to main content
Glama
YeomYuJun

Remote Memory MCP Server

by YeomYuJun

get_commit_history

Retrieve recent commit history from GitHub repositories to track changes and maintain version control for remote memory data synchronization.

Instructions

최근 커밋 히스토리를 조회합니다

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
limitNo조회할 커밋 수 (기본: 10)

Implementation Reference

  • The primary handler function for the 'get_commit_history' tool. It parses the 'limit' argument, calls SyncManager.getCommitHistory, and returns a formatted JSON response with commits or error.
    private async handleGetCommitHistory(args: any) { try { const limit = args.limit || 10; const commits = await this.syncManager.getCommitHistory(limit); return { content: [{ type: 'text', text: JSON.stringify({ success: true, commits, count: commits.length }, null, 2), }], }; } catch (error) { return { content: [{ type: 'text', text: JSON.stringify({ success: false, error: error instanceof Error ? error.message : 'Unknown error' }, null, 2), }], }; } }
  • src/index.ts:359-371 (registration)
    Registration of the 'get_commit_history' tool in the ListTools response, including name, description, and input schema definition.
    { name: 'get_commit_history', description: '최근 커밋 히스토리를 조회합니다', inputSchema: { type: 'object', properties: { limit: { type: 'number', description: '조회할 커밋 수 (기본: 10)' } }, }, },
  • Input schema definition for the 'get_commit_history' tool, specifying an optional 'limit' parameter of type number.
    inputSchema: { type: 'object', properties: { limit: { type: 'number', description: '조회할 커밋 수 (기본: 10)' } }, },
  • Helper method in SyncManager that fetches commit history from GitHub for the memory file path, maps the response to a simplified format, and handles errors.
    async getCommitHistory(limit: number = 10): Promise<any[]> { try { const response = await this.githubClient.getCommits(this.MEMORY_FILE_PATH, limit); return response.map(commit => ({ sha: commit.sha.substring(0, 7), message: commit.commit.message, author: commit.commit.author.name, date: commit.commit.author.date, url: commit.html_url })); } catch (error) { console.error('Failed to get commit history:', error); return []; } }

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/YeomYuJun/remote-memory-mcp-server'

If you have feedback or need assistance with the MCP directory API, please join our Discord server