TSNDep - Dependency Manager for TSN MQL5 Ecosystem. Manages dependencies recursively with hooks support
Project description
TSN Dependency Manager
A powerful CLI tool for managing TSN MQL5 Projects dependencies with recursive processing, hooks support, and automatic dependency resolution.
Main Features
Dependency Management
- Declarative Configuration: Define dependencies in a simple JSON format
- Recursive Processing: Automatically resolve nested dependencies
- Duplicate Prevention: Skip already-processed repositories
- Smart Updates: Clone new repos or pull existing ones
Hooks System
- Pre/Post Hooks: Execute custom commands before and after operations
- Conditional Execution: Run hooks only on success
- Timeout Control: Prevent hanging commands with configurable timeouts
- Error Handling: Skip failures or fail on errors
Advanced Queries
- Dependency Tree: Visualize project structure with depth control
- Export Analysis: Export flattened dependency list with metadata
- Repository Validation: Check that all dependencies are properly cloned
Multi-Language Support
- Language Detection: Identify required programming languages
- Version Tracking: Record language versions per dependency
- Structured Metadata: Store comments and branch information
Repository Structure
TSNDep/
├── tsndep/ # Source code (CLI, commands, utilities)
│ ├── Comands/ # Command modules (install, add, remove, update, list, check, export, init)
│ └── Ops/ # Utilities (Git operations, hooks, JSON handling)
Installation
From PyPI (Recommended)
pip install tsndep
Then use globally:
tsndep --help
From Repository
git clone https://forge.mql5.io/nique_372/TSNDep
cd TSNDep
pip install -e .
Contact me
Contact me on MQL5 (user: nique_372) to be added as a collaborator with your MQL5 nickname (read-only access), which will make the repository automatically appear in your Shared Projects folder
Quick Start
1. Initialize Your Project
cd your-project
tsndep init
This creates a dependencies.json template with:
- Empty repos array
- MetaTrader 5 build requirement
- Hook configuration (pre/post install/update)
2. Configure Dependencies
Edit dependencies.json and add your first dependency:
{
"repos": [
{
"name": "my-core-lib",
"url": "https://github.com/yourorg/my-core-lib.git",
"rama": "main",
"comment": "Core library for trading systems"
}
],
"hooks": {
"post_install": []
}
}
3. Clone & Install All Dependencies
# Install from repository URL
tsndep install https://github.com/yourorg/my-project.git main
# Or with custom path
tsndep install https://github.com/yourorg/my-project.git main --path_install custom\\path
This will:
- Clone the main repository
- Read its
dependencies.json - Recursively clone all nested dependencies
- Execute any pre/post hooks
4. Verify Everything is Installed
tsndep check
Shows status of each dependency:
[OK]: Repository cloned and ready[FAIL]: Repository missing or not cloned
5. Visualize the Dependency Tree
# Show all dependencies (default depth: 10)
tsndep list
# Show only 3 levels deep
tsndep list --depth 3
Output:
MyProject/
├── my-core-lib/
│ ├── logger-lib/
│ └── config-lib/
└── data-processor/
├── pandas-wrapper/
└── ml-models/
Common Commands
Add a New Dependency
tsndep add https://github.com/org/repo.git main \
--name my-new-lib \
--comment "Trading calculations library"
Remove a Dependency
tsndep remove my-new-lib
Update all repositories (from dependencies.json)
tsndep update
Pulls latest changes from all repositories.
Export Flat Dependency List
tsndep export --output all-deps.json
Creates a flattened list with all dependencies (useful for CI/CD).
Requirements
Python
- pip (Python package manager)
- see: requirements.txt
Check Your Setup
python --version # Should be 3.10+
git --version # Should be installed
pip list | grep click # Should show click installed
Documentation
- Commands Reference: Detailed description of each command
- dependencies.json Format: Full dependencies.json specification
- Hooks Guide: Hook system and examples
License
By downloading or using this repository, you accept the license terms.
Contact and Support
- Platform: MQL5 Community
- Profile: https://www.mql5.com/es/users/nique_372
- Issues: For bug reports or questions
Disclaimer
- TSNDep is a dependency management tool, not trading software
- Always test in development before production deployment
- Ensure you have permissions for all repositories
- Git operations may have security implications. review URLs carefully
- The authors assume no liability for system failures or data loss
Copyright © 2026 TradeSystemsNique
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file tsndep-1.0.1.tar.gz.
File metadata
- Download URL: tsndep-1.0.1.tar.gz
- Upload date:
- Size: 11.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.10.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
8ae7e9f3ababb3d7e504d9352ef3abaab79a2f61cf7b1ec574f0a3055bd24e4b
|
|
| MD5 |
8d0826c2d59f62835923cff5bfe7602b
|
|
| BLAKE2b-256 |
f0b8394c14ff09a16971dc22f00ec44043799e27470c315fd065322a952ec365
|
File details
Details for the file tsndep-1.0.1-py3-none-any.whl.
File metadata
- Download URL: tsndep-1.0.1-py3-none-any.whl
- Upload date:
- Size: 14.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.10.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
d80456711d542f9f97b0c051853b8fd2f4d2d4abe6b27b683b546fec007a23b7
|
|
| MD5 |
515e70de41e5101f6f07d27068ddf6dd
|
|
| BLAKE2b-256 |
f74cf935d647551e5c93b54865975da6023ea35168d163005c088a54d1ad7293
|