giton 0.1.5__tar.gz → 0.1.6__tar.gz
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.
- {giton-0.1.5 → giton-0.1.6}/.gitignore +30 -0
- {giton-0.1.5 → giton-0.1.6}/CHANGELOG.md +75 -0
- {giton-0.1.5 → giton-0.1.6}/PKG-INFO +95 -4
- {giton-0.1.5 → giton-0.1.6}/README.md +94 -3
- giton-0.1.6/SUMD.md +805 -0
- giton-0.1.6/SUMR.md +739 -0
- giton-0.1.6/TODO.md +93 -0
- giton-0.1.6/VERSION +1 -0
- giton-0.1.6/app.doql.less +28 -0
- {giton-0.1.5 → giton-0.1.6}/goal.yaml +2 -2
- giton-0.1.6/planfile.yaml +526 -0
- giton-0.1.6/prefact.yaml +94 -0
- giton-0.1.6/project/README.md +340 -0
- giton-0.1.6/project/analysis.toon.yaml +162 -0
- giton-0.1.6/project/calls.mmd +133 -0
- giton-0.1.6/project/calls.png +0 -0
- giton-0.1.6/project/calls.toon.yaml +169 -0
- giton-0.1.6/project/calls.yaml +765 -0
- giton-0.1.6/project/compact_flow.mmd +7 -0
- giton-0.1.6/project/compact_flow.png +0 -0
- giton-0.1.6/project/context.md +420 -0
- giton-0.1.6/project/duplication.toon.yaml +49 -0
- giton-0.1.6/project/evolution.toon.yaml +49 -0
- giton-0.1.6/project/flow.mmd +26 -0
- giton-0.1.6/project/flow.png +0 -0
- giton-0.1.6/project/index.html +624 -0
- giton-0.1.6/project/logic.pl +210 -0
- giton-0.1.6/project/map.toon.yaml +208 -0
- giton-0.1.6/project/mermaid.export +151 -0
- giton-0.1.6/project/planfile-tickets.yaml +444 -0
- giton-0.1.6/project/project.toon.yaml +57 -0
- giton-0.1.6/project/prompt.txt +50 -0
- giton-0.1.6/project.sh +59 -0
- {giton-0.1.5 → giton-0.1.6}/pyproject.toml +1 -1
- {giton-0.1.5 → giton-0.1.6}/src/giton/__init__.py +1 -1
- giton-0.1.6/testql-scenarios/generated-cli-tests.testql.toon.yaml +20 -0
- giton-0.1.6/testql-scenarios/generated-from-pytests.testql.toon.yaml +13 -0
- giton-0.1.6/tree.sh +1 -0
- {giton-0.1.5 → giton-0.1.6}/uv.lock +1 -1
- giton-0.1.5/TODO.md +0 -297
- giton-0.1.5/VERSION +0 -1
- {giton-0.1.5 → giton-0.1.6}/.idea/.gitignore +0 -0
- {giton-0.1.5 → giton-0.1.6}/.idea/workspace.xml +0 -0
- {giton-0.1.5 → giton-0.1.6}/.koru/event-store.jsonl +0 -0
- {giton-0.1.5 → giton-0.1.6}/.koru/events/observability.jsonl +0 -0
- {giton-0.1.5 → giton-0.1.6}/.koru/history.jsonl +0 -0
- {giton-0.1.5 → giton-0.1.6}/.koru/onboarding.json +0 -0
- {giton-0.1.5 → giton-0.1.6}/.koru/project.json +0 -0
- {giton-0.1.5 → giton-0.1.6}/.planfile/.koru/autonomous-state.json +0 -0
- {giton-0.1.5 → giton-0.1.6}/.planfile/.koru/autonomy-telemetry.json +0 -0
- {giton-0.1.5 → giton-0.1.6}/.planfile/.koru/event-store.jsonl +0 -0
- {giton-0.1.5 → giton-0.1.6}/.planfile/.koru/nfo-events.jsonl +0 -0
- {giton-0.1.5 → giton-0.1.6}/.planfile/.koru/operator-steps/mcp_koru.ticket +0 -0
- {giton-0.1.5 → giton-0.1.6}/.planfile/.koru/operator-steps/self_control.ticket +0 -0
- {giton-0.1.5 → giton-0.1.6}/.planfile/.koru/queue-runner.lock +0 -0
- {giton-0.1.5 → giton-0.1.6}/.planfile/.koru/serve-endpoint.json +0 -0
- {giton-0.1.5 → giton-0.1.6}/.planfile/config.yaml +0 -0
- {giton-0.1.5 → giton-0.1.6}/.planfile/sprints/current.yaml +0 -0
- {giton-0.1.5 → giton-0.1.6}/.planfile/sprints/current.yaml.lock +0 -0
- {giton-0.1.5 → giton-0.1.6}/LICENSE +0 -0
- {giton-0.1.5 → giton-0.1.6}/examples/advanced/Dockerfile +0 -0
- {giton-0.1.5 → giton-0.1.6}/examples/advanced/README.md +0 -0
- {giton-0.1.5 → giton-0.1.6}/examples/advanced/logs/log.txt +0 -0
- {giton-0.1.5 → giton-0.1.6}/examples/advanced/main.py +0 -0
- {giton-0.1.5 → giton-0.1.6}/examples/basic/Dockerfile +0 -0
- {giton-0.1.5 → giton-0.1.6}/examples/basic/README.md +0 -0
- {giton-0.1.5 → giton-0.1.6}/examples/basic/logs/log.txt +0 -0
- {giton-0.1.5 → giton-0.1.6}/examples/basic/main.py +0 -0
- {giton-0.1.5 → giton-0.1.6}/examples/testing/Dockerfile +0 -0
- {giton-0.1.5 → giton-0.1.6}/examples/testing/README.md +0 -0
- {giton-0.1.5 → giton-0.1.6}/examples/testing/docker-compose.yml +0 -0
- {giton-0.1.5 → giton-0.1.6}/examples/testing/logs/log.txt +0 -0
- {giton-0.1.5 → giton-0.1.6}/examples/testing/sample_project/pyproject.toml +0 -0
- {giton-0.1.5 → giton-0.1.6}/examples/testing/sample_project/src/example.py +0 -0
- {giton-0.1.5 → giton-0.1.6}/examples/testing/sample_project/tests/test_example.py +0 -0
- {giton-0.1.5 → giton-0.1.6}/examples/testing/test_giton_integration.py +0 -0
- {giton-0.1.5 → giton-0.1.6}/koru.yaml +0 -0
- {giton-0.1.5 → giton-0.1.6}/src/giton/__main__.py +0 -0
- {giton-0.1.5 → giton-0.1.6}/src/giton/catalog.py +0 -0
- {giton-0.1.5 → giton-0.1.6}/src/giton/cli.py +0 -0
- {giton-0.1.5 → giton-0.1.6}/src/giton/config.py +0 -0
- {giton-0.1.5 → giton-0.1.6}/src/giton/context.py +0 -0
- {giton-0.1.5 → giton-0.1.6}/src/giton/history.py +0 -0
- {giton-0.1.5 → giton-0.1.6}/src/giton/hooks.py +0 -0
- {giton-0.1.5 → giton-0.1.6}/src/giton/interactive.py +0 -0
- {giton-0.1.5 → giton-0.1.6}/src/giton/plugins.py +0 -0
- {giton-0.1.5 → giton-0.1.6}/src/giton/policies.py +0 -0
- {giton-0.1.5 → giton-0.1.6}/src/giton/repo_config.py +0 -0
- {giton-0.1.5 → giton-0.1.6}/src/giton/runner.py +0 -0
- {giton-0.1.5 → giton-0.1.6}/src/giton/shell.py +0 -0
- {giton-0.1.5 → giton-0.1.6}/tests/__init__.py +0 -0
- {giton-0.1.5 → giton-0.1.6}/tests/test_basic.py +0 -0
- {giton-0.1.5 → giton-0.1.6}/tests/test_history.py +0 -0
- {giton-0.1.5 → giton-0.1.6}/tests/test_policies.py +0 -0
|
@@ -1,4 +1,34 @@
|
|
|
1
1
|
# Byte-compiled / optimized / DLL files
|
|
2
|
+
.code2llm_cache/Dockerfile_1779904106733599983_1063.pkl
|
|
3
|
+
.code2llm_cache/Dockerfile_1779904204018542516_855.pkl
|
|
4
|
+
.code2llm_cache/Dockerfile_1779904222125718170_858.pkl
|
|
5
|
+
.code2llm_cache/__init___1779904484527861301_88.pkl
|
|
6
|
+
.code2llm_cache/__main___1779903461855440523_64.pkl
|
|
7
|
+
.code2llm_cache/catalog_1779903467942497517_4931.pkl
|
|
8
|
+
.code2llm_cache/cli_1779904308177553774_14209.pkl
|
|
9
|
+
.code2llm_cache/config_1779903467956497648_2190.pkl
|
|
10
|
+
.code2llm_cache/context_1779903467968497760_1979.pkl
|
|
11
|
+
.code2llm_cache/docker-compose_1779904015273715995_275.pkl
|
|
12
|
+
.code2llm_cache/example_1779904015363716864_377.pkl
|
|
13
|
+
.code2llm_cache/goal_1779904328814754362_12299.pkl
|
|
14
|
+
.code2llm_cache/history_1779904418550627319_3990.pkl
|
|
15
|
+
.code2llm_cache/hooks_1779904204594548103_1494.pkl
|
|
16
|
+
.code2llm_cache/interactive_1779903895476561902_1596.pkl
|
|
17
|
+
.code2llm_cache/koru_1779902061609676056_4752.pkl
|
|
18
|
+
.code2llm_cache/log_1779904164924163504_984.pkl
|
|
19
|
+
.code2llm_cache/log_1779904220074802878_277.pkl
|
|
20
|
+
.code2llm_cache/log_1779904238033879625_1632.pkl
|
|
21
|
+
.code2llm_cache/main_1779903932664919651_5066.pkl
|
|
22
|
+
.code2llm_cache/main_1779904024396804070_2151.pkl
|
|
23
|
+
.code2llm_cache/plugins_1779903461882440775_3639.pkl
|
|
24
|
+
.code2llm_cache/policies_1779904211790617903_4935.pkl
|
|
25
|
+
.code2llm_cache/project_1779639049507316391_1734.pkl
|
|
26
|
+
.code2llm_cache/pyproject_1779904015449717694_223.pkl
|
|
27
|
+
.code2llm_cache/pyproject_1779904484379748658_1384.pkl
|
|
28
|
+
.code2llm_cache/repo_config_1779904232535819185_3184.pkl
|
|
29
|
+
.code2llm_cache/runner_1779903923548831909_3654.pkl
|
|
30
|
+
.code2llm_cache/shell_1779903980013375824_6902.pkl
|
|
31
|
+
.code2llm_cache/tree_1777298880917790642_186.pkl
|
|
2
32
|
.idea/misc.xml
|
|
3
33
|
.idea/.name
|
|
4
34
|
.idea/giton.iml
|
|
@@ -5,8 +5,83 @@ All notable changes to this project will be documented in this file.
|
|
|
5
5
|
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
|
|
6
6
|
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
|
7
7
|
|
|
8
|
+
## [0.1.10] - 2026-05-27
|
|
9
|
+
|
|
10
|
+
### Fixed
|
|
11
|
+
- Fix string-concat issues (ticket-f8e33603)
|
|
12
|
+
- Fix smart-return-type issues (ticket-5241a23f)
|
|
13
|
+
- Fix unused-imports issues (ticket-678976ed)
|
|
14
|
+
- Fix ai-boilerplate issues (ticket-f1340096)
|
|
15
|
+
- Fix smart-return-type issues (ticket-cf388d88)
|
|
16
|
+
- Fix unused-imports issues (ticket-ef62ed06)
|
|
17
|
+
- Fix ai-boilerplate issues (ticket-c9e99715)
|
|
18
|
+
- Fix smart-return-type issues (ticket-25895170)
|
|
19
|
+
- Fix llm-hallucinations issues (ticket-d5864acf)
|
|
20
|
+
- Fix ai-boilerplate issues (ticket-22c7a20b)
|
|
21
|
+
|
|
22
|
+
## [0.1.10] - 2026-05-27
|
|
23
|
+
|
|
24
|
+
### Fixed
|
|
25
|
+
- Fix ai-boilerplate issues (ticket-520cc8b0)
|
|
26
|
+
- Fix unused-imports issues (ticket-d9ba49df)
|
|
27
|
+
- Fix smart-return-type issues (ticket-a078f21e)
|
|
28
|
+
- Fix unused-imports issues (ticket-6bb663ef)
|
|
29
|
+
- Fix magic-numbers issues (ticket-670a4fff)
|
|
30
|
+
- Fix ai-boilerplate issues (ticket-7b75c64a)
|
|
31
|
+
- Fix unused-imports issues (ticket-7f7595f5)
|
|
32
|
+
- Fix unused-imports issues (ticket-7836e6dc)
|
|
33
|
+
- Fix magic-numbers issues (ticket-364cdbb4)
|
|
34
|
+
- Fix unused-imports issues (ticket-3df4999d)
|
|
35
|
+
- Fix string-concat issues (ticket-ddefd20d)
|
|
36
|
+
- Fix unused-imports issues (ticket-37e354ce)
|
|
37
|
+
- Fix string-concat issues (ticket-0959072c)
|
|
38
|
+
- Fix unused-imports issues (ticket-cbff985c)
|
|
39
|
+
- Fix unused-imports issues (ticket-d9544d1d)
|
|
40
|
+
- Fix magic-numbers issues (ticket-01a9b257)
|
|
41
|
+
- Fix unused-imports issues (ticket-bf9e08bd)
|
|
42
|
+
- Fix unused-imports issues (ticket-dc102598)
|
|
43
|
+
- Fix magic-numbers issues (ticket-0afc68c7)
|
|
44
|
+
- Fix smart-return-type issues (ticket-a5264d97)
|
|
45
|
+
- Fix unused-imports issues (ticket-97fe62d8)
|
|
46
|
+
- Fix string-concat issues (ticket-07df1cf8)
|
|
47
|
+
- Fix unused-imports issues (ticket-9135e71a)
|
|
48
|
+
- Fix unused-imports issues (ticket-580c65b2)
|
|
49
|
+
- Fix magic-numbers issues (ticket-f6e8663e)
|
|
50
|
+
- Fix smart-return-type issues (ticket-b5dc313c)
|
|
51
|
+
- Fix unused-imports issues (ticket-e85782ed)
|
|
52
|
+
- Fix smart-return-type issues (ticket-bbf11608)
|
|
53
|
+
- Fix unused-imports issues (ticket-61cab342)
|
|
54
|
+
|
|
8
55
|
## [Unreleased]
|
|
9
56
|
|
|
57
|
+
## [0.1.6] - 2026-05-27
|
|
58
|
+
|
|
59
|
+
### Docs
|
|
60
|
+
- Update CHANGELOG.md
|
|
61
|
+
- Update README.md
|
|
62
|
+
- Update SUMD.md
|
|
63
|
+
- Update SUMR.md
|
|
64
|
+
- Update TODO.md
|
|
65
|
+
- Update project/README.md
|
|
66
|
+
- Update project/context.md
|
|
67
|
+
|
|
68
|
+
### Test
|
|
69
|
+
- Update testql-scenarios/generated-cli-tests.testql.toon.yaml
|
|
70
|
+
- Update testql-scenarios/generated-from-pytests.testql.toon.yaml
|
|
71
|
+
|
|
72
|
+
### Other
|
|
73
|
+
- Update .code2llm_cache/Dockerfile_1779904106733599983_1063.pkl
|
|
74
|
+
- Update .code2llm_cache/Dockerfile_1779904204018542516_855.pkl
|
|
75
|
+
- Update .code2llm_cache/Dockerfile_1779904222125718170_858.pkl
|
|
76
|
+
- Update .code2llm_cache/__init___1779904484527861301_88.pkl
|
|
77
|
+
- Update .code2llm_cache/__main___1779903461855440523_64.pkl
|
|
78
|
+
- Update .code2llm_cache/catalog_1779903467942497517_4931.pkl
|
|
79
|
+
- Update .code2llm_cache/cli_1779904308177553774_14209.pkl
|
|
80
|
+
- Update .code2llm_cache/config_1779903467956497648_2190.pkl
|
|
81
|
+
- Update .code2llm_cache/context_1779903467968497760_1979.pkl
|
|
82
|
+
- Update .code2llm_cache/docker-compose_1779904015273715995_275.pkl
|
|
83
|
+
- ... and 43 more files
|
|
84
|
+
|
|
10
85
|
## [0.1.5] - 2026-05-27
|
|
11
86
|
|
|
12
87
|
### Docs
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: giton
|
|
3
|
-
Version: 0.1.
|
|
3
|
+
Version: 0.1.6
|
|
4
4
|
Summary: Local AI layer for git: orchestrates policies & plugins between commit and push.
|
|
5
5
|
Author: semcod
|
|
6
6
|
Author-email: Tom Sapletta <tom@sapletta.com>
|
|
@@ -22,11 +22,11 @@ Description-Content-Type: text/markdown
|
|
|
22
22
|
|
|
23
23
|
## AI Cost Tracking
|
|
24
24
|
|
|
25
|
-
    
