@datamitsu/datamitsu-win32-x64 0.0.1-alpha-1
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.
- package/README.md +188 -0
- package/datamitsu.exe +0 -0
- package/package.json +24 -0
package/README.md
ADDED
|
@@ -0,0 +1,188 @@
|
|
|
1
|
+
# datamitsu
|
|
2
|
+
|
|
3
|
+
> Opinionated configuration management, extensible by design
|
|
4
|
+
|
|
5
|
+
[](https://opensource.org/licenses/MIT)
|
|
6
|
+
|
|
7
|
+
## Philosophy & Name
|
|
8
|
+
|
|
9
|
+
**Datamitsu** combines "data" with "mitsu" (光 - light, 蜜 - honey in Japanese), symbolizing clarity and sweetness in managing development tools and configurations.
|
|
10
|
+
|
|
11
|
+
The name reflects the project's philosophy: to bring **clarity** to the complexity of tool management and **sweetness** to the developer experience through a stable, fast core engine that others can extend with opinionated configurations.
|
|
12
|
+
|
|
13
|
+
Like light illuminating the path forward and honey making the experience pleasant, datamitsu provides a foundation that is both reliable and enjoyable to work with.
|
|
14
|
+
|
|
15
|
+
## What is datamitsu?
|
|
16
|
+
|
|
17
|
+
Datamitsu is a **core engine** for configuration management and binary distribution, written in Go for performance and delivered as a single binary or npm package.
|
|
18
|
+
|
|
19
|
+
It manages development tools and binaries across multiple platforms, handling downloads, SHA256 verification, caching, and execution. Configuration is defined in JavaScript (powered by the goja runtime), providing flexibility while maintaining type safety through TypeScript definitions.
|
|
20
|
+
|
|
21
|
+
### Target Audience
|
|
22
|
+
|
|
23
|
+
- **Config package creators** building opinionated tooling distributions
|
|
24
|
+
- **Development teams** standardizing tool versions and configurations
|
|
25
|
+
- **Projects** requiring reproducible development environments
|
|
26
|
+
|
|
27
|
+
## Key Features
|
|
28
|
+
|
|
29
|
+
- **Fast binary management** with SHA256 hash verification
|
|
30
|
+
- **JavaScript-based configuration** with TypeScript definitions
|
|
31
|
+
- **Multi-platform support**: darwin, linux, freebsd, openbsd, windows (amd64, arm64, aarch64)
|
|
32
|
+
- **Three app types**:
|
|
33
|
+
- `binary` - Self-managed binaries with URLs, hashes, and archive formats
|
|
34
|
+
- `uvx` - Python packages via uvx (e.g., yamllint)
|
|
35
|
+
- `pnpm` - npm packages via pnpm dlx (e.g., @mermaid-js/mermaid-cli, @slidev/cli)
|
|
36
|
+
- **Git hook integration** for pre-commit, commit-msg, and other hooks
|
|
37
|
+
- **Smart caching** using stable hash-based paths for reproducibility
|
|
38
|
+
- **Extensibility** - Build opinionated config packages on top
|
|
39
|
+
|
|
40
|
+
## Architecture
|
|
41
|
+
|
|
42
|
+
Datamitsu is designed as a **stable, rarely updated core engine** that provides the foundation for extensible configuration management:
|
|
43
|
+
|
|
44
|
+
### Core Components
|
|
45
|
+
|
|
46
|
+
**JavaScript Configuration Engine** ([internal/engine/](internal/engine/))
|
|
47
|
+
|
|
48
|
+
- Uses goja JavaScript runtime to evaluate configuration files
|
|
49
|
+
- Exposes console API, format utilities (YAML, TOML, INI), and tools API
|
|
50
|
+
- Configuration defined in [internal/config/config.js](internal/config/config.js)
|
|
51
|
+
|
|
52
|
+
**Binary Manager** ([internal/binmanager/](internal/binmanager/))
|
|
53
|
+
|
|
54
|
+
- Downloads binaries with hash verification
|
|
55
|
+
- Supports multiple archive formats: tar.gz, tar.xz, zip, gz, raw binaries
|
|
56
|
+
- Caches binaries in `{cache}/.bin/{name}/{configHash}` with lazy loading
|
|
57
|
+
- Executes binaries with environment passthrough
|
|
58
|
+
|
|
59
|
+
**File Traverser** ([internal/traverser/](internal/traverser/))
|
|
60
|
+
|
|
61
|
+
- Walks directory trees respecting .gitignore rules
|
|
62
|
+
- Custom gitignore matcher implementation
|
|
63
|
+
|
|
64
|
+
**CLI Commands** ([cmd/](cmd/))
|
|
65
|
+
|
|
66
|
+
- `exec` - Execute managed binaries
|
|
67
|
+
- `hook git` - Git hook management (pre-commit, commit-msg, etc.)
|
|
68
|
+
- `hook npm` - npm lifecycle script hooks (preinstall, postinstall, etc.)
|
|
69
|
+
- `init` - Initialization (TODO)
|
|
70
|
+
|
|
71
|
+
For detailed architecture documentation, see [CLAUDE.md](CLAUDE.md).
|
|
72
|
+
|
|
73
|
+
## Installation
|
|
74
|
+
|
|
75
|
+
### As Standalone Binary
|
|
76
|
+
|
|
77
|
+
```bash
|
|
78
|
+
# Clone and build
|
|
79
|
+
git clone https://github.com/shibanet0/s0conf.git
|
|
80
|
+
cd s0conf
|
|
81
|
+
pnpm build
|
|
82
|
+
|
|
83
|
+
# Or just build with Go (after building JS config)
|
|
84
|
+
go build
|
|
85
|
+
```
|
|
86
|
+
|
|
87
|
+
### As npm Package Dependency
|
|
88
|
+
|
|
89
|
+
```json
|
|
90
|
+
{
|
|
91
|
+
"dependencies": {
|
|
92
|
+
"datamitsu": "^0.0.0"
|
|
93
|
+
}
|
|
94
|
+
}
|
|
95
|
+
```
|
|
96
|
+
|
|
97
|
+
## Quick Start
|
|
98
|
+
|
|
99
|
+
Datamitsu provides several commands for managing development tools:
|
|
100
|
+
|
|
101
|
+
```bash
|
|
102
|
+
# Execute a managed binary
|
|
103
|
+
./datamitsu exec <appName> [args...]
|
|
104
|
+
|
|
105
|
+
# Git hook commands
|
|
106
|
+
./datamitsu hook git pre-commit
|
|
107
|
+
./datamitsu hook git commit-msg
|
|
108
|
+
|
|
109
|
+
# npm lifecycle hooks
|
|
110
|
+
./datamitsu hook npm preinstall
|
|
111
|
+
./datamitsu hook npm postinstall
|
|
112
|
+
```
|
|
113
|
+
|
|
114
|
+
*Note: Detailed usage examples and configuration guides will be added in future releases.*
|
|
115
|
+
|
|
116
|
+
## Development
|
|
117
|
+
|
|
118
|
+
### Building
|
|
119
|
+
|
|
120
|
+
```bash
|
|
121
|
+
# Build JavaScript config and Go binary
|
|
122
|
+
pnpm build
|
|
123
|
+
|
|
124
|
+
# This runs:
|
|
125
|
+
# 1. pnpm build:lib - Compiles TypeScript config to JavaScript
|
|
126
|
+
# 2. go build - Compiles Go binary
|
|
127
|
+
```
|
|
128
|
+
|
|
129
|
+
### Testing
|
|
130
|
+
|
|
131
|
+
```bash
|
|
132
|
+
# Run Go tests
|
|
133
|
+
go test ./...
|
|
134
|
+
|
|
135
|
+
# Or use pnpm
|
|
136
|
+
pnpm test
|
|
137
|
+
```
|
|
138
|
+
|
|
139
|
+
### Project Structure
|
|
140
|
+
|
|
141
|
+
- `cmd/` - CLI command implementations (cobra framework)
|
|
142
|
+
- `internal/binmanager/` - Binary download, verification, and execution
|
|
143
|
+
- `internal/config/` - JavaScript configuration files and engine
|
|
144
|
+
- `internal/engine/` - Goja JavaScript runtime integration
|
|
145
|
+
- `internal/traverser/` - File system traversal with gitignore support
|
|
146
|
+
- `internal/env/` - Environment and path utilities
|
|
147
|
+
- `internal/logger/` - Structured logging (zap)
|
|
148
|
+
- `internal/syslist/` - Platform detection and mapping
|
|
149
|
+
|
|
150
|
+
See [CLAUDE.md](CLAUDE.md) for detailed architecture and implementation notes.
|
|
151
|
+
|
|
152
|
+
## Extensibility Model
|
|
153
|
+
|
|
154
|
+
Datamitsu is designed to be extended. The core engine provides stable binary management and configuration capabilities, while opinionated configurations are built as separate packages.
|
|
155
|
+
|
|
156
|
+
### Building Opinionated Packages
|
|
157
|
+
|
|
158
|
+
You can create your own configuration packages on top of datamitsu:
|
|
159
|
+
|
|
160
|
+
1. **Create a new npm package** with datamitsu as a runtime dependency
|
|
161
|
+
2. **Define your configurations** for ESLint, Prettier, lefthook, etc.
|
|
162
|
+
3. **Include plugins and presets** specific to your team or project
|
|
163
|
+
4. **Distribute as an npm package** that others can install
|
|
164
|
+
|
|
165
|
+
Example structure:
|
|
166
|
+
|
|
167
|
+
```json
|
|
168
|
+
{
|
|
169
|
+
"name": "@yourscope/dev-config",
|
|
170
|
+
"dependencies": {
|
|
171
|
+
"datamitsu": "^0.0.0"
|
|
172
|
+
}
|
|
173
|
+
}
|
|
174
|
+
```
|
|
175
|
+
|
|
176
|
+
This approach keeps the core stable while allowing the ecosystem to grow with various opinionated configurations tailored to different needs.
|
|
177
|
+
|
|
178
|
+
## License
|
|
179
|
+
|
|
180
|
+
MIT - See [LICENSE](LICENSE) for details
|
|
181
|
+
|
|
182
|
+
## Contributing
|
|
183
|
+
|
|
184
|
+
This project is in early development. Contribution guidelines will be established as the project matures.
|
|
185
|
+
|
|
186
|
+
## Research & References
|
|
187
|
+
|
|
188
|
+
For research notes and tool references, see [docs/research.md](docs/research.md).
|
package/datamitsu.exe
ADDED
|
Binary file
|
package/package.json
ADDED
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@datamitsu/datamitsu-win32-x64",
|
|
3
|
+
"version": "0.0.1-alpha-1",
|
|
4
|
+
"description": "The Windows x64 binary for datamitsu, configuration management and binary distribution tool",
|
|
5
|
+
"repository": {
|
|
6
|
+
"type": "git",
|
|
7
|
+
"url": "git+https://github.com/shibanet0/s0conf.git"
|
|
8
|
+
},
|
|
9
|
+
"keywords": [
|
|
10
|
+
"datamitsu",
|
|
11
|
+
"config",
|
|
12
|
+
"binary",
|
|
13
|
+
"tools",
|
|
14
|
+
"linter"
|
|
15
|
+
],
|
|
16
|
+
"author": "Alexander Svinarev <shibanet0@gmail.com> (shibanet0.com)",
|
|
17
|
+
"license": "MIT",
|
|
18
|
+
"bugs": {
|
|
19
|
+
"url": "https://github.com/shibanet0/s0conf/issues"
|
|
20
|
+
},
|
|
21
|
+
"homepage": "https://github.com/shibanet0/s0conf#readme",
|
|
22
|
+
"os": ["win32"],
|
|
23
|
+
"cpu": ["x64"]
|
|
24
|
+
}
|