git-mob-mcp-server 1.0.0

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.
Files changed (44) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +89 -0
  3. package/dist/clients/gitMobClient.js +38 -0
  4. package/dist/clients/gitMobClient.test.js +114 -0
  5. package/dist/gitMobServerFactory.js +34 -0
  6. package/dist/gitMobServerFactory.test.js +58 -0
  7. package/dist/helpers/index.js +4 -0
  8. package/dist/helpers/registerGitMobResource.js +4 -0
  9. package/dist/helpers/registerGitMobResource.test.js +36 -0
  10. package/dist/helpers/registerGitMobResourceAsTool.js +24 -0
  11. package/dist/helpers/registerGitMobResourceAsTool.test.js +63 -0
  12. package/dist/helpers/registerGitMobTool.js +9 -0
  13. package/dist/helpers/registerGitMobTool.test.js +40 -0
  14. package/dist/helpers/runCliCommand.js +21 -0
  15. package/dist/helpers/runCliCommand.test.js +38 -0
  16. package/dist/index.js +8 -0
  17. package/dist/index.test.js +22 -0
  18. package/dist/resources/gitMobHelp.js +29 -0
  19. package/dist/resources/gitMobHelp.test.js +23 -0
  20. package/dist/resources/gitMobVersion.js +27 -0
  21. package/dist/resources/gitMobVersion.test.js +19 -0
  22. package/dist/resources/index.js +5 -0
  23. package/dist/resources/mobSessionCoauthorTrailers.js +39 -0
  24. package/dist/resources/mobSessionCoauthorTrailers.test.js +22 -0
  25. package/dist/resources/mobSessionCoauthors.js +40 -0
  26. package/dist/resources/mobSessionCoauthors.test.js +21 -0
  27. package/dist/resources/teamMembers.js +41 -0
  28. package/dist/resources/teamMembers.test.js +22 -0
  29. package/dist/tools/addTeamMember.js +31 -0
  30. package/dist/tools/addTeamMember.test.js +33 -0
  31. package/dist/tools/clearMobSession.js +23 -0
  32. package/dist/tools/clearMobSession.test.js +25 -0
  33. package/dist/tools/deleteTeamMember.js +28 -0
  34. package/dist/tools/deleteTeamMember.test.js +30 -0
  35. package/dist/tools/index.js +6 -0
  36. package/dist/tools/setMobSessionCoauthors.js +29 -0
  37. package/dist/tools/setMobSessionCoauthors.test.js +31 -0
  38. package/dist/tools/setupGitMobGlobally.js +27 -0
  39. package/dist/tools/setupGitMobGlobally.test.js +29 -0
  40. package/dist/tools/setupGitMobLocally.js +28 -0
  41. package/dist/tools/setupGitMobLocally.test.js +30 -0
  42. package/dist/types/GitMobResource.js +1 -0
  43. package/dist/types/GitMobTool.js +1 -0
  44. package/package.json +88 -0
