mcp-server-git 2025.1.14__py3-none-any.whl

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.
@@ -0,0 +1,24 @@
1
+ import click
2
+ from pathlib import Path
3
+ import logging
4
+ import sys
5
+ from .server import serve
6
+
7
+ @click.command()
8
+ @click.option("--repository", "-r", type=Path, help="Git repository path")
9
+ @click.option("-v", "--verbose", count=True)
10
+ def main(repository: Path | None, verbose: bool) -> None:
11
+ """MCP Git Server - Git functionality for MCP"""
12
+ import asyncio
13
+
14
+ logging_level = logging.WARN
15
+ if verbose == 1:
16
+ logging_level = logging.INFO
17
+ elif verbose >= 2:
18
+ logging_level = logging.DEBUG
19
+
20
+ logging.basicConfig(level=logging_level, stream=sys.stderr)
21
+ asyncio.run(serve(repository))
22
+
23
+ if __name__ == "__main__":
24
+ main()
@@ -0,0 +1,5 @@
1
+ # __main__.py
2
+
3
+ from mcp_server_git import main
4
+
5
+ main()
@@ -0,0 +1,333 @@
1
+ import logging
2
+ from pathlib import Path
3
+ from typing import Sequence
4
+ from mcp.server import Server
5
+ from mcp.server.session import ServerSession
6
+ from mcp.server.stdio import stdio_server
7
+ from mcp.types import (
8
+ ClientCapabilities,
9
+ TextContent,
10
+ Tool,
11
+ ListRootsResult,
12
+ RootsCapability,
13
+ )
14
+ from enum import Enum
15
+ import git
16
+ from pydantic import BaseModel
17
+
18
+ class GitStatus(BaseModel):
19
+ repo_path: str
20
+
21
+ class GitDiffUnstaged(BaseModel):
22
+ repo_path: str
23
+
24
+ class GitDiffStaged(BaseModel):
25
+ repo_path: str
26
+
27
+ class GitDiff(BaseModel):
28
+ repo_path: str
29
+ target: str
30
+
31
+ class GitCommit(BaseModel):
32
+ repo_path: str
33
+ message: str
34
+
35
+ class GitAdd(BaseModel):
36
+ repo_path: str
37
+ files: list[str]
38
+
39
+ class GitReset(BaseModel):
40
+ repo_path: str
41
+
42
+ class GitLog(BaseModel):
43
+ repo_path: str
44
+ max_count: int = 10
45
+
46
+ class GitCreateBranch(BaseModel):
47
+ repo_path: str
48
+ branch_name: str
49
+ base_branch: str | None = None
50
+
51
+ class GitCheckout(BaseModel):
52
+ repo_path: str
53
+ branch_name: str
54
+
55
+ class GitShow(BaseModel):
56
+ repo_path: str
57
+ revision: str
58
+
59
+ class GitTools(str, Enum):
60
+ STATUS = "git_status"
61
+ DIFF_UNSTAGED = "git_diff_unstaged"
62
+ DIFF_STAGED = "git_diff_staged"
63
+ DIFF = "git_diff"
64
+ COMMIT = "git_commit"
65
+ ADD = "git_add"
66
+ RESET = "git_reset"
67
+ LOG = "git_log"
68
+ CREATE_BRANCH = "git_create_branch"
69
+ CHECKOUT = "git_checkout"
70
+ SHOW = "git_show"
71
+
72
+ def git_status(repo: git.Repo) -> str:
73
+ return repo.git.status()
74
+
75
+ def git_diff_unstaged(repo: git.Repo) -> str:
76
+ return repo.git.diff()
77
+
78
+ def git_diff_staged(repo: git.Repo) -> str:
79
+ return repo.git.diff("--cached")
80
+
81
+ def git_diff(repo: git.Repo, target: str) -> str:
82
+ return repo.git.diff(target)
83
+
84
+ def git_commit(repo: git.Repo, message: str) -> str:
85
+ commit = repo.index.commit(message)
86
+ return f"Changes committed successfully with hash {commit.hexsha}"
87
+
88
+ def git_add(repo: git.Repo, files: list[str]) -> str:
89
+ repo.index.add(files)
90
+ return "Files staged successfully"
91
+
92
+ def git_reset(repo: git.Repo) -> str:
93
+ repo.index.reset()
94
+ return "All staged changes reset"
95
+
96
+ def git_log(repo: git.Repo, max_count: int = 10) -> list[str]:
97
+ commits = list(repo.iter_commits(max_count=max_count))
98
+ log = []
99
+ for commit in commits:
100
+ log.append(
101
+ f"Commit: {commit.hexsha}\n"
102
+ f"Author: {commit.author}\n"
103
+ f"Date: {commit.authored_datetime}\n"
104
+ f"Message: {commit.message}\n"
105
+ )
106
+ return log
107
+
108
+ def git_create_branch(repo: git.Repo, branch_name: str, base_branch: str | None = None) -> str:
109
+ if base_branch:
110
+ base = repo.refs[base_branch]
111
+ else:
112
+ base = repo.active_branch
113
+
114
+ repo.create_head(branch_name, base)
115
+ return f"Created branch '{branch_name}' from '{base.name}'"
116
+
117
+ def git_checkout(repo: git.Repo, branch_name: str) -> str:
118
+ repo.git.checkout(branch_name)
119
+ return f"Switched to branch '{branch_name}'"
120
+
121
+ def git_show(repo: git.Repo, revision: str) -> str:
122
+ commit = repo.commit(revision)
123
+ output = [
124
+ f"Commit: {commit.hexsha}\n"
125
+ f"Author: {commit.author}\n"
126
+ f"Date: {commit.authored_datetime}\n"
127
+ f"Message: {commit.message}\n"
128
+ ]
129
+ if commit.parents:
130
+ parent = commit.parents[0]
131
+ diff = parent.diff(commit, create_patch=True)
132
+ else:
133
+ diff = commit.diff(git.NULL_TREE, create_patch=True)
134
+ for d in diff:
135
+ output.append(f"\n--- {d.a_path}\n+++ {d.b_path}\n")
136
+ output.append(d.diff.decode('utf-8'))
137
+ return "".join(output)
138
+
139
+ async def serve(repository: Path | None) -> None:
140
+ logger = logging.getLogger(__name__)
141
+
142
+ if repository is not None:
143
+ try:
144
+ git.Repo(repository)
145
+ logger.info(f"Using repository at {repository}")
146
+ except git.InvalidGitRepositoryError:
147
+ logger.error(f"{repository} is not a valid Git repository")
148
+ return
149
+
150
+ server = Server("mcp-git")
151
+
152
+ @server.list_tools()
153
+ async def list_tools() -> list[Tool]:
154
+ return [
155
+ Tool(
156
+ name=GitTools.STATUS,
157
+ description="Shows the working tree status",
158
+ inputSchema=GitStatus.schema(),
159
+ ),
160
+ Tool(
161
+ name=GitTools.DIFF_UNSTAGED,
162
+ description="Shows changes in the working directory that are not yet staged",
163
+ inputSchema=GitDiffUnstaged.schema(),
164
+ ),
165
+ Tool(
166
+ name=GitTools.DIFF_STAGED,
167
+ description="Shows changes that are staged for commit",
168
+ inputSchema=GitDiffStaged.schema(),
169
+ ),
170
+ Tool(
171
+ name=GitTools.DIFF,
172
+ description="Shows differences between branches or commits",
173
+ inputSchema=GitDiff.schema(),
174
+ ),
175
+ Tool(
176
+ name=GitTools.COMMIT,
177
+ description="Records changes to the repository",
178
+ inputSchema=GitCommit.schema(),
179
+ ),
180
+ Tool(
181
+ name=GitTools.ADD,
182
+ description="Adds file contents to the staging area",
183
+ inputSchema=GitAdd.schema(),
184
+ ),
185
+ Tool(
186
+ name=GitTools.RESET,
187
+ description="Unstages all staged changes",
188
+ inputSchema=GitReset.schema(),
189
+ ),
190
+ Tool(
191
+ name=GitTools.LOG,
192
+ description="Shows the commit logs",
193
+ inputSchema=GitLog.schema(),
194
+ ),
195
+ Tool(
196
+ name=GitTools.CREATE_BRANCH,
197
+ description="Creates a new branch from an optional base branch",
198
+ inputSchema=GitCreateBranch.schema(),
199
+ ),
200
+ Tool(
201
+ name=GitTools.CHECKOUT,
202
+ description="Switches branches",
203
+ inputSchema=GitCheckout.schema(),
204
+ ),
205
+ Tool(
206
+ name=GitTools.SHOW,
207
+ description="Shows the contents of a commit",
208
+ inputSchema=GitShow.schema(),
209
+ )
210
+ ]
211
+
212
+ async def list_repos() -> Sequence[str]:
213
+ async def by_roots() -> Sequence[str]:
214
+ if not isinstance(server.request_context.session, ServerSession):
215
+ raise TypeError("server.request_context.session must be a ServerSession")
216
+
217
+ if not server.request_context.session.check_client_capability(
218
+ ClientCapabilities(roots=RootsCapability())
219
+ ):
220
+ return []
221
+
222
+ roots_result: ListRootsResult = await server.request_context.session.list_roots()
223
+ logger.debug(f"Roots result: {roots_result}")
224
+ repo_paths = []
225
+ for root in roots_result.roots:
226
+ path = root.uri.path
227
+ try:
228
+ git.Repo(path)
229
+ repo_paths.append(str(path))
230
+ except git.InvalidGitRepositoryError:
231
+ pass
232
+ return repo_paths
233
+
234
+ def by_commandline() -> Sequence[str]:
235
+ return [str(repository)] if repository is not None else []
236
+
237
+ cmd_repos = by_commandline()
238
+ root_repos = await by_roots()
239
+ return [*root_repos, *cmd_repos]
240
+
241
+ @server.call_tool()
242
+ async def call_tool(name: str, arguments: dict) -> list[TextContent]:
243
+ repo_path = Path(arguments["repo_path"])
244
+ repo = git.Repo(repo_path)
245
+
246
+ match name:
247
+ case GitTools.STATUS:
248
+ status = git_status(repo)
249
+ return [TextContent(
250
+ type="text",
251
+ text=f"Repository status:\n{status}"
252
+ )]
253
+
254
+ case GitTools.DIFF_UNSTAGED:
255
+ diff = git_diff_unstaged(repo)
256
+ return [TextContent(
257
+ type="text",
258
+ text=f"Unstaged changes:\n{diff}"
259
+ )]
260
+
261
+ case GitTools.DIFF_STAGED:
262
+ diff = git_diff_staged(repo)
263
+ return [TextContent(
264
+ type="text",
265
+ text=f"Staged changes:\n{diff}"
266
+ )]
267
+
268
+ case GitTools.DIFF:
269
+ diff = git_diff(repo, arguments["target"])
270
+ return [TextContent(
271
+ type="text",
272
+ text=f"Diff with {arguments['target']}:\n{diff}"
273
+ )]
274
+
275
+ case GitTools.COMMIT:
276
+ result = git_commit(repo, arguments["message"])
277
+ return [TextContent(
278
+ type="text",
279
+ text=result
280
+ )]
281
+
282
+ case GitTools.ADD:
283
+ result = git_add(repo, arguments["files"])
284
+ return [TextContent(
285
+ type="text",
286
+ text=result
287
+ )]
288
+
289
+ case GitTools.RESET:
290
+ result = git_reset(repo)
291
+ return [TextContent(
292
+ type="text",
293
+ text=result
294
+ )]
295
+
296
+ case GitTools.LOG:
297
+ log = git_log(repo, arguments.get("max_count", 10))
298
+ return [TextContent(
299
+ type="text",
300
+ text="Commit history:\n" + "\n".join(log)
301
+ )]
302
+
303
+ case GitTools.CREATE_BRANCH:
304
+ result = git_create_branch(
305
+ repo,
306
+ arguments["branch_name"],
307
+ arguments.get("base_branch")
308
+ )
309
+ return [TextContent(
310
+ type="text",
311
+ text=result
312
+ )]
313
+
314
+ case GitTools.CHECKOUT:
315
+ result = git_checkout(repo, arguments["branch_name"])
316
+ return [TextContent(
317
+ type="text",
318
+ text=result
319
+ )]
320
+
321
+ case GitTools.SHOW:
322
+ result = git_show(repo, arguments["revision"])
323
+ return [TextContent(
324
+ type="text",
325
+ text=result
326
+ )]
327
+
328
+ case _:
329
+ raise ValueError(f"Unknown tool: {name}")
330
+
331
+ options = server.create_initialization_options()
332
+ async with stdio_server() as (read_stream, write_stream):
333
+ await server.run(read_stream, write_stream, options, raise_exceptions=True)
@@ -0,0 +1,280 @@
1
+ Metadata-Version: 2.4
2
+ Name: mcp-server-git
3
+ Version: 2025.1.14
4
+ Summary: A Model Context Protocol server providing tools to read, search, and manipulate Git repositories programmatically via LLMs
5
+ Author: Anthropic, PBC.
6
+ Maintainer-email: David Soria Parra <davidsp@anthropic.com>
7
+ License: MIT
8
+ License-File: LICENSE
9
+ Keywords: automation,git,llm,mcp
10
+ Classifier: Development Status :: 4 - Beta
11
+ Classifier: Intended Audience :: Developers
12
+ Classifier: License :: OSI Approved :: MIT License
13
+ Classifier: Programming Language :: Python :: 3
14
+ Classifier: Programming Language :: Python :: 3.10
15
+ Requires-Python: >=3.10
16
+ Requires-Dist: click>=8.1.7
17
+ Requires-Dist: gitpython>=3.1.43
18
+ Requires-Dist: mcp>=1.0.0
19
+ Requires-Dist: pydantic>=2.0.0
20
+ Description-Content-Type: text/markdown
21
+
22
+ # mcp-server-git: A git MCP server
23
+
24
+ ## Overview
25
+
26
+ A Model Context Protocol server for Git repository interaction and automation. This server provides tools to read, search, and manipulate Git repositories via Large Language Models.
27
+
28
+ Please note that mcp-server-git is currently in early development. The functionality and available tools are subject to change and expansion as we continue to develop and improve the server.
29
+
30
+ ### Tools
31
+
32
+ 1. `git_status`
33
+ - Shows the working tree status
34
+ - Input:
35
+ - `repo_path` (string): Path to Git repository
36
+ - Returns: Current status of working directory as text output
37
+
38
+ 2. `git_diff_unstaged`
39
+ - Shows changes in working directory not yet staged
40
+ - Input:
41
+ - `repo_path` (string): Path to Git repository
42
+ - Returns: Diff output of unstaged changes
43
+
44
+ 3. `git_diff_staged`
45
+ - Shows changes that are staged for commit
46
+ - Input:
47
+ - `repo_path` (string): Path to Git repository
48
+ - Returns: Diff output of staged changes
49
+
50
+ 4. `git_diff`
51
+ - Shows differences between branches or commits
52
+ - Inputs:
53
+ - `repo_path` (string): Path to Git repository
54
+ - `target` (string): Target branch or commit to compare with
55
+ - Returns: Diff output comparing current state with target
56
+
57
+ 5. `git_commit`
58
+ - Records changes to the repository
59
+ - Inputs:
60
+ - `repo_path` (string): Path to Git repository
61
+ - `message` (string): Commit message
62
+ - Returns: Confirmation with new commit hash
63
+
64
+ 6. `git_add`
65
+ - Adds file contents to the staging area
66
+ - Inputs:
67
+ - `repo_path` (string): Path to Git repository
68
+ - `files` (string[]): Array of file paths to stage
69
+ - Returns: Confirmation of staged files
70
+
71
+ 7. `git_reset`
72
+ - Unstages all staged changes
73
+ - Input:
74
+ - `repo_path` (string): Path to Git repository
75
+ - Returns: Confirmation of reset operation
76
+
77
+ 8. `git_log`
78
+ - Shows the commit logs
79
+ - Inputs:
80
+ - `repo_path` (string): Path to Git repository
81
+ - `max_count` (number, optional): Maximum number of commits to show (default: 10)
82
+ - Returns: Array of commit entries with hash, author, date, and message
83
+
84
+ 9. `git_create_branch`
85
+ - Creates a new branch
86
+ - Inputs:
87
+ - `repo_path` (string): Path to Git repository
88
+ - `branch_name` (string): Name of the new branch
89
+ - `start_point` (string, optional): Starting point for the new branch
90
+ - Returns: Confirmation of branch creation
91
+ 8. `git_checkout`
92
+ - Switches branches
93
+ - Inputs:
94
+ - `repo_path` (string): Path to Git repository
95
+ - `branch_name` (string): Name of branch to checkout
96
+ - Returns: Confirmation of branch switch
97
+ 9. `git_show`
98
+ - Shows the contents of a commit
99
+ - Inputs:
100
+ - `repo_path` (string): Path to Git repository
101
+ - `revision` (string): The revision (commit hash, branch name, tag) to show
102
+ - Returns: Contents of the specified commit
103
+
104
+ ## Installation
105
+
106
+ ### Using uv (recommended)
107
+
108
+ When using [`uv`](https://docs.astral.sh/uv/) no specific installation is needed. We will
109
+ use [`uvx`](https://docs.astral.sh/uv/guides/tools/) to directly run *mcp-server-git*.
110
+
111
+ ### Using PIP
112
+
113
+ Alternatively you can install `mcp-server-git` via pip:
114
+
115
+ ```
116
+ pip install mcp-server-git
117
+ ```
118
+
119
+ After installation, you can run it as a script using:
120
+
121
+ ```
122
+ python -m mcp_server_git
123
+ ```
124
+
125
+ ## Configuration
126
+
127
+ ### Usage with Claude Desktop
128
+
129
+ Add this to your `claude_desktop_config.json`:
130
+
131
+ <details>
132
+ <summary>Using uvx</summary>
133
+
134
+ ```json
135
+ "mcpServers": {
136
+ "git": {
137
+ "command": "uvx",
138
+ "args": ["mcp-server-git", "--repository", "path/to/git/repo"]
139
+ }
140
+ }
141
+ ```
142
+ </details>
143
+
144
+ <details>
145
+ <summary>Using docker</summary>
146
+
147
+ * Note: replace '/Users/username' with the a path that you want to be accessible by this tool
148
+
149
+ ```json
150
+ "mcpServers": {
151
+ "git": {
152
+ "command": "docker",
153
+ "args": ["run", "--rm", "-i", "--mount", "type=bind,src=/Users/username,dst=/Users/username", "mcp/git"]
154
+ }
155
+ }
156
+ ```
157
+ </details>
158
+
159
+ <details>
160
+ <summary>Using pip installation</summary>
161
+
162
+ ```json
163
+ "mcpServers": {
164
+ "git": {
165
+ "command": "python",
166
+ "args": ["-m", "mcp_server_git", "--repository", "path/to/git/repo"]
167
+ }
168
+ }
169
+ ```
170
+ </details>
171
+
172
+ ### Usage with [Zed](https://github.com/zed-industries/zed)
173
+
174
+ Add to your Zed settings.json:
175
+
176
+ <details>
177
+ <summary>Using uvx</summary>
178
+
179
+ ```json
180
+ "context_servers": [
181
+ "mcp-server-git": {
182
+ "command": {
183
+ "path": "uvx",
184
+ "args": ["mcp-server-git"]
185
+ }
186
+ }
187
+ ],
188
+ ```
189
+ </details>
190
+
191
+ <details>
192
+ <summary>Using pip installation</summary>
193
+
194
+ ```json
195
+ "context_servers": {
196
+ "mcp-server-git": {
197
+ "command": {
198
+ "path": "python",
199
+ "args": ["-m", "mcp_server_git"]
200
+ }
201
+ }
202
+ },
203
+ ```
204
+ </details>
205
+
206
+ ## Debugging
207
+
208
+ You can use the MCP inspector to debug the server. For uvx installations:
209
+
210
+ ```
211
+ npx @modelcontextprotocol/inspector uvx mcp-server-git
212
+ ```
213
+
214
+ Or if you've installed the package in a specific directory or are developing on it:
215
+
216
+ ```
217
+ cd path/to/servers/src/git
218
+ npx @modelcontextprotocol/inspector uv run mcp-server-git
219
+ ```
220
+
221
+ Running `tail -n 20 -f ~/Library/Logs/Claude/mcp*.log` will show the logs from the server and may
222
+ help you debug any issues.
223
+
224
+ ## Development
225
+
226
+ If you are doing local development, there are two ways to test your changes:
227
+
228
+ 1. Run the MCP inspector to test your changes. See [Debugging](#debugging) for run instructions.
229
+
230
+ 2. Test using the Claude desktop app. Add the following to your `claude_desktop_config.json`:
231
+
232
+ ### Docker
233
+
234
+ ```json
235
+ {
236
+ "mcpServers": {
237
+ "git": {
238
+ "command": "docker",
239
+ "args": [
240
+ "run",
241
+ "--rm",
242
+ "-i",
243
+ "--mount", "type=bind,src=/Users/username/Desktop,dst=/projects/Desktop",
244
+ "--mount", "type=bind,src=/path/to/other/allowed/dir,dst=/projects/other/allowed/dir,ro",
245
+ "--mount", "type=bind,src=/path/to/file.txt,dst=/projects/path/to/file.txt",
246
+ "mcp/git"
247
+ ]
248
+ }
249
+ }
250
+ }
251
+ ```
252
+
253
+ ### UVX
254
+ ```json
255
+ {
256
+ "mcpServers": {
257
+ "git": {
258
+ "command": "uv",
259
+ "args": [
260
+ "--directory",
261
+ "/<path to mcp-servers>/mcp-servers/src/git",
262
+ "run",
263
+ "mcp-server-git"
264
+ ]
265
+ }
266
+ }
267
+ ```
268
+
269
+ ## Build
270
+
271
+ Docker build:
272
+
273
+ ```bash
274
+ cd src/git
275
+ docker build -t mcp/git .
276
+ ```
277
+
278
+ ## License
279
+
280
+ This MCP server is licensed under the MIT License. This means you are free to use, modify, and distribute the software, subject to the terms and conditions of the MIT License. For more details, please see the LICENSE file in the project repository.
@@ -0,0 +1,8 @@
1
+ mcp_server_git/__init__.py,sha256=u1kAH2ucvcRXgB_DMrxPFIppcBWzC6x2XKRc-COuCSs,650
2
+ mcp_server_git/__main__.py,sha256=hsKGEXubWAgg4lB38E1tKJ3ZZp8FOFK8W1CT0-i8SR8,55
3
+ mcp_server_git/server.py,sha256=aadPvauUkRge-KwT-GliOXzxuUz0ibeMQjU5DJVlzZM,10335
4
+ mcp_server_git-2025.1.14.dist-info/METADATA,sha256=M6BIbq00bvUF_fBJk_rWktrgqrREhGH4lP2I2Qg0FDI,7081
5
+ mcp_server_git-2025.1.14.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
6
+ mcp_server_git-2025.1.14.dist-info/entry_points.txt,sha256=lNDfXZzZdY33F_H2B1kgXXeORLmy5YYmrFfbDAoy4DY,55
7
+ mcp_server_git-2025.1.14.dist-info/licenses/LICENSE,sha256=jMfG4zsk7U7o_MzDPszxAlSdBPpMuXN87Ml3Da0QgP8,1059
8
+ mcp_server_git-2025.1.14.dist-info/RECORD,,
@@ -0,0 +1,4 @@
1
+ Wheel-Version: 1.0
2
+ Generator: hatchling 1.27.0
3
+ Root-Is-Purelib: true
4
+ Tag: py3-none-any
@@ -0,0 +1,2 @@
1
+ [console_scripts]
2
+ mcp-server-git = mcp_server_git:main
@@ -0,0 +1,7 @@
1
+ Copyright (c) 2024 Anthropic, PBC.
2
+
3
+ Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
4
+
5
+ The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
6
+
7
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.