|
|
26
26
|
  
|
|
27
27
|
|
|
28
|
-
- 🤖 **LLM usage:** $0.
|
|
29
|
-
- 👤 **Human dev:** ~$
|
|
28
|
+
- 🤖 **LLM usage:** $0.6135 (9 commits)
|
|
29
|
+
- 👤 **Human dev:** ~$319 (3.2h @ $100/h, 30min dedup)
|
|
30
30
|
|
|
31
31
|
Generated on 2026-05-27 using [openrouter/qwen/qwen3-coder-next](https://openrouter.ai/qwen/qwen3-coder-next)
|
|
32
32
|
|
|
@@ -99,6 +99,97 @@ giton: Apply patch and add commit "fixup! ..."? [Y/n]
|
|
|
99
99
|
pip install giton
|
|
100
100
|
```
|
|
101
101
|
|
|
102
|
+
## Development
|
|
103
|
+
|
|
104
|
+
### Setup
|
|
105
|
+
|
|
106
|
+
```bash
|
|
107
|
+
# Clone the repository
|
|
108
|
+
git clone <repo-url>
|
|
109
|
+
cd gix
|
|
110
|
+
|
|
111
|
+
# Install in development mode
|
|
112
|
+
pip install -e .[dev]
|
|
113
|
+
```
|
|
114
|
+
|
|
115
|
+
### Dependencies
|
|
116
|
+
|
|
117
|
+
**Runtime:**
|
|
118
|
+
- `typer>=0.12`
|
|
119
|
+
- `rich>=13.7`
|
|
120
|
+
- `PyYAML>=6.0`
|
|
121
|
+
|
|
122
|
+
**Development:**
|
|
123
|
+
- `pytest>=8.0`
|
|
124
|
+
- `goal>=2.1.0`
|
|
125
|
+
- `costs>=0.1.20`
|
|
126
|
+
- `pfix>=0.1.60`
|
|
127
|
+
|
|
128
|
+
### Testing
|
|
129
|
+
|
|
130
|
+
```bash
|
|
131
|
+
# Run all tests
|
|
132
|
+
pytest
|
|
133
|
+
|
|
134
|
+
# Run specific test file
|
|
135
|
+
pytest tests/test_history.py
|
|
136
|
+
|
|
137
|
+
# Run with coverage
|
|
138
|
+
pytest --cov=src/giton
|
|
139
|
+
```
|
|
140
|
+
|
|
141
|
+
### Environment Variables
|
|
142
|
+
|
|
143
|
+
Create a `.env` file in the project root (see `.env.example`):
|
|
144
|
+
|
|
145
|
+
| Variable | Default | Description |
|
|
146
|
+
|----------|---------|-------------|
|
|
147
|
+
| `OPENROUTER_API_KEY` | *(not set)* | Required: OpenRouter API key (https://openrouter.ai/keys) |
|
|
148
|
+
| `LLM_MODEL` | `openrouter/qwen/qwen3-coder-next` | Model to use for AI operations |
|
|
149
|
+
| `PFIX_AUTO_APPLY` | `true` | Automatically apply fixes without asking |
|
|
150
|
+
| `PFIX_AUTO_INSTALL_DEPS` | `true` | Automatically pip/uv install dependencies |
|
|
151
|
+
| `PFIX_AUTO_RESTART` | `false` | Restart process after fix using os.execv |
|
|
152
|
+
| `PFIX_MAX_RETRIES` | `3` | Maximum retry attempts |
|
|
153
|
+
| `PFIX_DRY_RUN` | `false` | Run in dry-run mode without making changes |
|
|
154
|
+
| `PFIX_ENABLED` | `true` | Enable automatic fixing |
|
|
155
|
+
| `PFIX_GIT_COMMIT` | `false` | Automatically commit fixes |
|
|
156
|
+
| `PFIX_GIT_PREFIX` | `pfix:` | Commit message prefix for fixes |
|
|
157
|
+
| `PFIX_CREATE_BACKUPS` | `false` | Create backups in `.pfix_backups/` directory |
|
|
158
|
+
|
|
159
|
+
### Project Structure
|
|
160
|
+
|
|
161
|
+
```
|
|
162
|
+
gix/
|
|
163
|
+
├── src/giton/ # Main source code
|
|
164
|
+
│ ├── __init__.py # Package initialization
|
|
165
|
+
│ ├── __main__.py # Entry point for `python -m giton`
|
|
166
|
+
│ ├── catalog.py # Plugin catalog management
|
|
167
|
+
│ ├── cli.py # Command-line interface (Typer)
|
|
168
|
+
│ ├── config.py # User plugin configuration
|
|
169
|
+
│ ├── context.py # Git context collection
|
|
170
|
+
│ ├── history.py # Safe history operations (fixup, autosquash)
|
|
171
|
+
│ ├── hooks.py # Git hook installation
|
|
172
|
+
│ ├── interactive.py # Interactive prompts
|
|
173
|
+
│ ├── plugins.py # Plugin installation/management
|
|
174
|
+
│ ├── policies.py # Built-in policy engine
|
|
175
|
+
│ ├── repo_config.py # Repository configuration
|
|
176
|
+
│ ├── runner.py # Plugin execution runner
|
|
177
|
+
│ └── shell.py # Interactive REPL shell
|
|
178
|
+
├── tests/ # Test suite
|
|
179
|
+
│ ├── test_basic.py # Basic functionality tests
|
|
180
|
+
│ ├── test_history.py # History operations tests
|
|
181
|
+
│ └── test_policies.py # Policy engine tests
|
|
182
|
+
├── examples/ # Usage examples
|
|
183
|
+
│ ├── basic/ # Basic library usage
|
|
184
|
+
│ ├── advanced/ # Advanced features demo
|
|
185
|
+
│ └── testing/ # CI/CD integration example
|
|
186
|
+
├── pyproject.toml # Project configuration
|
|
187
|
+
├── README.md # This file
|
|
188
|
+
├── SUMD.md # System documentation (SUMD)
|
|
189
|
+
├── TODO.md # Auto-generated TODO list
|
|
190
|
+
└── CHANGELOG.md # Version history
|
|
191
|
+
```
|
|
192
|
+
|
|
102
193
|
## Quick start
|
|
103
194
|
|
|
104
195
|
```bash
|
|
@@ -3,11 +3,11 @@
|
|
|
3
3
|
|
|
4
4
|
## AI Cost Tracking
|
|
5
5
|
|
|
6
|
-
    
|
|
7
7
|
  
|
|
8
8
|
|
|
9
|
-
- 🤖 **LLM usage:** $0.
|
|
10
|
-
- 👤 **Human dev:** ~$
|
|
9
|
+
- 🤖 **LLM usage:** $0.6135 (9 commits)
|
|
10
|
+
- 👤 **Human dev:** ~$319 (3.2h @ $100/h, 30min dedup)
|
|
11
11
|
|
|
12
12
|
Generated on 2026-05-27 using [openrouter/qwen/qwen3-coder-next](https://openrouter.ai/qwen/qwen3-coder-next)
|
|
13
13
|
|
|
@@ -80,6 +80,97 @@ giton: Apply patch and add commit "fixup! ..."? [Y/n]
|
|
|
80
80
|
pip install giton
|
|
81
81
|
```
|
|
82
82
|
|
|
83
|
+
## Development
|
|
84
|
+
|
|
85
|
+
### Setup
|
|
86
|
+
|
|
87
|
+
```bash
|
|
88
|
+
# Clone the repository
|
|
89
|
+
git clone <repo-url>
|
|
90
|
+
cd gix
|
|
91
|
+
|
|
92
|
+
# Install in development mode
|
|
93
|
+
pip install -e .[dev]
|
|
94
|
+
```
|
|
95
|
+
|
|
96
|
+
### Dependencies
|
|
97
|
+
|
|
98
|
+
**Runtime:**
|
|
99
|
+
- `typer>=0.12`
|
|
100
|
+
- `rich>=13.7`
|
|
101
|
+
- `PyYAML>=6.0`
|
|
102
|
+
|
|
103
|
+
**Development:**
|
|
104
|
+
- `pytest>=8.0`
|
|
105
|
+
- `goal>=2.1.0`
|
|
106
|
+
- `costs>=0.1.20`
|
|
107
|
+
- `pfix>=0.1.60`
|
|
108
|
+
|
|
109
|
+
### Testing
|
|
110
|
+
|
|
111
|
+
```bash
|
|
112
|
+
# Run all tests
|
|
113
|
+
pytest
|
|
114
|
+
|
|
115
|
+
# Run specific test file
|
|
116
|
+
pytest tests/test_history.py
|
|
117
|
+
|
|
118
|
+
# Run with coverage
|
|
119
|
+
pytest --cov=src/giton
|
|
120
|
+
```
|
|
121
|
+
|
|
122
|
+
### Environment Variables
|
|
123
|
+
|
|
124
|
+
Create a `.env` file in the project root (see `.env.example`):
|
|
125
|
+
|
|
126
|
+
| Variable | Default | Description |
|
|
127
|
+
|----------|---------|-------------|
|
|
128
|
+
| `OPENROUTER_API_KEY` | *(not set)* | Required: OpenRouter API key (https://openrouter.ai/keys) |
|
|
129
|
+
| `LLM_MODEL` | `openrouter/qwen/qwen3-coder-next` | Model to use for AI operations |
|
|
130
|
+
| `PFIX_AUTO_APPLY` | `true` | Automatically apply fixes without asking |
|
|
131
|
+
| `PFIX_AUTO_INSTALL_DEPS` | `true` | Automatically pip/uv install dependencies |
|
|
132
|
+
| `PFIX_AUTO_RESTART` | `false` | Restart process after fix using os.execv |
|
|
133
|
+
| `PFIX_MAX_RETRIES` | `3` | Maximum retry attempts |
|
|
134
|
+
| `PFIX_DRY_RUN` | `false` | Run in dry-run mode without making changes |
|
|
135
|
+
| `PFIX_ENABLED` | `true` | Enable automatic fixing |
|
|
136
|
+
| `PFIX_GIT_COMMIT` | `false` | Automatically commit fixes |
|
|
137
|
+
| `PFIX_GIT_PREFIX` | `pfix:` | Commit message prefix for fixes |
|
|
138
|
+
| `PFIX_CREATE_BACKUPS` | `false` | Create backups in `.pfix_backups/` directory |
|
|
139
|
+
|
|
140
|
+
### Project Structure
|
|
141
|
+
|
|
142
|
+
```
|
|
143
|
+
gix/
|
|
144
|
+
├── src/giton/ # Main source code
|
|
145
|
+
│ ├── __init__.py # Package initialization
|
|
146
|
+
│ ├── __main__.py # Entry point for `python -m giton`
|
|
147
|
+
│ ├── catalog.py # Plugin catalog management
|
|
148
|
+
│ ├── cli.py # Command-line interface (Typer)
|
|
149
|
+
│ ├── config.py # User plugin configuration
|
|
150
|
+
│ ├── context.py # Git context collection
|
|
151
|
+
│ ├── history.py # Safe history operations (fixup, autosquash)
|
|
152
|
+
│ ├── hooks.py # Git hook installation
|
|
153
|
+
│ ├── interactive.py # Interactive prompts
|
|
154
|
+
│ ├── plugins.py # Plugin installation/management
|
|
155
|
+
│ ├── policies.py # Built-in policy engine
|
|
156
|
+
│ ├── repo_config.py # Repository configuration
|
|
157
|
+
│ ├── runner.py # Plugin execution runner
|
|
158
|
+
│ └── shell.py # Interactive REPL shell
|
|
159
|
+
├── tests/ # Test suite
|
|
160
|
+
│ ├── test_basic.py # Basic functionality tests
|
|
161
|
+
│ ├── test_history.py # History operations tests
|
|
162
|
+
│ └── test_policies.py # Policy engine tests
|
|
163
|
+
├── examples/ # Usage examples
|
|
164
|
+
│ ├── basic/ # Basic library usage
|
|
165
|
+
│ ├── advanced/ # Advanced features demo
|
|
166
|
+
│ └── testing/ # CI/CD integration example
|
|
167
|
+
├── pyproject.toml # Project configuration
|
|
168
|
+
├── README.md # This file
|
|
169
|
+
├── SUMD.md # System documentation (SUMD)
|
|
170
|
+
├── TODO.md # Auto-generated TODO list
|
|
171
|
+
└── CHANGELOG.md # Version history
|
|
172
|
+
```
|
|
173
|
+
|
|
83
174
|
## Quick start
|
|
84
175
|
|
|
85
176
|
```bash
|