yjcli 0.1.0__tar.gz → 0.1.2__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.
- {yjcli-0.1.0 → yjcli-0.1.2}/PKG-INFO +11 -1
- {yjcli-0.1.0 → yjcli-0.1.2}/README.md +10 -0
- {yjcli-0.1.0 → yjcli-0.1.2}/pyproject.toml +1 -1
- {yjcli-0.1.0 → yjcli-0.1.2}/src/yjcli/data/skills/yj-arch-core/SKILL.md +10 -2
- {yjcli-0.1.0 → yjcli-0.1.2}/src/yjcli/data/templates/.gitignore +8 -0
- {yjcli-0.1.0 → yjcli-0.1.2}/src/yjcli/data/templates/AGENTS.md +2 -2
- {yjcli-0.1.0 → yjcli-0.1.2}/src/yjcli/data/templates/Makefile +3 -0
- {yjcli-0.1.0 → yjcli-0.1.2}/src/yjcli/data/templates/make.bat +2 -0
- yjcli-0.1.2/src/yjcli/data/templates/platform/envs/app/.env.examples +8 -0
- yjcli-0.1.2/src/yjcli/data/templates/platform/envs/app/.env.local-dev +4 -0
- {yjcli-0.1.0 → yjcli-0.1.2}/src/yjcli/data/templates/platform/envs/listen/.env.examples +3 -0
- yjcli-0.1.2/src/yjcli/data/templates/platform/envs/listen/.env.local-dev +6 -0
- {yjcli-0.1.0 → yjcli-0.1.2}/src/yjcli/data/templates/platform/envs/worker/.env.examples +3 -0
- yjcli-0.1.2/src/yjcli/data/templates/platform/envs/worker/.env.local-dev +4 -0
- {yjcli-0.1.0 → yjcli-0.1.2}/src/yjcli/data/templates/platform/frontend/vite.config.ts +1 -1
- {yjcli-0.1.0 → yjcli-0.1.2}/src/yjcli/data/templates/platform/scripts/run.bat +10 -14
- {yjcli-0.1.0 → yjcli-0.1.2}/src/yjcli/data/templates/platform/scripts/run.sh +11 -36
- yjcli-0.1.0/src/yjcli/data/templates/platform/envs/app/.env.examples +0 -5
- yjcli-0.1.0/src/yjcli/data/templates/platform/envs/app/.env.local-dev +0 -2
- yjcli-0.1.0/src/yjcli/data/templates/platform/envs/listen/.env.local-dev +0 -4
- yjcli-0.1.0/src/yjcli/data/templates/platform/envs/worker/.env.local-dev +0 -2
- {yjcli-0.1.0 → yjcli-0.1.2}/.gitignore +0 -0
- {yjcli-0.1.0 → yjcli-0.1.2}/LICENSE +0 -0
- {yjcli-0.1.0 → yjcli-0.1.2}/src/yjcli/__init__.py +0 -0
- {yjcli-0.1.0 → yjcli-0.1.2}/src/yjcli/__main__.py +0 -0
- {yjcli-0.1.0 → yjcli-0.1.2}/src/yjcli/cli.py +0 -0
- {yjcli-0.1.0 → yjcli-0.1.2}/src/yjcli/commands/__init__.py +0 -0
- {yjcli-0.1.0 → yjcli-0.1.2}/src/yjcli/commands/init_cmd.py +0 -0
- {yjcli-0.1.0 → yjcli-0.1.2}/src/yjcli/commands/platform.py +0 -0
- {yjcli-0.1.0 → yjcli-0.1.2}/src/yjcli/commands/service.py +0 -0
- {yjcli-0.1.0 → yjcli-0.1.2}/src/yjcli/commands/sync.py +0 -0
- {yjcli-0.1.0 → yjcli-0.1.2}/src/yjcli/data/__init__.py +0 -0
- {yjcli-0.1.0 → yjcli-0.1.2}/src/yjcli/data/skills/yj-backend-msa/SKILL.md +0 -0
- {yjcli-0.1.0 → yjcli-0.1.2}/src/yjcli/data/skills/yj-backend-service/SKILL.md +0 -0
- {yjcli-0.1.0 → yjcli-0.1.2}/src/yjcli/data/skills/yj-browser-extension/SKILL.md +0 -0
- {yjcli-0.1.0 → yjcli-0.1.2}/src/yjcli/data/skills/yj-cli/SKILL.md +0 -0
- {yjcli-0.1.0 → yjcli-0.1.2}/src/yjcli/data/skills/yj-frontend/SKILL.md +0 -0
- {yjcli-0.1.0 → yjcli-0.1.2}/src/yjcli/data/skills/yj-mobile-app/SKILL.md +0 -0
- {yjcli-0.1.0 → yjcli-0.1.2}/src/yjcli/data/skills/yj-pc-app/SKILL.md +0 -0
- {yjcli-0.1.0 → yjcli-0.1.2}/src/yjcli/data/templates/TOOLS.md +0 -0
- {yjcli-0.1.0 → yjcli-0.1.2}/src/yjcli/data/templates/platform/envs/app/.env.development +0 -0
- {yjcli-0.1.0 → yjcli-0.1.2}/src/yjcli/data/templates/platform/envs/app/.env.production +0 -0
- {yjcli-0.1.0 → yjcli-0.1.2}/src/yjcli/data/templates/platform/envs/listen/.env.development +0 -0
- {yjcli-0.1.0 → yjcli-0.1.2}/src/yjcli/data/templates/platform/envs/listen/.env.production +0 -0
- {yjcli-0.1.0 → yjcli-0.1.2}/src/yjcli/data/templates/platform/envs/worker/.env.development +0 -0
- {yjcli-0.1.0 → yjcli-0.1.2}/src/yjcli/data/templates/platform/envs/worker/.env.production +0 -0
- {yjcli-0.1.0 → yjcli-0.1.2}/src/yjcli/data/templates/platform/frontend/package.json +0 -0
- {yjcli-0.1.0 → yjcli-0.1.2}/src/yjcli/data/templates/settings.json +0 -0
- {yjcli-0.1.0 → yjcli-0.1.2}/src/yjcli/modules/__init__.py +0 -0
- {yjcli-0.1.0 → yjcli-0.1.2}/src/yjcli/modules/constants.py +0 -0
- {yjcli-0.1.0 → yjcli-0.1.2}/src/yjcli/modules/fsutil.py +0 -0
- {yjcli-0.1.0 → yjcli-0.1.2}/src/yjcli/modules/paths.py +0 -0
- {yjcli-0.1.0 → yjcli-0.1.2}/src/yjcli/modules/prompt.py +0 -0
- {yjcli-0.1.0 → yjcli-0.1.2}/src/yjcli/services/__init__.py +0 -0
- {yjcli-0.1.0 → yjcli-0.1.2}/src/yjcli/services/scaffold.py +0 -0
- {yjcli-0.1.0 → yjcli-0.1.2}/src/yjcli/services/status.py +0 -0
- {yjcli-0.1.0 → yjcli-0.1.2}/src/yjcli/services/sync.py +0 -0
- {yjcli-0.1.0 → yjcli-0.1.2}/src/yjcli/services/wiring.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: yjcli
|
|
3
|
-
Version: 0.1.
|
|
3
|
+
Version: 0.1.2
|
|
4
4
|
Summary: Scaffold platforms, services, and AI agent wiring (Cursor/Claude/Codex) for YJ architecture repos.
|
|
5
5
|
Project-URL: Homepage, https://github.com/yseiren87/yjcli
|
|
6
6
|
Project-URL: Repository, https://github.com/yseiren87/yjcli
|
|
@@ -78,12 +78,22 @@ Use with `-t` / `--type` (repeatable on `init` / `platform add`):
|
|
|
78
78
|
- Root `Makefile`, `make.bat`, `TOOLS.md`, `.gitignore`
|
|
79
79
|
- Selected platform roots (`*/scripts/run.sh` / `run.bat`)
|
|
80
80
|
|
|
81
|
+
The root `Makefile` / `make.bat` is the repository-owned extension point for
|
|
82
|
+
project automation. Projects may add commands such as `<platform>-build` or
|
|
83
|
+
`<platform>-deploy` and reuse optional `NAME=<service>` selection. Defining and
|
|
84
|
+
implementing init/install/build/deploy behavior is the project's responsibility;
|
|
85
|
+
yjcli does not generate action scripts. Do not add per-service `scripts/`
|
|
86
|
+
directories or per-service Makefiles.
|
|
87
|
+
|
|
81
88
|
Operating rules (skill routing, output discipline) are in `AGENTS.md` — not in
|
|
82
89
|
`.cursor/rules` / `.claude/rules`.
|
|
83
90
|
|
|
84
91
|
## Run (`make`)
|
|
85
92
|
|
|
86
93
|
Platform targets are discovered from `*/scripts/run.sh` (after `init` / `platform add`).
|
|
94
|
+
Each service declares its local command as `RUN_COMMAND` in `.env.local-dev`.
|
|
95
|
+
The platform runner executes that repository-owned declaration instead of
|
|
96
|
+
inferring npm, uv, Go, or another language/runtime from project manifests.
|
|
87
97
|
|
|
88
98
|
```bash
|
|
89
99
|
make <platform> # all services under that platform (concurrent)
|
|
@@ -53,12 +53,22 @@ Use with `-t` / `--type` (repeatable on `init` / `platform add`):
|
|
|
53
53
|
- Root `Makefile`, `make.bat`, `TOOLS.md`, `.gitignore`
|
|
54
54
|
- Selected platform roots (`*/scripts/run.sh` / `run.bat`)
|
|
55
55
|
|
|
56
|
+
The root `Makefile` / `make.bat` is the repository-owned extension point for
|
|
57
|
+
project automation. Projects may add commands such as `<platform>-build` or
|
|
58
|
+
`<platform>-deploy` and reuse optional `NAME=<service>` selection. Defining and
|
|
59
|
+
implementing init/install/build/deploy behavior is the project's responsibility;
|
|
60
|
+
yjcli does not generate action scripts. Do not add per-service `scripts/`
|
|
61
|
+
directories or per-service Makefiles.
|
|
62
|
+
|
|
56
63
|
Operating rules (skill routing, output discipline) are in `AGENTS.md` — not in
|
|
57
64
|
`.cursor/rules` / `.claude/rules`.
|
|
58
65
|
|
|
59
66
|
## Run (`make`)
|
|
60
67
|
|
|
61
68
|
Platform targets are discovered from `*/scripts/run.sh` (after `init` / `platform add`).
|
|
69
|
+
Each service declares its local command as `RUN_COMMAND` in `.env.local-dev`.
|
|
70
|
+
The platform runner executes that repository-owned declaration instead of
|
|
71
|
+
inferring npm, uv, Go, or another language/runtime from project manifests.
|
|
62
72
|
|
|
63
73
|
```bash
|
|
64
74
|
make <platform> # all services under that platform (concurrent)
|
|
@@ -41,9 +41,14 @@ browser-extension/ # yj-browser-extension
|
|
|
41
41
|
- `backend/proto/` is reserved (see yj-backend-msa).
|
|
42
42
|
- `browser-extension/native_{name}/` → **yj-backend-service**.
|
|
43
43
|
- Do not invent new platform roots or put app code at repo root.
|
|
44
|
-
- Do not
|
|
44
|
+
- Do not create a `Makefile` inside any service folder, including generic `run`,
|
|
45
|
+
`install`, or `help` targets. Do not add per-service `scripts/`.
|
|
45
46
|
Root `make <platform>` starts all services under that platform (concurrent); `NAME=<service>` runs one.
|
|
46
|
-
Platforms via `*/scripts/run
|
|
47
|
+
Platforms run via `*/scripts/run.*`; services are sibling dirs created with `yjcli service add`.
|
|
48
|
+
- The root `Makefile` / `make.bat` is repository-owned and may be extended. Prefer
|
|
49
|
+
`<platform>-<action> [NAME=<service>]` when an action should target all services
|
|
50
|
+
or one service (for example, `backend-deploy`). The repository owns and implements
|
|
51
|
+
actions such as init/install/build/deploy; yjcli does not generate action scripts.
|
|
47
52
|
|
|
48
53
|
|
|
49
54
|
## Environment (guardrails only)
|
|
@@ -61,6 +66,9 @@ Allowed files at each service root (no plain `.env`):
|
|
|
61
66
|
- `HOST`/`PORT` are required for `listen`. For `worker` they are optional — add only if needed.
|
|
62
67
|
- Commit `.env.examples` only; never commit the other three.
|
|
63
68
|
- Local platform `run.*` uses `.env.local-dev` only — do not hardcode HOST/PORT in scripts.
|
|
69
|
+
- Each service declares its repository-owned local `RUN_COMMAND` in `.env.local-dev`.
|
|
70
|
+
Platform `run.*` must execute that declaration and must not infer commands from
|
|
71
|
+
`package.json`, `pyproject.toml`, `go.mod`, or other language/runtime manifests.
|
|
64
72
|
|
|
65
73
|
## Skill routing
|
|
66
74
|
|
|
@@ -35,6 +35,14 @@ Desktop.ini
|
|
|
35
35
|
.env.*
|
|
36
36
|
!.env.examples
|
|
37
37
|
|
|
38
|
+
# Keep yjcli's packaged env source templates when this file lives under data/templates.
|
|
39
|
+
# These paths do not match generated service env files in a target repository.
|
|
40
|
+
!platform/envs/
|
|
41
|
+
!platform/envs/*/
|
|
42
|
+
!platform/envs/*/.env.local-dev
|
|
43
|
+
!platform/envs/*/.env.development
|
|
44
|
+
!platform/envs/*/.env.production
|
|
45
|
+
|
|
38
46
|
# ----- Logs / debug -----
|
|
39
47
|
logs/
|
|
40
48
|
*.log
|
|
@@ -57,8 +57,8 @@ Paths from `yjcli init` are fixed; add platform/app rows with `<path>` / `<role>
|
|
|
57
57
|
| `AGENTS.md` | Agent / contributor guide (this file) — source of truth |
|
|
58
58
|
| `CLAUDE.md` | Mirror of `AGENTS.md` — do not edit; refresh with `yjcli sync agents` |
|
|
59
59
|
| `TOOLS.md` | Release-tools feature spec (version / deploy / git) |
|
|
60
|
-
| `Makefile` |
|
|
61
|
-
| `make.bat` | Windows counterpart of root Makefile |
|
|
60
|
+
| `Makefile` | Extensible root entry — `make <platform>` (all services) or `NAME=<service>` (one); repository may add `<platform>-<action>` targets |
|
|
61
|
+
| `make.bat` | Extensible Windows counterpart of root Makefile |
|
|
62
62
|
| `.gitignore` | Canonical ignore rules |
|
|
63
63
|
| `.cursor/skills/` | Cursor skills (copied from package) |
|
|
64
64
|
| `.claude/skills/` | Claude skills (copied from package) |
|
|
@@ -2,6 +2,9 @@
|
|
|
2
2
|
# Usage:
|
|
3
3
|
# make <platform> # all services under that platform (concurrent)
|
|
4
4
|
# make <platform> NAME=<service> # one service
|
|
5
|
+
# Extend this root file for repository-owned work when needed. A useful pattern
|
|
6
|
+
# is <platform>-<action> with the same optional NAME selector, for example
|
|
7
|
+
# `make backend-deploy [NAME=api]`. yjcli does not define those actions.
|
|
5
8
|
|
|
6
9
|
PLATFORMS := $(patsubst %/scripts/run.sh,%,$(wildcard */scripts/run.sh))
|
|
7
10
|
|
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
@echo off
|
|
2
2
|
setlocal EnableExtensions EnableDelayedExpansion
|
|
3
|
+
rem Extend this root file with repository-owned platform-action commands as needed,
|
|
4
|
+
rem for example: make.bat backend-deploy NAME=api. yjcli does not define them.
|
|
3
5
|
|
|
4
6
|
if /I "%~1"=="" goto help
|
|
5
7
|
if /I "%~1"=="help" goto help
|
|
@@ -3,7 +3,7 @@ import react from "@vitejs/plugin-react";
|
|
|
3
3
|
|
|
4
4
|
// Env files (yj-arch-core): .env.local-dev | .env.development | .env.production
|
|
5
5
|
// Loaded via Vite --mode (no plain .env).
|
|
6
|
-
// Platform run
|
|
6
|
+
// Platform run.* always exports values from .env.local-dev before RUN_COMMAND.
|
|
7
7
|
|
|
8
8
|
export default defineConfig(({ mode }) => {
|
|
9
9
|
const env = loadEnv(mode, process.cwd(), "");
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
@echo off
|
|
2
2
|
setlocal EnableExtensions EnableDelayedExpansion
|
|
3
|
+
rem The service owns RUN_COMMAND; this runner does not infer a language/runtime.
|
|
3
4
|
set "PLATFORM_DIR=%~dp0.."
|
|
4
5
|
cd /d "%PLATFORM_DIR%"
|
|
5
6
|
|
|
@@ -31,7 +32,8 @@ if not exist "%ENV_FILE%" (
|
|
|
31
32
|
|
|
32
33
|
rem Load KEY=VALUE from .env.local-dev
|
|
33
34
|
for /f "usebackq tokens=1* delims==" %%A in (`findstr /R "^[A-Za-z_][A-Za-z0-9_]*=" "%ENV_FILE%"`) do (
|
|
34
|
-
|
|
35
|
+
rem %%~B removes optional dotenv quotes while preserving the value text.
|
|
36
|
+
set "%%A=%%~B"
|
|
35
37
|
)
|
|
36
38
|
|
|
37
39
|
echo [%NAME%] env: %ENV_FILE%
|
|
@@ -45,21 +47,15 @@ call :kill_by_pidfile
|
|
|
45
47
|
|
|
46
48
|
cd /d "%SERVICE_DIR%"
|
|
47
49
|
|
|
48
|
-
if
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
if exist "package.json" (
|
|
54
|
-
set "EXTRA="
|
|
55
|
-
if defined HOST set "EXTRA=!EXTRA! --host %HOST%"
|
|
56
|
-
if defined PORT set "EXTRA=!EXTRA! --port %PORT%"
|
|
57
|
-
call npm start -- !EXTRA! %*
|
|
58
|
-
exit /b %ERRORLEVEL%
|
|
50
|
+
if not defined RUN_COMMAND (
|
|
51
|
+
echo [%NAME%] RUN_COMMAND is unset in %ENV_FILE%
|
|
52
|
+
echo Declare the service-owned local command, for example: RUN_COMMAND=your-command --flag
|
|
53
|
+
exit /b 1
|
|
59
54
|
)
|
|
60
55
|
|
|
61
|
-
echo [%NAME%]
|
|
62
|
-
|
|
56
|
+
echo [%NAME%] command: !RUN_COMMAND!
|
|
57
|
+
call !RUN_COMMAND! %*
|
|
58
|
+
exit /b %ERRORLEVEL%
|
|
63
59
|
|
|
64
60
|
:run_all
|
|
65
61
|
set "ANY="
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
#!/usr/bin/env bash
|
|
2
2
|
# Run service(s) under this platform.
|
|
3
3
|
# Always loads {service}/.env.local-dev (never development/production).
|
|
4
|
+
# The service owns RUN_COMMAND; this runner does not infer a language/runtime.
|
|
4
5
|
# Usage:
|
|
5
6
|
# ./scripts/run.sh # all services concurrently
|
|
6
7
|
# ./scripts/run.sh <service> [args...]
|
|
@@ -111,44 +112,18 @@ run_one() {
|
|
|
111
112
|
exit "$code"
|
|
112
113
|
}
|
|
113
114
|
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
export PORT="${PORT:-}"
|
|
119
|
-
start_and_track make run "$@"
|
|
120
|
-
fi
|
|
121
|
-
|
|
122
|
-
if [ -f "package.json" ]; then
|
|
123
|
-
export HOST="${HOST:-}"
|
|
124
|
-
export PORT="${PORT:-}"
|
|
125
|
-
local -a extra=()
|
|
126
|
-
if [ -n "${HOST:-}" ]; then
|
|
127
|
-
extra+=(--host "$HOST")
|
|
128
|
-
fi
|
|
129
|
-
if [ -n "${PORT:-}" ]; then
|
|
130
|
-
extra+=(--port "$PORT")
|
|
131
|
-
fi
|
|
132
|
-
if npm run | grep -qE '^ start$'; then
|
|
133
|
-
if [ "${#extra[@]}" -gt 0 ]; then
|
|
134
|
-
start_and_track npm start -- "${extra[@]}" "$@"
|
|
135
|
-
else
|
|
136
|
-
start_and_track npm start -- "$@"
|
|
137
|
-
fi
|
|
138
|
-
fi
|
|
139
|
-
if npm run | grep -qE '^ dev$'; then
|
|
140
|
-
if [ "${#extra[@]}" -gt 0 ]; then
|
|
141
|
-
start_and_track npm run dev -- "${extra[@]}" "$@"
|
|
142
|
-
else
|
|
143
|
-
start_and_track npm run dev -- "$@"
|
|
144
|
-
fi
|
|
145
|
-
fi
|
|
146
|
-
start_and_track npm start -- "$@"
|
|
115
|
+
if [ -z "${RUN_COMMAND:-}" ]; then
|
|
116
|
+
echo "[$NAME] RUN_COMMAND is unset in $ENV_FILE"
|
|
117
|
+
echo "Declare the service-owned local command, for example: RUN_COMMAND=\"your-command --flag\""
|
|
118
|
+
return 1
|
|
147
119
|
fi
|
|
148
120
|
|
|
149
|
-
|
|
150
|
-
echo "
|
|
151
|
-
|
|
121
|
+
cd "$SERVICE_DIR"
|
|
122
|
+
echo "[$NAME] command: $RUN_COMMAND"
|
|
123
|
+
# RUN_COMMAND is trusted, repository-owned configuration. Execute it through
|
|
124
|
+
# the platform shell so one contract works for any repository-selected tool.
|
|
125
|
+
# Extra arguments supplied after the service name are appended as "$@".
|
|
126
|
+
start_and_track bash -c "$RUN_COMMAND \"\$@\"" yjcli-run "$@"
|
|
152
127
|
}
|
|
153
128
|
|
|
154
129
|
run_all() {
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|