@@ -0,0 +1,30 @@
1
+ import tool from "./setupGitMobLocally.js";
2
+ import { describe, it, expect } from "@jest/globals";
3
+ describe("[tools] setupGitMobLocally", () => {
4
+ it("should have correct name", () => {
5
+ expect(tool.name).toBe("setup_git_mob_locally");
6
+ });
7
+ it("should have correct description", () => {
8
+ const description = "Sets up the Git Mob CLI for the current repository by installing a local " +
9
+ "prepare-commit-msg git hook. This hook delegates to the global " +
10
+ "prepare-commit-msg hook configured by setupGitMobGlobally. Use this tool " +
11
+ "only if your repository overrides the core.hooksPath git " +
12
+ "configuration (e.g., when using Husky). Note: You must run " +
13
+ "setupGitMobGlobally at least once before using this tool.";
14
+ expect(tool.description).toBe(description);
15
+ });
16
+ it("should have correct input schema", () => {
17
+ const inputSchema = {};
18
+ expect(JSON.stringify(tool.inputSchema)).toEqual(JSON.stringify(inputSchema));
19
+ });
20
+ it("should have correct annotations", () => {
21
+ const annotations = {
22
+ title: "Setup Git Mob Locally",
23
+ readOnlyHint: false,
24
+ destructiveHint: true,
25
+ idempotentHint: false,
26
+ openWorldHint: false,
27
+ };
28
+ expect(tool.annotations).toEqual(annotations);
29
+ });
30
+ });
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1 @@
1
+ export {};
package/package.json ADDED
@@ -0,0 +1,88 @@
1
+ {
2
+ "name": "git-mob-mcp-server",
3
+ "version": "1.0.0",
4
+ "description": "MCP Server for git-mob CLI app",
5
+ "main": "dist/index.js",
6
+ "type": "module",
7
+ "bin": {
8
+ "git-mob-mcp-server": "dist/index.js"
9
+ },
10
+ "files": [
11
+ "dist"
12
+ ],
13
+ "scripts": {
14
+ "build": "tsc && shx chmod +x dist/*.js",
15
+ "eslint": "eslint .",
16
+ "eslint:fix": "eslint --fix",
17
+ "format": "prettier --write \"**/*.{js,mjs,cjs,ts}\"",
18
+ "lint": "npm-run-all typecheck eslint",
19
+ "lint:fix": "npm-run-all format typecheck eslint:fix",
20
+ "prepare": "npm run build",
21
+ "start": "node --experimental-strip-types src/index.ts",
22
+ "test": "jest",
23
+ "typecheck": "tsc --noEmit",
24
+ "watch": "node --experimental-strip-types --watch src/index.ts"
25
+ },
26
+ "publishConfig": {
27
+ "access": "public",
28
+ "registry": "https://registry.npmjs.org/",
29
+ "tag": "latest"
30
+ },
31
+ "repository": {
32
+ "type": "git",
33
+ "url": "git+https://github.com/Mubashwer/git-mob-mcp-server.git"
34
+ },
35
+ "keywords": [
36
+ "git-mob",
37
+ "mcp-server",
38
+ "git-pair",
39
+ "pair-programming"
40
+ ],
41
+ "author": "Mubashwer Salman Khurshid",
42
+ "license": "MIT",
43
+ "devDependencies": {
44
+ "@eslint/js": "^9.27.0",
45
+ "@types/jest": "^29.5.14",
46
+ "@types/node": "^22.15.18",
47
+ "eslint": "^9.27.0",
48
+ "eslint-config-prettier": "^10.1.5",
49
+ "globals": "^16.1.0",
50
+ "jest": "^29.7.0",
51
+ "npm-run-all": "^4.1.5",
52
+ "prettier": "3.5.3",
53
+ "semantic-release": "^24.2.5",
54
+ "shx": "^0.4.0",
55
+ "ts-jest": "^29.3.4",
56
+ "typescript": "^5.8.3",
57
+ "typescript-eslint": "^8.32.1"
58
+ },
59
+ "dependencies": {
60
+ "@modelcontextprotocol/sdk": "^1.11.4"
61
+ },
62
+ "jest": {
63
+ "preset": "ts-jest/presets/default-esm",
64
+ "testEnvironment": "node",
65
+ "extensionsToTreatAsEsm": [
66
+ ".ts"
67
+ ],
68
+ "transform": {
69
+ "^.+\\.ts$": [
70
+ "ts-jest",
71
+ {
72
+ "useESM": true,
73
+ "tsconfig": "<rootDir>/tsconfig.json"
74
+ }
75
+ ]
76
+ },
77
+ "moduleNameMapper": {
78
+ "^(\\.{1,2}/.*)\\.js$": "$1"
79
+ },
80
+ "collectCoverageFrom": [
81
+ "<rootDir>/src/**/*"
82
+ ],
83
+ "testPathIgnorePatterns": [
84
+ "/node_modules",
85
+ "/dist"
86
+ ]
87
+ }
88
+ }