cairn-code 0.3.7__py3-none-macosx_10_12_x86_64.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.
cairn_code/__init__.py ADDED
@@ -0,0 +1 @@
1
+ """The cairn-code PyPI package: the release binary plus the `cairn` launcher."""
cairn_code/__main__.py ADDED
@@ -0,0 +1,40 @@
1
+ """The `cairn` command of the cairn-code PyPI package.
2
+
3
+ Each platform wheel carries one release binary in cairn_code/bin. This
4
+ launcher runs it.
5
+ """
6
+
7
+ import os
8
+ import subprocess
9
+ import sys
10
+ from pathlib import Path
11
+
12
+
13
+ def main() -> None:
14
+ name = "cairn.exe" if sys.platform == "win32" else "cairn"
15
+ binary = Path(__file__).resolve().parent / "bin" / name
16
+ if not binary.is_file():
17
+ sys.exit(f"cairn-code: {binary} is missing. Reinstall cairn-code.")
18
+
19
+ env = dict(os.environ)
20
+ # The package manager owns this copy. A background self-update would
21
+ # rewrite the binary inside site-packages behind its back, so it is off
22
+ # unless the user set the variable themselves.
23
+ env.setdefault("CAIRN_NO_AUTO_UPDATE", "1")
24
+
25
+ argv = [str(binary), *sys.argv[1:]]
26
+ if sys.platform == "win32":
27
+ # Windows has no exec that keeps the console's process identity, so
28
+ # wait for the child and pass its exit code on. Ctrl+C reaches the
29
+ # child through the shared console; the launcher just keeps waiting.
30
+ child = subprocess.Popen(argv, env=env)
31
+ while True:
32
+ try:
33
+ sys.exit(child.wait())
34
+ except KeyboardInterrupt:
35
+ continue
36
+ os.execve(argv[0], argv, env)
37
+
38
+
39
+ if __name__ == "__main__":
40
+ main()
cairn_code/bin/cairn ADDED
Binary file
@@ -0,0 +1,99 @@
1
+ Metadata-Version: 2.4
2
+ Name: cairn-code
3
+ Version: 0.3.7
4
+ Summary: Terminal coding agent
5
+ License-Expression: LicenseRef-Proprietary
6
+ License-File: LICENSE
7
+ Project-URL: Homepage, https://github.com/cairn/cairn
8
+ Project-URL: Issues, https://github.com/cairn/cairn/issues
9
+ Requires-Python: >=3.8
10
+ Description-Content-Type: text/markdown
11
+
12
+ <p align="center">
13
+ <img src="https://raw.githubusercontent.com/cairn/cairn/main/banner.png" alt="Cairn" width="560">
14
+ </p>
15
+
16
+ # Cairn
17
+
18
+ <p align="center">
19
+ <strong>English</strong> | <a href="https://github.com/cairn/cairn/blob/main/README_ZH.md">中文</a>
20
+ </p>
21
+
22
+ > **Official distribution:** Cairn is distributed only from this GitHub repository, through the Releases page and the install scripts below, through Cairn's official Homebrew tap (`brew tap cairn/tap`, then `brew install cairn`), and on npm as [`cairn-code`](https://www.npmjs.com/package/cairn-code) (0.3.6 and later). It is not published on any other package manager. Any other package using the Cairn name is unofficial, unrelated to this project, and not endorsed by Cairn.
23
+
24
+ A terminal-based coding agent, built by Cairn.
25
+
26
+ Cairn runs on macOS, Linux, and Windows. It lives in your terminal and works across multiple LLM providers, reading files, writing and editing code, running shell commands, and searching your codebase to carry out a task from a natural-language instruction.
27
+
28
+ ## Features
29
+
30
+ - **Multi-provider LLM support**: Anthropic, OpenAI, OpenRouter, SpaceXSI, and local models via Ollama, switchable per session
31
+ - **Agentic tool loop**: reads files, writes and edits code, runs shell commands, and searches the codebase autonomously until the task is done
32
+ - **Skills + MCP**: on-demand skill packs and Model Context Protocol server support
33
+ - **Real-time streaming**: token-by-token output with live tool activity and thinking display
34
+ - **Terminal UI**: a fast, keyboard-driven interface with provider/model pickers and syntax-highlighted code
35
+ - **Cost tracking**: per-session and per-call token usage
36
+ - **Permission system**: configurable auto-approve, ask, and deny rules per tool
37
+ - **Self-updating**: built-in `cairn update` command to stay on the latest version
38
+ - **Non-interactive mode**: scriptable, pipeline-friendly execution
39
+
40
+ ## Get started
41
+
42
+ Install the latest release binary:
43
+
44
+ ```sh
45
+ curl -fsSL https://raw.githubusercontent.com/cairn/cairn/v0.3.6/install.sh | sh
46
+ ```
47
+
48
+ > **Note:** The version tag in the URL above is pinned for security.
49
+
50
+ On Windows, in PowerShell:
51
+
52
+ ```powershell
53
+ irm https://raw.githubusercontent.com/cairn/cairn/v0.3.6/install.ps1 | iex
54
+ ```
55
+
56
+ > **Note:** The version tag in that URL is pinned the same way.
57
+
58
+ With Bun or npm:
59
+
60
+ ```sh
61
+ bun add -g cairn-code # or: npm install -g cairn-code
62
+ ```
63
+
64
+ Or download binaries directly from the [Releases](https://github.com/cairn/cairn/releases) page:
65
+ - **macOS (Apple Silicon)**: `cairn-code-macos-aarch64`
66
+ - **macOS (Intel)**: `cairn-code-macos-x86_64`
67
+ - **Linux (x86_64)**: `cairn-code-linux-x86_64`
68
+ - **Linux (ARM64)**: `cairn-code-linux-aarch64`
69
+ - **Windows (x86_64)**: `cairn-code-windows-x86_64.exe`
70
+
71
+ The install script and the Homebrew formula also link the binary as `agent`, so `agent` runs Cairn too. The link is only made when that name is free in the install directory; an existing `agent` belonging to another tool is left untouched.
72
+
73
+ ## Updating
74
+
75
+ Run the built-in update command:
76
+
77
+ ```sh
78
+ cairn update
79
+ ```
80
+
81
+ If you installed with Bun or npm, update through the package manager instead (`bun update -g cairn-code`).
82
+
83
+ ## Documentation
84
+
85
+ See the [wiki](https://github.com/cairn/cairn/wiki) to get started, and for commands and configuration.
86
+
87
+ ## Feedback & bug reports
88
+
89
+ This repository does not host Cairn's source. Use [GitHub Issues](https://github.com/cairn/cairn/issues) to report a bug, request a feature, or share feedback.
90
+
91
+ ## License
92
+
93
+ Proprietary. All rights reserved. See [LICENSE](https://github.com/cairn/cairn/blob/main/LICENSE).
94
+
95
+ This is not open source. Cairn's source is not published in this repository, and nothing here licenses that source for use, modification, or distribution.
96
+
97
+ You may download the published release binaries and run them on your own machine. That is written permission to copy those binaries onto your computer and to use them. It does not grant any other right.
98
+
99
+ © euxarist 2026. All rights reserved.
@@ -0,0 +1,8 @@
1
+ cairn_code/__init__.py,sha256=MKRt7cgR02QgVAVfNaF8VqAaNNGIgchNsTK8UzIis7Y,81
2
+ cairn_code/__main__.py,sha256=SSWvhIE18Jw-SWH_Q3n4DhGVE8oiJ-G9wNfHOffJWNs,1302
3
+ cairn_code/bin/cairn,sha256=_6QstCnrkXo5JzXHUBAzjWNvuPukDrLiOdF_a6_mCec,10123496
4
+ cairn_code-0.3.7.dist-info/entry_points.txt,sha256=63udhyKMdusmAQIDsS0rqZy7wP2K7c7GyI943bTdIHE,51
5
+ cairn_code-0.3.7.dist-info/METADATA,sha256=vV6sYWjc-cKx4YImIaPO5bpT0xSvJrjag3XTO-xlIeg,4318
6
+ cairn_code-0.3.7.dist-info/WHEEL,sha256=0rGw42EJs0E0XH73nL3bIiCMaJfqCL6AFrNb9xXx3gI,115
7
+ cairn_code-0.3.7.dist-info/licenses/LICENSE,sha256=TYUZdZl_r9UJ4mCz4TaH4ymgf_KCu5_OCp6qRYo218E,4739
8
+ cairn_code-0.3.7.dist-info/RECORD,,
@@ -0,0 +1,4 @@
1
+ Wheel-Version: 1.0
2
+ Generator: cairn-code pypi/assemble.py
3
+ Root-Is-Purelib: false
4
+ Tag: py3-none-macosx_10_12_x86_64
@@ -0,0 +1,2 @@
1
+ [console_scripts]
2
+ cairn = cairn_code.__main__:main
@@ -0,0 +1,105 @@
1
+ Cairn Code
2
+
3
+ Copyright © euxarist 2026. All rights reserved.
4
+
5
+ 1. Ownership
6
+
7
+ This software, including its source code, documentation, configuration,
8
+ assets, and any accompanying materials (together, the "Software"), is the
9
+ property of the copyright holder. It is protected by copyright law and by
10
+ international treaties. All right, title, and interest in and to the
11
+ Software, including all intellectual property rights, remain with the
12
+ copyright holder.
13
+
14
+ 2. No licence granted
15
+
16
+ No licence, express or implied, is granted by this file or by the
17
+ availability of the Software in any location, including a public source
18
+ repository. Publishing the Software where it can be read does not place it
19
+ in the public domain, does not make it open source, and does not grant any
20
+ right beyond those stated in section 3.
21
+
22
+ 3. Permitted use
23
+
24
+ You may view the Software, and you may make the copies that your platform
25
+ or client creates automatically in the ordinary course of viewing it.
26
+
27
+ Distribution of the Software is reserved exclusively to the copyright
28
+ holder, and the Software is made available only through the copyright
29
+ holder's official channels: the releases published in the cairn/cairn
30
+ GitHub repository and the cairn/tap Homebrew tap. No other person may distribute, publish, or
31
+ otherwise make the Software available, in whole or in part, through any
32
+ package manager, package repository, mirror, or other channel; this
33
+ paragraph grants no right, and section 3(b) applies to every other person
34
+ without exception.
35
+
36
+ Any other act reserved to the copyright holder requires that holder's prior
37
+ written permission. Without it you may not:
38
+
39
+ a. use the Software, in whole or in part, for any purpose, including
40
+ personal, internal, educational, evaluative, or commercial purposes;
41
+
42
+ b. reproduce, publish, distribute, sublicense, sell, rent, lease, or
43
+ otherwise transfer the Software or any copy of it;
44
+
45
+ c. modify, adapt, translate, or create derivative works based on the
46
+ Software;
47
+
48
+ d. incorporate the Software, or any portion of it, into another work,
49
+ including a work distributed under an open-source licence;
50
+
51
+ e. use the Software, or any portion of it, as training data, or as input to
52
+ the training, fine-tuning, or evaluation of any machine learning model;
53
+
54
+ f. reverse engineer, decompile, or disassemble any compiled form of the
55
+ Software, except to the extent that this restriction is expressly
56
+ prohibited by applicable law; or
57
+
58
+ g. remove, obscure, or alter any copyright, trademark, or other proprietary
59
+ notice contained in the Software.
60
+
61
+ 4. Contributions
62
+
63
+ A contribution submitted to this project, by any means including a pull
64
+ request, patch, or issue attachment, is offered to the copyright holder on
65
+ a non-exclusive, perpetual, irrevocable, worldwide, royalty-free basis, with
66
+ the right to use, reproduce, modify, distribute, and sublicense it as part
67
+ of the Software. You represent that you are entitled to grant that, and that
68
+ your contribution does not infringe the rights of any third party. No
69
+ contribution creates any ownership interest in the Software.
70
+
71
+ 5. Third-party components
72
+
73
+ The Software depends on third-party components that are separately licensed
74
+ by their respective owners. Nothing in this file alters, restricts, or
75
+ supersedes the terms of those licences, and nothing in this file asserts
76
+ ownership over those components. Their terms govern their own use.
77
+
78
+ 6. No warranty
79
+
80
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
81
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
82
+ FITNESS FOR A PARTICULAR PURPOSE, TITLE, AND NONINFRINGEMENT.
83
+
84
+ 7. Limitation of liability
85
+
86
+ TO THE MAXIMUM EXTENT PERMITTED BY APPLICABLE LAW, IN NO EVENT SHALL THE
87
+ COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES, OR OTHER LIABILITY,
88
+ WHETHER IN AN ACTION OF CONTRACT, TORT, OR OTHERWISE, ARISING FROM, OUT OF,
89
+ OR IN CONNECTION WITH THE SOFTWARE OR THE USE OF OR OTHER DEALINGS IN THE
90
+ SOFTWARE.
91
+
92
+ The Software executes commands, edits files, and sends data to third-party
93
+ services at the direction of a language model. The copyright holder accepts
94
+ no liability for any action it takes or for any consequence of that action.
95
+
96
+ 8. Reservation
97
+
98
+ All rights not expressly granted in this file are reserved. No waiver of any
99
+ provision is effective unless made in writing by the copyright holder, and
100
+ no failure to enforce a provision waives it.
101
+
102
+ 9. Enquiries
103
+
104
+ Requests for a licence, or any other permission under this file, should be
105
+ directed to the copyright holder through this repository.