scip-cli 2.2.0__tar.gz → 2.3.0__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.
- scip_cli-2.3.0/.github/ISSUE_TEMPLATE/bug_report.md +36 -0
- scip_cli-2.3.0/.github/ISSUE_TEMPLATE/feature_request.md +33 -0
- scip_cli-2.3.0/.github/ISSUE_TEMPLATE/question.md +21 -0
- scip_cli-2.3.0/.github/pull_request_template.md +43 -0
- scip_cli-2.3.0/CODE_OF_CONDUCT.md +128 -0
- scip_cli-2.3.0/CONTRIBUTING.md +95 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/PKG-INFO +22 -4
- {scip_cli-2.2.0 → scip_cli-2.3.0}/README.md +21 -3
- scip_cli-2.3.0/SECURITY.md +46 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/scip_cli/SKILL.md +20 -2
- {scip_cli-2.2.0 → scip_cli-2.3.0}/scip_cli/__init__.py +1 -1
- {scip_cli-2.2.0 → scip_cli-2.3.0}/scip_cli/__main__.py +10 -2
- {scip_cli-2.2.0 → scip_cli-2.3.0}/scip_cli/analyze/common.py +3 -3
- {scip_cli-2.2.0 → scip_cli-2.3.0}/scip_cli/analyze/file.py +20 -23
- {scip_cli-2.2.0 → scip_cli-2.3.0}/scip_cli/analyze/live.py +44 -15
- {scip_cli-2.2.0 → scip_cli-2.3.0}/scip_cli/analyze/project.py +25 -62
- scip_cli-2.3.0/scip_cli/analyze/sections.py +120 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/scip_cli/analyze/symbol.py +3 -2
- {scip_cli-2.2.0 → scip_cli-2.3.0}/scip_cli/cli_args.py +1 -1
- {scip_cli-2.2.0 → scip_cli-2.3.0}/scip_cli/commands/analyze.py +32 -13
- scip_cli-2.3.0/scip_cli/commands/deps.py +144 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/scripts/publish.sh +4 -4
- {scip_cli-2.2.0 → scip_cli-2.3.0}/tests/e2e_harness.py +1 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/tests/test_analyze.py +39 -18
- {scip_cli-2.2.0 → scip_cli-2.3.0}/tests/test_e2e.py +19 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/tests/test_e2e_analyze_patterns.py +0 -8
- {scip_cli-2.2.0 → scip_cli-2.3.0}/tests/test_e2e_perf.py +1 -0
- scip_cli-2.2.0/scip_cli/analyze/sections.py +0 -77
- scip_cli-2.2.0/scripts/verify_rovetia_reports.py +0 -128
- {scip_cli-2.2.0 → scip_cli-2.3.0}/.cursor/rules/agent.mdc +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/.gitignore +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/.pre-commit-config.yaml +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/LICENSE +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/pyproject.toml +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/scip_cli/analyze/__init__.py +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/scip_cli/analyze/graph.py +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/scip_cli/analyze/targets.py +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/scip_cli/cache.py +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/scip_cli/commands/__init__.py +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/scip_cli/commands/code.py +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/scip_cli/commands/members.py +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/scip_cli/commands/rdeps.py +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/scip_cli/commands/refs.py +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/scip_cli/commands/reindex.py +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/scip_cli/commands/search.py +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/scip_cli/commands/skill.py +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/scip_cli/commands/symbols.py +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/scip_cli/config.py +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/scip_cli/debug.py +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/scip_cli/discover.py +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/scip_cli/indexing.py +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/scip_cli/merge.py +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/scip_cli/output.py +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/scip_cli/paths.py +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/scip_cli/project.py +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/scip_cli/queries.py +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/scip_cli/scip_tool.py +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/scip_cli/scope.py +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/scip_cli/session.py +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/scip_cli/source.py +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/scip_cli/sql.py +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/scip_cli/symbols.py +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/scip_cli/targets.py +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/scripts/build.sh +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/scripts/test.sh +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/tests/__init__.py +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/tests/analyze_db.py +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/tests/conftest.py +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/tests/fixture_catalog.py +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/tests/fixtures/sample-project/package.json +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/tests/fixtures/sample-project/src/app/handler.ts +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/tests/fixtures/sample-project/src/config.ts +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/tests/fixtures/sample-project/src/consumer.ts +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/tests/fixtures/sample-project/src/dead.ts +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/tests/fixtures/sample-project/src/domain/i18n/en.ts +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/tests/fixtures/sample-project/src/domain/i18n/index.ts +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/tests/fixtures/sample-project/src/domain/i18n/useLocale.ts +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/tests/fixtures/sample-project/src/domain/labels/index.ts +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/tests/fixtures/sample-project/src/events/streamTypes.ts +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/tests/fixtures/sample-project/src/gateway/index.ts +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/tests/fixtures/sample-project/src/helper.ts +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/tests/fixtures/sample-project/src/hooks/useHookA.ts +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/tests/fixtures/sample-project/src/hooks/useHookB.ts +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/tests/fixtures/sample-project/src/hooks/useItems.ts +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/tests/fixtures/sample-project/src/index.ts +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/tests/fixtures/sample-project/src/integrations/inferenceClient.ts +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/tests/fixtures/sample-project/src/loaders/useInference.ts +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/tests/fixtures/sample-project/src/pages/panelPage.ts +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/tests/fixtures/sample-project/src/rules/applyRule.ts +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/tests/fixtures/sample-project/src/types/a.ts +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/tests/fixtures/sample-project/src/types/b.ts +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/tests/fixtures/sample-project/src/ui/Button.ts +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/tests/fixtures/sample-project/src/ui/LazyPanel.ts +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/tests/fixtures/sample-project/src/ui/buttonConsumer.ts +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/tests/fixtures/sample-project/src/ui/menuModule.ts +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/tests/fixtures/sample-project/src/user.ts +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/tests/fixtures/sample-project/src/widget.ts +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/tests/fixtures/sample-project/src/widgets/OrphanWidget.ts +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/tests/fixtures/sample-project/tsconfig.json +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/tests/perf_util.py +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/tests/test_analyze_graph.py +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/tests/test_analyze_perf.py +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/tests/test_cache.py +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/tests/test_composability.py +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/tests/test_config.py +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/tests/test_discover.py +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/tests/test_index_prune.py +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/tests/test_indexer_env.py +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/tests/test_merge.py +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/tests/test_multi_symbol.py +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/tests/test_pure_functions.py +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/tests/test_qualified_symbols.py +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/tests/test_reindex.py +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/tests/test_scip_tool.py +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/tests/test_scope.py +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/tests/test_targets.py +0 -0
- {scip_cli-2.2.0 → scip_cli-2.3.0}/tests/test_typescript_projects.py +0 -0
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: Bug Report
|
|
3
|
+
about: Report a bug or unexpected behavior
|
|
4
|
+
title: '[BUG] '
|
|
5
|
+
labels: bug
|
|
6
|
+
assignees: ''
|
|
7
|
+
---
|
|
8
|
+
|
|
9
|
+
**Describe the bug**
|
|
10
|
+
A clear and concise description of what the bug is.
|
|
11
|
+
|
|
12
|
+
**To Reproduce**
|
|
13
|
+
Steps to reproduce the behavior:
|
|
14
|
+
1. Run command: `scip-cli ...`
|
|
15
|
+
2. On project: [describe project type, size, language]
|
|
16
|
+
3. See error
|
|
17
|
+
|
|
18
|
+
**Expected behavior**
|
|
19
|
+
A clear and concise description of what you expected to happen.
|
|
20
|
+
|
|
21
|
+
**Actual behavior**
|
|
22
|
+
What actually happened. Include error messages, stack traces, or unexpected output.
|
|
23
|
+
|
|
24
|
+
**Environment**
|
|
25
|
+
- OS: [e.g., Ubuntu 22.04, macOS 14.0]
|
|
26
|
+
- Python version: [e.g., 3.11.5]
|
|
27
|
+
- scip-cli version: [e.g., 0.5.0]
|
|
28
|
+
- Node.js version: [e.g., 20.10.0] (if applicable)
|
|
29
|
+
|
|
30
|
+
**Additional context**
|
|
31
|
+
Add any other context about the problem here (logs, screenshots, project structure).
|
|
32
|
+
|
|
33
|
+
**Checklist**
|
|
34
|
+
- [ ] I've searched existing issues for similar bugs
|
|
35
|
+
- [ ] I've included a minimal reproducible example (if possible)
|
|
36
|
+
- [ ] I've provided my environment details
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: Feature Request
|
|
3
|
+
about: Suggest an idea or enhancement
|
|
4
|
+
title: '[FEATURE] '
|
|
5
|
+
labels: enhancement
|
|
6
|
+
assignees: ''
|
|
7
|
+
---
|
|
8
|
+
|
|
9
|
+
**Is your feature request related to a problem? Please describe.**
|
|
10
|
+
A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]
|
|
11
|
+
|
|
12
|
+
**Describe the solution you'd like**
|
|
13
|
+
A clear and concise description of what you want to happen.
|
|
14
|
+
|
|
15
|
+
**Describe alternatives you've considered**
|
|
16
|
+
A clear and concise description of any alternative solutions or features you've considered.
|
|
17
|
+
|
|
18
|
+
**Use case**
|
|
19
|
+
Describe your use case and how this feature would help you.
|
|
20
|
+
|
|
21
|
+
**Example usage**
|
|
22
|
+
If applicable, show how you'd use this feature:
|
|
23
|
+
|
|
24
|
+
```bash
|
|
25
|
+
scip-cli <command> [arguments]
|
|
26
|
+
```
|
|
27
|
+
|
|
28
|
+
**Additional context**
|
|
29
|
+
Add any other context, mockups, or examples about the feature request here.
|
|
30
|
+
|
|
31
|
+
**Checklist**
|
|
32
|
+
- [ ] I've searched existing issues for similar feature requests
|
|
33
|
+
- [ ] I've explained my use case clearly
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: Question
|
|
3
|
+
about: Ask a question about usage or behavior
|
|
4
|
+
title: '[QUESTION] '
|
|
5
|
+
labels: question
|
|
6
|
+
assignees: ''
|
|
7
|
+
---
|
|
8
|
+
|
|
9
|
+
**Your question**
|
|
10
|
+
A clear and concise question about scip-cli usage, behavior, or configuration.
|
|
11
|
+
|
|
12
|
+
**Context**
|
|
13
|
+
What are you trying to accomplish? What have you tried so far?
|
|
14
|
+
|
|
15
|
+
**Environment** (if relevant)
|
|
16
|
+
- OS: [e.g., Ubuntu 22.04]
|
|
17
|
+
- Python version: [e.g., 3.11.5]
|
|
18
|
+
- scip-cli version: [e.g., 0.5.0]
|
|
19
|
+
|
|
20
|
+
**Additional context**
|
|
21
|
+
Any other context, code examples, or screenshots that might help answer your question.
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
## Description
|
|
2
|
+
|
|
3
|
+
Brief description of what this PR does and why.
|
|
4
|
+
|
|
5
|
+
Fixes #(issue)
|
|
6
|
+
|
|
7
|
+
## Type of Change
|
|
8
|
+
|
|
9
|
+
- [ ] Bug fix (non-breaking change that fixes an issue)
|
|
10
|
+
- [ ] New feature (non-breaking change that adds functionality)
|
|
11
|
+
- [ ] Breaking change (fix or feature that would cause existing functionality to change)
|
|
12
|
+
- [ ] Documentation update
|
|
13
|
+
- [ ] Performance improvement
|
|
14
|
+
- [ ] Refactoring (no functional changes)
|
|
15
|
+
|
|
16
|
+
## Changes Made
|
|
17
|
+
|
|
18
|
+
-
|
|
19
|
+
-
|
|
20
|
+
-
|
|
21
|
+
|
|
22
|
+
## Testing
|
|
23
|
+
|
|
24
|
+
- [ ] `pytest` passes
|
|
25
|
+
- [ ] `ruff check .` passes
|
|
26
|
+
- [ ] `ruff format .` passes
|
|
27
|
+
- [ ] E2E tests pass (if CLI behavior changed): `pytest tests/test_e2e.py`
|
|
28
|
+
|
|
29
|
+
## Checklist
|
|
30
|
+
|
|
31
|
+
- [ ] My code follows the project's style guidelines
|
|
32
|
+
- [ ] I have self-reviewed my code
|
|
33
|
+
- [ ] I have updated documentation (README, SKILL.md) if needed
|
|
34
|
+
- [ ] I have added tests for new functionality
|
|
35
|
+
- [ ] All new and existing tests pass
|
|
36
|
+
|
|
37
|
+
## Screenshots / Output
|
|
38
|
+
|
|
39
|
+
If applicable, paste relevant CLI output or screenshots here.
|
|
40
|
+
|
|
41
|
+
## Additional Notes
|
|
42
|
+
|
|
43
|
+
Anything else reviewers should know.
|
|
@@ -0,0 +1,128 @@
|
|
|
1
|
+
# Contributor Covenant Code of Conduct
|
|
2
|
+
|
|
3
|
+
## Our Pledge
|
|
4
|
+
|
|
5
|
+
We as members, contributors, and leaders pledge to make participation in our
|
|
6
|
+
community a harassment-free experience for everyone, regardless of age, body
|
|
7
|
+
size, visible or invisible disability, ethnicity, sex characteristics, gender
|
|
8
|
+
identity and expression, level of experience, education, socio-economic status,
|
|
9
|
+
nationality, personal appearance, race, religion, or sexual identity
|
|
10
|
+
and orientation.
|
|
11
|
+
|
|
12
|
+
We pledge to act and interact in ways that contribute to an open, welcoming,
|
|
13
|
+
diverse, inclusive, and healthy community.
|
|
14
|
+
|
|
15
|
+
## Our Standards
|
|
16
|
+
|
|
17
|
+
Examples of behavior that contributes to a positive environment for our
|
|
18
|
+
community include:
|
|
19
|
+
|
|
20
|
+
* Demonstrating empathy and kindness toward other people
|
|
21
|
+
* Being respectful of differing opinions, viewpoints, and experiences
|
|
22
|
+
* Giving and gracefully accepting constructive feedback
|
|
23
|
+
* Accepting responsibility and apologizing to those affected by our mistakes,
|
|
24
|
+
and learning from the experience
|
|
25
|
+
* Focusing on what is best not just for us as individuals, but for the
|
|
26
|
+
overall community
|
|
27
|
+
|
|
28
|
+
Examples of unacceptable behavior include:
|
|
29
|
+
|
|
30
|
+
* The use of sexualized language or imagery, and sexual attention or
|
|
31
|
+
advances of any kind
|
|
32
|
+
* Trolling, insulting or derogatory comments, and personal or political attacks
|
|
33
|
+
* Public or private harassment
|
|
34
|
+
* Publishing others' private information, such as a physical or email
|
|
35
|
+
address, without their explicit permission
|
|
36
|
+
* Other conduct which could reasonably be considered inappropriate in a
|
|
37
|
+
professional setting
|
|
38
|
+
|
|
39
|
+
## Enforcement Responsibilities
|
|
40
|
+
|
|
41
|
+
Community leaders are responsible for clarifying and enforcing our standards of
|
|
42
|
+
acceptable behavior and will take appropriate and fair corrective action in
|
|
43
|
+
response to any behavior that they deem inappropriate, threatening, offensive,
|
|
44
|
+
or harmful.
|
|
45
|
+
|
|
46
|
+
Community leaders have the right and responsibility to remove, edit, or reject
|
|
47
|
+
comments, commits, code, wiki edits, issues, and other contributions that are
|
|
48
|
+
not aligned to this Code of Conduct, and will communicate reasons for moderation
|
|
49
|
+
decisions when appropriate.
|
|
50
|
+
|
|
51
|
+
## Scope
|
|
52
|
+
|
|
53
|
+
This Code of Conduct applies within all community spaces, and also applies when
|
|
54
|
+
an individual is officially representing the community in public spaces.
|
|
55
|
+
Examples of representing our community include using an official e-mail address,
|
|
56
|
+
posting via an official social media account, or acting as an appointed
|
|
57
|
+
representative at an online or offline event.
|
|
58
|
+
|
|
59
|
+
## Enforcement
|
|
60
|
+
|
|
61
|
+
Instances of abusive, harassing, or otherwise unacceptable behavior may be
|
|
62
|
+
reported to the community leaders responsible for enforcement at
|
|
63
|
+
ariel.flesler@gmail.com.
|
|
64
|
+
All complaints will be reviewed and investigated promptly and fairly.
|
|
65
|
+
|
|
66
|
+
All community leaders are obligated to respect the privacy and security of the
|
|
67
|
+
reporter of any incident.
|
|
68
|
+
|
|
69
|
+
## Enforcement Guidelines
|
|
70
|
+
|
|
71
|
+
Community leaders will follow these Community Impact Guidelines in determining
|
|
72
|
+
the consequences for any action they deem in violation of this Code of Conduct:
|
|
73
|
+
|
|
74
|
+
### 1. Correction
|
|
75
|
+
|
|
76
|
+
**Community Impact**: Use of inappropriate language or other behavior deemed
|
|
77
|
+
unprofessional or unwelcome in the community.
|
|
78
|
+
|
|
79
|
+
**Consequence**: A private, written warning from community leaders, providing
|
|
80
|
+
clarity around the nature of the violation and an explanation of why the
|
|
81
|
+
behavior was inappropriate. A public apology may be requested.
|
|
82
|
+
|
|
83
|
+
### 2. Warning
|
|
84
|
+
|
|
85
|
+
**Community Impact**: A violation through a single incident or series
|
|
86
|
+
of actions.
|
|
87
|
+
|
|
88
|
+
**Consequence**: A warning with consequences for continued behavior. No
|
|
89
|
+
interaction with the people involved, including unsolicited interaction with
|
|
90
|
+
those enforcing the Code of Conduct, for a specified period of time. This
|
|
91
|
+
includes avoiding interactions in community spaces as well as external channels
|
|
92
|
+
like social media. Violating these terms may lead to a temporary or
|
|
93
|
+
permanent ban.
|
|
94
|
+
|
|
95
|
+
### 3. Temporary Ban
|
|
96
|
+
|
|
97
|
+
**Community Impact**: A serious violation of community standards, including
|
|
98
|
+
sustained inappropriate behavior.
|
|
99
|
+
|
|
100
|
+
**Consequence**: A temporary ban from any sort of interaction or public
|
|
101
|
+
communication with the community for a specified period of time. No public or
|
|
102
|
+
private interaction with the people involved, including unsolicited interaction
|
|
103
|
+
with those enforcing the Code of Conduct, is allowed during this period.
|
|
104
|
+
Violating these terms may lead to a permanent ban.
|
|
105
|
+
|
|
106
|
+
### 4. Permanent Ban
|
|
107
|
+
|
|
108
|
+
**Community Impact**: Demonstrating a pattern of violation of community
|
|
109
|
+
standards, including sustained inappropriate behavior, harassment of an
|
|
110
|
+
individual, or aggression toward or disparagement of classes of individuals.
|
|
111
|
+
|
|
112
|
+
**Consequence**: A permanent ban from any sort of public interaction within
|
|
113
|
+
the community.
|
|
114
|
+
|
|
115
|
+
## Attribution
|
|
116
|
+
|
|
117
|
+
This Code of Conduct is adapted from the [Contributor Covenant][homepage],
|
|
118
|
+
version 2.0, available at
|
|
119
|
+
https://www.contributor-covenant.org/version/2/0/code_of_conduct.html.
|
|
120
|
+
|
|
121
|
+
Community Impact Guidelines were inspired by [Mozilla's code of conduct
|
|
122
|
+
enforcement ladder](https://github.com/mozilla/diversity).
|
|
123
|
+
|
|
124
|
+
[homepage]: https://www.contributor-covenant.org
|
|
125
|
+
|
|
126
|
+
For answers to common questions about this code of conduct, see the FAQ at
|
|
127
|
+
https://www.contributor-covenant.org/faq. Translations are available at
|
|
128
|
+
https://www.contributor-covenant.org/translations.
|
|
@@ -0,0 +1,95 @@
|
|
|
1
|
+
# Contributing to scip-cli
|
|
2
|
+
|
|
3
|
+
Thank you for your interest in contributing to scip-cli! This document provides guidelines and information for contributors.
|
|
4
|
+
|
|
5
|
+
## Code of Conduct
|
|
6
|
+
|
|
7
|
+
This project adheres to the [Contributor Covenant Code of Conduct](CODE_OF_CONDUCT.md). By participating, you are expected to uphold this code.
|
|
8
|
+
|
|
9
|
+
## How to Contribute
|
|
10
|
+
|
|
11
|
+
### Reporting Bugs
|
|
12
|
+
|
|
13
|
+
Before creating bug reports, please check existing issues. When creating a bug report, include:
|
|
14
|
+
|
|
15
|
+
- Clear, descriptive title
|
|
16
|
+
- Steps to reproduce the issue
|
|
17
|
+
- Expected vs actual behavior
|
|
18
|
+
- Environment details (OS, Python version, scip-cli version)
|
|
19
|
+
- Minimal reproducible example if possible
|
|
20
|
+
|
|
21
|
+
### Suggesting Enhancements
|
|
22
|
+
|
|
23
|
+
Enhancement suggestions are welcome! Please:
|
|
24
|
+
|
|
25
|
+
- Use a clear, descriptive title
|
|
26
|
+
- Provide a detailed description of the proposed enhancement
|
|
27
|
+
- Explain why this enhancement would be useful
|
|
28
|
+
- Include examples of how it would be used
|
|
29
|
+
|
|
30
|
+
### Pull Requests
|
|
31
|
+
|
|
32
|
+
1. Fork the repository
|
|
33
|
+
2. Create a feature branch (`git checkout -b feature/amazing-feature`)
|
|
34
|
+
3. Make your changes
|
|
35
|
+
4. Run tests: `pytest`
|
|
36
|
+
5. Run linter: `ruff check .` and `ruff format .`
|
|
37
|
+
6. Commit your changes (`git commit -m 'Add amazing feature'`)
|
|
38
|
+
7. Push to the branch (`git push origin feature/amazing-feature`)
|
|
39
|
+
8. Open a Pull Request
|
|
40
|
+
|
|
41
|
+
## Development Setup
|
|
42
|
+
|
|
43
|
+
```bash
|
|
44
|
+
# Clone your fork
|
|
45
|
+
git clone https://github.com/your-username/scip-cli.git
|
|
46
|
+
cd scip-cli
|
|
47
|
+
|
|
48
|
+
# Install with dev dependencies
|
|
49
|
+
pip install -e ".[dev]"
|
|
50
|
+
|
|
51
|
+
# Install pre-commit hooks
|
|
52
|
+
pre-commit install
|
|
53
|
+
|
|
54
|
+
# Run tests
|
|
55
|
+
pytest
|
|
56
|
+
|
|
57
|
+
# Run linter
|
|
58
|
+
ruff check .
|
|
59
|
+
ruff format .
|
|
60
|
+
```
|
|
61
|
+
|
|
62
|
+
## Testing
|
|
63
|
+
|
|
64
|
+
- Run full test suite: `pytest`
|
|
65
|
+
- Run E2E tests: `pytest tests/test_e2e.py tests/test_e2e_analyze_patterns.py`
|
|
66
|
+
- Integration tests require Node.js and `npx` (for `scip-typescript`)
|
|
67
|
+
|
|
68
|
+
## Code Style
|
|
69
|
+
|
|
70
|
+
- Python 3.9+
|
|
71
|
+
- Line length: 120 characters
|
|
72
|
+
- Use type hints where practical
|
|
73
|
+
- Follow existing code patterns
|
|
74
|
+
- No unnecessary comments
|
|
75
|
+
- Use double quotes for strings
|
|
76
|
+
|
|
77
|
+
## Commit Messages
|
|
78
|
+
|
|
79
|
+
- Use clear, descriptive commit messages
|
|
80
|
+
- Start with a verb in imperative mood: "Add", "Fix", "Update", "Remove"
|
|
81
|
+
- Keep the first line under 72 characters
|
|
82
|
+
- Reference issues when applicable
|
|
83
|
+
|
|
84
|
+
## Documentation
|
|
85
|
+
|
|
86
|
+
- Update README.md for user-facing changes
|
|
87
|
+
- Update SKILL.md if CLI flags or commands change
|
|
88
|
+
- Add docstrings to new functions
|
|
89
|
+
- Keep comments minimal but meaningful
|
|
90
|
+
|
|
91
|
+
## Questions?
|
|
92
|
+
|
|
93
|
+
Open an issue or contact the maintainer.
|
|
94
|
+
|
|
95
|
+
Thank you for contributing!
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: scip-cli
|
|
3
|
-
Version: 2.
|
|
3
|
+
Version: 2.3.0
|
|
4
4
|
Summary: Fast code intelligence via SCIP indexes
|
|
5
5
|
Project-URL: Homepage, https://github.com/flesler/scip-cli
|
|
6
6
|
Author: Ariel Flesler
|
|
@@ -133,6 +133,7 @@ scip-cli <command> [arguments]
|
|
|
133
133
|
- `search <pattern>` - Search symbols by name pattern (`--path`)
|
|
134
134
|
- `symbols <file>` - List all symbols in a file (`--path`; bare filename OK)
|
|
135
135
|
- `rdeps <file>` - Find files that depend on a file (`--path`)
|
|
136
|
+
- `deps <symbol|file>` - Find outbound dependencies (what a symbol or file calls) (`--path`, `--paths-only`)
|
|
136
137
|
- `members <symbol>` - List members of a class/interface (`--path`)
|
|
137
138
|
- `analyze [target]` - SQL health dashboards (`--limit`, `--priority`, `--include-tests`). No target: project-wide; directory or file path; symbol name. See [Finding easy wins with `analyze`](#finding-easy-wins-with-analyze).
|
|
138
139
|
- `reindex` - Force re-indexing of the current project (`--path` to limit scope; repeatable)
|
|
@@ -159,6 +160,12 @@ scip-cli symbols helper.ts
|
|
|
159
160
|
# Find files that import from a module
|
|
160
161
|
scip-cli rdeps src/helper.ts
|
|
161
162
|
|
|
163
|
+
# Find what a function calls
|
|
164
|
+
scip-cli deps greet
|
|
165
|
+
|
|
166
|
+
# Find what a file depends on
|
|
167
|
+
scip-cli deps src/helper.ts --paths-only
|
|
168
|
+
|
|
162
169
|
# List members of a class
|
|
163
170
|
scip-cli members Widget
|
|
164
171
|
|
|
@@ -171,7 +178,7 @@ scip-cli skill ~/.claude/skills/scip-cli/SKILL.md
|
|
|
171
178
|
|
|
172
179
|
### Pipelines
|
|
173
180
|
|
|
174
|
-
Stdout is one record per line; stderr carries warnings and ambiguity notices. Kinds are lowercase (`function`, `class`, `method`, `property`). Pipe-friendly flags: `refs --paths-only`, `search --names-only` / `--paths-only`, `members --names-only`. `rdeps` already prints bare file paths.
|
|
181
|
+
Stdout is one record per line; stderr carries warnings and ambiguity notices. Kinds are lowercase (`function`, `class`, `method`, `property`). Pipe-friendly flags: `refs --paths-only`, `search --names-only` / `--paths-only`, `members --names-only`, `deps --paths-only`. `rdeps` already prints bare file paths.
|
|
175
182
|
|
|
176
183
|
```bash
|
|
177
184
|
# What do importers of this file export?
|
|
@@ -185,6 +192,9 @@ scip-cli search Handler --kind class --names-only | xargs -I{} scip-cli members
|
|
|
185
192
|
|
|
186
193
|
# Walk class members to their definitions
|
|
187
194
|
scip-cli members Widget --names-only | xargs -I{} scip-cli code Widget.{}
|
|
195
|
+
|
|
196
|
+
# Find all files that a symbol depends on (outbound dependencies)
|
|
197
|
+
scip-cli deps greet --paths-only | sort -u
|
|
188
198
|
```
|
|
189
199
|
|
|
190
200
|
## How It Works
|
|
@@ -255,7 +265,7 @@ Use `--priority high` for a quick gate; `--priority high,medium` adds context. F
|
|
|
255
265
|
| **Cycles** | Import/mention cycles between production files — break the edge or extract shared code |
|
|
256
266
|
| **Unreferenced** | No usage in the index at all — delete |
|
|
257
267
|
| **Dead exports** | No external refs — delete or `_` prefix |
|
|
258
|
-
| **Stale types** | Classes/types with
|
|
268
|
+
| **Stale types** | Classes/types with no external consumer in the index — verify in-file or type-only use before removing |
|
|
259
269
|
| **Same-file only** | Used only inside defining file — rename to `_` |
|
|
260
270
|
| **Test-only consumers** | Cross-file refs are all from tests — promote to e2e or accept as internal |
|
|
261
271
|
|
|
@@ -270,7 +280,7 @@ scip-cli analyze scip_cli --limit 15 # directory: scoped project +
|
|
|
270
280
|
|
|
271
281
|
**Defaults:** project-wide and directory analyze skip `tests/`, `*.test.*`, `*.spec.*`, `conftest.py`, and `__tests__/`. Pass `--include-tests` to include them. File-target analyze always includes that file.
|
|
272
282
|
|
|
273
|
-
**Limits:**
|
|
283
|
+
**Limits:** "Dead export" means no cross-file mentions in the index — not unreachable code. Same-file private helpers are expected. Re-run `reindex` after large changes; the index is a snapshot.
|
|
274
284
|
|
|
275
285
|
## Performance
|
|
276
286
|
|
|
@@ -332,6 +342,14 @@ SCIP_CLI_DEBUG=1 scip-cli refs MyFunction
|
|
|
332
342
|
|
|
333
343
|
This is useful for testing and debugging SQL queries
|
|
334
344
|
|
|
345
|
+
## Contributing
|
|
346
|
+
|
|
347
|
+
Contributions are welcome! See [CONTRIBUTING.md](CONTRIBUTING.md) for guidelines. By participating, you agree to the [Code of Conduct](CODE_OF_CONDUCT.md).
|
|
348
|
+
|
|
349
|
+
## Security
|
|
350
|
+
|
|
351
|
+
To report a security vulnerability, see [SECURITY.md](SECURITY.md).
|
|
352
|
+
|
|
335
353
|
## License
|
|
336
354
|
|
|
337
355
|
MIT
|
|
@@ -113,6 +113,7 @@ scip-cli <command> [arguments]
|
|
|
113
113
|
- `search <pattern>` - Search symbols by name pattern (`--path`)
|
|
114
114
|
- `symbols <file>` - List all symbols in a file (`--path`; bare filename OK)
|
|
115
115
|
- `rdeps <file>` - Find files that depend on a file (`--path`)
|
|
116
|
+
- `deps <symbol|file>` - Find outbound dependencies (what a symbol or file calls) (`--path`, `--paths-only`)
|
|
116
117
|
- `members <symbol>` - List members of a class/interface (`--path`)
|
|
117
118
|
- `analyze [target]` - SQL health dashboards (`--limit`, `--priority`, `--include-tests`). No target: project-wide; directory or file path; symbol name. See [Finding easy wins with `analyze`](#finding-easy-wins-with-analyze).
|
|
118
119
|
- `reindex` - Force re-indexing of the current project (`--path` to limit scope; repeatable)
|
|
@@ -139,6 +140,12 @@ scip-cli symbols helper.ts
|
|
|
139
140
|
# Find files that import from a module
|
|
140
141
|
scip-cli rdeps src/helper.ts
|
|
141
142
|
|
|
143
|
+
# Find what a function calls
|
|
144
|
+
scip-cli deps greet
|
|
145
|
+
|
|
146
|
+
# Find what a file depends on
|
|
147
|
+
scip-cli deps src/helper.ts --paths-only
|
|
148
|
+
|
|
142
149
|
# List members of a class
|
|
143
150
|
scip-cli members Widget
|
|
144
151
|
|
|
@@ -151,7 +158,7 @@ scip-cli skill ~/.claude/skills/scip-cli/SKILL.md
|
|
|
151
158
|
|
|
152
159
|
### Pipelines
|
|
153
160
|
|
|
154
|
-
Stdout is one record per line; stderr carries warnings and ambiguity notices. Kinds are lowercase (`function`, `class`, `method`, `property`). Pipe-friendly flags: `refs --paths-only`, `search --names-only` / `--paths-only`, `members --names-only`. `rdeps` already prints bare file paths.
|
|
161
|
+
Stdout is one record per line; stderr carries warnings and ambiguity notices. Kinds are lowercase (`function`, `class`, `method`, `property`). Pipe-friendly flags: `refs --paths-only`, `search --names-only` / `--paths-only`, `members --names-only`, `deps --paths-only`. `rdeps` already prints bare file paths.
|
|
155
162
|
|
|
156
163
|
```bash
|
|
157
164
|
# What do importers of this file export?
|
|
@@ -165,6 +172,9 @@ scip-cli search Handler --kind class --names-only | xargs -I{} scip-cli members
|
|
|
165
172
|
|
|
166
173
|
# Walk class members to their definitions
|
|
167
174
|
scip-cli members Widget --names-only | xargs -I{} scip-cli code Widget.{}
|
|
175
|
+
|
|
176
|
+
# Find all files that a symbol depends on (outbound dependencies)
|
|
177
|
+
scip-cli deps greet --paths-only | sort -u
|
|
168
178
|
```
|
|
169
179
|
|
|
170
180
|
## How It Works
|
|
@@ -235,7 +245,7 @@ Use `--priority high` for a quick gate; `--priority high,medium` adds context. F
|
|
|
235
245
|
| **Cycles** | Import/mention cycles between production files — break the edge or extract shared code |
|
|
236
246
|
| **Unreferenced** | No usage in the index at all — delete |
|
|
237
247
|
| **Dead exports** | No external refs — delete or `_` prefix |
|
|
238
|
-
| **Stale types** | Classes/types with
|
|
248
|
+
| **Stale types** | Classes/types with no external consumer in the index — verify in-file or type-only use before removing |
|
|
239
249
|
| **Same-file only** | Used only inside defining file — rename to `_` |
|
|
240
250
|
| **Test-only consumers** | Cross-file refs are all from tests — promote to e2e or accept as internal |
|
|
241
251
|
|
|
@@ -250,7 +260,7 @@ scip-cli analyze scip_cli --limit 15 # directory: scoped project +
|
|
|
250
260
|
|
|
251
261
|
**Defaults:** project-wide and directory analyze skip `tests/`, `*.test.*`, `*.spec.*`, `conftest.py`, and `__tests__/`. Pass `--include-tests` to include them. File-target analyze always includes that file.
|
|
252
262
|
|
|
253
|
-
**Limits:**
|
|
263
|
+
**Limits:** "Dead export" means no cross-file mentions in the index — not unreachable code. Same-file private helpers are expected. Re-run `reindex` after large changes; the index is a snapshot.
|
|
254
264
|
|
|
255
265
|
## Performance
|
|
256
266
|
|
|
@@ -312,6 +322,14 @@ SCIP_CLI_DEBUG=1 scip-cli refs MyFunction
|
|
|
312
322
|
|
|
313
323
|
This is useful for testing and debugging SQL queries
|
|
314
324
|
|
|
325
|
+
## Contributing
|
|
326
|
+
|
|
327
|
+
Contributions are welcome! See [CONTRIBUTING.md](CONTRIBUTING.md) for guidelines. By participating, you agree to the [Code of Conduct](CODE_OF_CONDUCT.md).
|
|
328
|
+
|
|
329
|
+
## Security
|
|
330
|
+
|
|
331
|
+
To report a security vulnerability, see [SECURITY.md](SECURITY.md).
|
|
332
|
+
|
|
315
333
|
## License
|
|
316
334
|
|
|
317
335
|
MIT
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
# Security Policy
|
|
2
|
+
|
|
3
|
+
## Supported Versions
|
|
4
|
+
|
|
5
|
+
| Version | Supported |
|
|
6
|
+
| ------- | ------------------ |
|
|
7
|
+
| latest | :white_check_mark: |
|
|
8
|
+
| < latest| :x: |
|
|
9
|
+
|
|
10
|
+
## Reporting a Vulnerability
|
|
11
|
+
|
|
12
|
+
**Do not open public issues for security vulnerabilities.**
|
|
13
|
+
|
|
14
|
+
If you discover a security vulnerability, please email **ariel.flesler@gmail.com** with:
|
|
15
|
+
|
|
16
|
+
- Description of the vulnerability
|
|
17
|
+
- Steps to reproduce or proof of concept
|
|
18
|
+
- Potential impact
|
|
19
|
+
- Suggested fix (if any)
|
|
20
|
+
|
|
21
|
+
## What to Expect
|
|
22
|
+
|
|
23
|
+
- Acknowledgment within 48 hours
|
|
24
|
+
- Assessment of the vulnerability's severity and impact
|
|
25
|
+
- Timeline for a fix and release
|
|
26
|
+
- Credit in the release notes (unless you prefer to remain anonymous)
|
|
27
|
+
|
|
28
|
+
## Scope
|
|
29
|
+
|
|
30
|
+
Security considerations for scip-cli include:
|
|
31
|
+
|
|
32
|
+
- **Index integrity**: SCIP indexes are read from local filesystem and trusted
|
|
33
|
+
- **SQL injection**: All queries use parameterized statements
|
|
34
|
+
- **Path traversal**: File operations are scoped to the indexed project
|
|
35
|
+
- **Dependency security**: Minimal dependencies; pinned versions in `pyproject.toml`
|
|
36
|
+
|
|
37
|
+
## Security Best Practices for Users
|
|
38
|
+
|
|
39
|
+
- Install from PyPI: `pip install scip-cli` (verified releases)
|
|
40
|
+
- Keep scip-cli updated to the latest version
|
|
41
|
+
- Review `.scip-cli.json` configuration before use in untrusted projects
|
|
42
|
+
- The `scip` binary is downloaded from [official releases](https://github.com/scip-code/scip/releases)
|
|
43
|
+
|
|
44
|
+
## Responsible Disclosure
|
|
45
|
+
|
|
46
|
+
We appreciate responsible disclosure and will work with you to understand and address the issue promptly.
|
|
@@ -18,6 +18,7 @@ All commands are sub-commands of `scip-cli`. Run from the project root.
|
|
|
18
18
|
| "What's in this file?" | `symbols file` | Up to `--limit` symbols (default 10). Bare filename works (`helper.ts`) |
|
|
19
19
|
| "Find symbols by name" | `search name` | Functions, types, interfaces, classes |
|
|
20
20
|
| "What files depend on this file?" | `rdeps file` | Importers — bare name works |
|
|
21
|
+
| "What does this symbol/file depend on?" | `deps target` | Outbound dependencies — symbols referenced within a function or file |
|
|
21
22
|
| "What methods does this class have?" | `members ClassName` | All methods/fields with line ranges |
|
|
22
23
|
| "Health / risk / stale code?" | `analyze` | Multi-section SQL dashboard — omit target (project), pass file, or symbol |
|
|
23
24
|
|
|
@@ -70,8 +71,9 @@ Commands emit one record per line on stdout; warnings and progress go to stderr.
|
|
|
70
71
|
| Find functions, show callers | `scip-cli search Publish --kind function --names-only \| xargs -I{} scip-cli refs {} --paths-only` |
|
|
71
72
|
| Files touching a topic | `scip-cli search Dynamo --paths-only` |
|
|
72
73
|
| Count importers | `scip-cli rdeps file.ts \| wc -l` |
|
|
74
|
+
| Outbound dependency files | `scip-cli deps file.ts --paths-only` |
|
|
73
75
|
|
|
74
|
-
`rdeps` already prints bare paths. `refs` defaults to `path:line`; add `--paths-only` to dedupe files. `search` / `members` need `--names-only` or `--paths-only` instead of `awk`.
|
|
76
|
+
`rdeps` already prints bare paths. `deps --paths-only` deduplicates to unique files. `refs` defaults to `path:line`; add `--paths-only` to dedupe files. `search` / `members` need `--names-only` or `--paths-only` instead of `awk`.
|
|
75
77
|
|
|
76
78
|
Each `xargs` invocation reopens the index (fast on cache hit). Use `--limit` on the first command to cap fan-out.
|
|
77
79
|
|
|
@@ -105,6 +107,20 @@ Returns list of files that import from this file.
|
|
|
105
107
|
|
|
106
108
|
Default `--limit` is 10.
|
|
107
109
|
|
|
110
|
+
### deps
|
|
111
|
+
|
|
112
|
+
```bash
|
|
113
|
+
deps [--limit N] [--path PATH] [--paths-only] <symbol|file>
|
|
114
|
+
```
|
|
115
|
+
|
|
116
|
+
Returns outbound dependencies — symbols referenced within a function/method or file.
|
|
117
|
+
|
|
118
|
+
For a symbol target, finds all symbols mentioned within the definition range (function body). For a file target, finds all external symbols referenced in that file (excluding the file's own symbols).
|
|
119
|
+
|
|
120
|
+
Output format: `file:line symbolName` for each dependency. Use `--paths-only` to output unique file paths only (pipe-friendly).
|
|
121
|
+
|
|
122
|
+
Default `--limit` is 10.
|
|
123
|
+
|
|
108
124
|
### members
|
|
109
125
|
|
|
110
126
|
```bash
|
|
@@ -128,10 +144,12 @@ analyze [--limit N] [--path PATH] [--include-tests] [target]
|
|
|
128
144
|
|
|
129
145
|
Sections are ordered **high → medium → low**. `[high]` cycles, unreferenced, dead exports, stale types; `[medium]` same-file-only, change surface (file); `[low]` test-only consumers (noisy on Python), coupling, bottlenecks, hotspots.
|
|
130
146
|
|
|
147
|
+
`--limit` caps **result rows across the whole run** (default 20); remaining checks are skipped once the cap is reached. `(none)` sections and section headers do not count.
|
|
148
|
+
|
|
131
149
|
`--priority high` or `--priority high,medium` (also `1`/`2`/`3`) skips lower tiers.
|
|
132
150
|
|
|
133
151
|
Directory detection uses the filesystem when present, otherwise an indexed path prefix. `--path` narrows ambiguous file/symbol resolution only (not directory scope — pass the dir as `target`).
|
|
134
152
|
|
|
135
153
|
**Dogfood loop:** `reindex` → `analyze --limit 25` → `analyze scip_cli` or `analyze scip_cli/queries.py` on suspects. Skips test paths in project-wide and directory runs (`tests/`, `*.test.*`, `*.spec.*`); `--include-tests` to include them. File-target analyze always includes that file.
|
|
136
154
|
|
|
137
|
-
**Easy pickings:** **Cycles** and **dead exports** (production paths) — cross-file cleanup. **Stale types** —
|
|
155
|
+
**Easy pickings:** **Cycles** and **dead exports** (production paths) — cross-file cleanup. **Stale types** — types with no external refs in the index. Ignore `analyze/*` section helpers in dead exports. “Dead” = no refs from *other* files in the index, not `vulture`.
|
|
@@ -9,7 +9,7 @@ import sys
|
|
|
9
9
|
|
|
10
10
|
from . import __version__
|
|
11
11
|
from .cli_args import add_limit_argument, add_names_only_argument, add_path_argument, add_paths_only_argument
|
|
12
|
-
from .commands import analyze, code, members, rdeps, refs, reindex, search, skill, symbols
|
|
12
|
+
from .commands import analyze, code, deps, members, rdeps, refs, reindex, search, skill, symbols
|
|
13
13
|
from .symbols import SymbolKind
|
|
14
14
|
|
|
15
15
|
# Set up debug logging based on SCIP_CLI_DEBUG env var
|
|
@@ -93,6 +93,13 @@ def main():
|
|
|
93
93
|
add_path_argument(rdeps_parser)
|
|
94
94
|
rdeps_parser.add_argument("file", help="File path or pattern")
|
|
95
95
|
|
|
96
|
+
# deps
|
|
97
|
+
deps_parser = subparsers.add_parser("deps", help="Find outbound dependencies (what a symbol/file calls)")
|
|
98
|
+
add_limit_argument(deps_parser, default=10, help_suffix="dependencies")
|
|
99
|
+
add_path_argument(deps_parser)
|
|
100
|
+
add_paths_only_argument(deps_parser)
|
|
101
|
+
deps_parser.add_argument("target", help="Symbol name or file path")
|
|
102
|
+
|
|
96
103
|
# members
|
|
97
104
|
members_parser = subparsers.add_parser("members", help="List members of a class/interface")
|
|
98
105
|
add_limit_argument(members_parser, default=10, help_suffix="members")
|
|
@@ -115,7 +122,7 @@ def main():
|
|
|
115
122
|
help="Omit for project-wide; directory for scoped project + per-file; file or symbol for focused checks",
|
|
116
123
|
)
|
|
117
124
|
add_path_argument(analyze_parser)
|
|
118
|
-
add_limit_argument(analyze_parser, default=20, help_suffix="rows
|
|
125
|
+
add_limit_argument(analyze_parser, default=20, help_suffix="result rows total")
|
|
119
126
|
analyze_parser.add_argument(
|
|
120
127
|
"--include-tests",
|
|
121
128
|
action="store_true",
|
|
@@ -150,6 +157,7 @@ def main():
|
|
|
150
157
|
"search": search.main,
|
|
151
158
|
"symbols": symbols.main,
|
|
152
159
|
"rdeps": rdeps.main,
|
|
160
|
+
"deps": deps.main,
|
|
153
161
|
"members": members.main,
|
|
154
162
|
"skill": skill.main,
|
|
155
163
|
"analyze": analyze.main,
|
|
@@ -127,7 +127,7 @@ def cycle_path_noise(cycle_line: str, *, include_tests: bool = False) -> bool:
|
|
|
127
127
|
return any(is_test_path(part.strip()) for part in parts if part.strip())
|
|
128
128
|
|
|
129
129
|
|
|
130
|
-
def section(title: str, lines: list[str]) -> tuple[str, list[str]]:
|
|
130
|
+
def section(title: str, lines: list[str], *, preface: str | None = None) -> tuple[str, list[str], str | None]:
|
|
131
131
|
if not lines:
|
|
132
|
-
return title, ["(none)"]
|
|
133
|
-
return title, lines
|
|
132
|
+
return title, ["(none)"], None
|
|
133
|
+
return title, lines, preface
|