structkit 3.2.0__py3-none-any.whl → 3.3.0__py3-none-any.whl
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.
- structkit/commands/completion.py +1 -3
- structkit/commands/config.py +82 -0
- structkit/commands/generate.py +137 -4
- structkit/commands/init.py +20 -7
- structkit/config.py +202 -0
- structkit/contribs/README.md +2 -2
- structkit/contribs/github/prompts/struct.yaml +3 -3
- structkit/contribs/github/workflows/run-struct.yaml +3 -3
- structkit/file_item.py +2 -0
- structkit/filters.py +79 -15
- structkit/main.py +113 -8
- structkit/mcp_server.py +7 -1
- structkit/project_file.py +113 -0
- {structkit-3.2.0.dist-info → structkit-3.3.0.dist-info}/METADATA +22 -7
- {structkit-3.2.0.dist-info → structkit-3.3.0.dist-info}/RECORD +19 -16
- {structkit-3.2.0.dist-info → structkit-3.3.0.dist-info}/WHEEL +1 -1
- {structkit-3.2.0.dist-info → structkit-3.3.0.dist-info}/entry_points.txt +0 -0
- {structkit-3.2.0.dist-info → structkit-3.3.0.dist-info}/licenses/LICENSE +0 -0
- {structkit-3.2.0.dist-info → structkit-3.3.0.dist-info}/top_level.txt +0 -0
structkit/commands/completion.py
CHANGED
|
@@ -51,9 +51,7 @@ class CompletionCommand(Command):
|
|
|
51
51
|
print("exec zsh")
|
|
52
52
|
|
|
53
53
|
elif shell == "fish":
|
|
54
|
-
print("\n#
|
|
55
|
-
print("python -m pip install shtab")
|
|
56
|
-
print("\n# Generate static fish completion for 'struct':")
|
|
54
|
+
print("\n# Generate static fish completion for 'structkit':")
|
|
57
55
|
print('mkdir -p ~/.config/fish/completions')
|
|
58
56
|
print('structkit --print-completion fish > ~/.config/fish/completions/structkit.fish')
|
|
59
57
|
print("\n# Apply now:")
|
|
@@ -0,0 +1,82 @@
|
|
|
1
|
+
"""Config command for displaying effective configuration."""
|
|
2
|
+
|
|
3
|
+
from structkit.commands import Command
|
|
4
|
+
import yaml
|
|
5
|
+
import json
|
|
6
|
+
from structkit.config import get_effective_config, get_user_config_path, get_builtin_defaults
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
class ConfigCommand(Command):
|
|
10
|
+
def __init__(self, parser):
|
|
11
|
+
# Don't call super().__init__() yet - we need to set up subparsers first
|
|
12
|
+
self.parser = parser
|
|
13
|
+
import logging
|
|
14
|
+
self.logger = logging.getLogger(__name__)
|
|
15
|
+
|
|
16
|
+
parser.description = "Display and manage structkit configuration"
|
|
17
|
+
|
|
18
|
+
# Create subparsers for config subcommands
|
|
19
|
+
subparsers = parser.add_subparsers(dest='config_subcommand', help='Config subcommand')
|
|
20
|
+
|
|
21
|
+
# print subcommand
|
|
22
|
+
print_parser = subparsers.add_parser('print', help='Print the effective configuration')
|
|
23
|
+
print_parser.add_argument(
|
|
24
|
+
'--format',
|
|
25
|
+
type=str,
|
|
26
|
+
choices=['yaml', 'json'],
|
|
27
|
+
default='yaml',
|
|
28
|
+
help='Output format (default: yaml)'
|
|
29
|
+
)
|
|
30
|
+
print_parser.set_defaults(config_func=self.print_config)
|
|
31
|
+
|
|
32
|
+
# Add common arguments to the main parser and all subparsers
|
|
33
|
+
for p in [parser, print_parser]:
|
|
34
|
+
self._add_common_args(p)
|
|
35
|
+
|
|
36
|
+
parser.set_defaults(func=self.execute)
|
|
37
|
+
|
|
38
|
+
def _add_common_args(self, parser):
|
|
39
|
+
"""Add common arguments to a parser (replicating Command base class)."""
|
|
40
|
+
from structkit.completers import log_level_completer
|
|
41
|
+
parser.add_argument('-l', '--log', type=str, default='INFO', help='Set the logging level (DEBUG, INFO, WARNING, ERROR, CRITICAL)').completer = log_level_completer
|
|
42
|
+
parser.add_argument('-c', '--config-file', type=str, help='Path to a configuration file')
|
|
43
|
+
parser.add_argument('-i', '--log-file', type=str, help='Path to a log file')
|
|
44
|
+
|
|
45
|
+
def execute(self, args):
|
|
46
|
+
"""Execute the config command."""
|
|
47
|
+
# If no subcommand is provided, show help
|
|
48
|
+
if not hasattr(args, 'config_func'):
|
|
49
|
+
self.parser.print_help()
|
|
50
|
+
return
|
|
51
|
+
|
|
52
|
+
# Execute the subcommand
|
|
53
|
+
args.config_func(args)
|
|
54
|
+
|
|
55
|
+
def print_config(self, args):
|
|
56
|
+
"""Print the effective configuration after all layers are merged.
|
|
57
|
+
|
|
58
|
+
This shows the final configuration that structkit would use,
|
|
59
|
+
combining built-in defaults, user config, project config, and CLI args.
|
|
60
|
+
"""
|
|
61
|
+
# Get effective config
|
|
62
|
+
effective_config = get_effective_config(args)
|
|
63
|
+
|
|
64
|
+
# Format and print
|
|
65
|
+
if args.format == 'json':
|
|
66
|
+
output = json.dumps(effective_config, indent=2, sort_keys=True)
|
|
67
|
+
else: # yaml
|
|
68
|
+
output = yaml.dump(effective_config, default_flow_style=False, sort_keys=True)
|
|
69
|
+
|
|
70
|
+
print(output.rstrip())
|
|
71
|
+
|
|
72
|
+
# Show config sources
|
|
73
|
+
user_config_path = get_user_config_path()
|
|
74
|
+
self.logger.info("")
|
|
75
|
+
self.logger.info("Configuration sources:")
|
|
76
|
+
self.logger.info(" 1. Built-in defaults: always loaded")
|
|
77
|
+
self.logger.info(f" 2. User config: {user_config_path} {'(exists)' if user_config_path.exists() else '(not found)'}")
|
|
78
|
+
if hasattr(args, 'config_file') and args.config_file:
|
|
79
|
+
self.logger.info(f" 3. Project config: {args.config_file}")
|
|
80
|
+
else:
|
|
81
|
+
self.logger.info(" 3. Project config: none specified")
|
|
82
|
+
self.logger.info(" 4. CLI arguments: highest priority")
|
structkit/commands/generate.py
CHANGED
|
@@ -8,6 +8,11 @@ from structkit.template_renderer import TemplateRenderer, TemplateVariableError
|
|
|
8
8
|
from structkit.sources import SourceError, resolve_structures_path
|
|
9
9
|
from structkit.struct_refs import SourceContext, resolve_struct_reference
|
|
10
10
|
from structkit.input_store import InputStoreError
|
|
11
|
+
from structkit.project_file import (
|
|
12
|
+
CANONICAL_PROJECT_STRUCT_FILE,
|
|
13
|
+
LEGACY_PROJECT_STRUCT_FILE,
|
|
14
|
+
resolve_project_struct_file,
|
|
15
|
+
)
|
|
11
16
|
|
|
12
17
|
import subprocess
|
|
13
18
|
|
|
@@ -21,7 +26,16 @@ class GenerateCommand(Command):
|
|
|
21
26
|
def __init__(self, parser):
|
|
22
27
|
super().__init__(parser)
|
|
23
28
|
parser.description = "Generate the project structure from a YAML configuration file"
|
|
24
|
-
structure_arg = parser.add_argument(
|
|
29
|
+
structure_arg = parser.add_argument(
|
|
30
|
+
'structure_definition',
|
|
31
|
+
nargs='?',
|
|
32
|
+
default=CANONICAL_PROJECT_STRUCT_FILE,
|
|
33
|
+
type=str,
|
|
34
|
+
help=(
|
|
35
|
+
f'Path to the YAML configuration file (default: {CANONICAL_PROJECT_STRUCT_FILE}; '
|
|
36
|
+
f'falls back to {LEGACY_PROJECT_STRUCT_FILE} for compatibility)'
|
|
37
|
+
),
|
|
38
|
+
)
|
|
25
39
|
structure_arg.completer = structures_completer
|
|
26
40
|
parser.add_argument('base_path', nargs='?', default='.', type=str, help='Base path where the structure will be created (default: current directory)')
|
|
27
41
|
parser.add_argument(
|
|
@@ -50,6 +64,8 @@ class GenerateCommand(Command):
|
|
|
50
64
|
help='Path to a YAML file containing mappings to be used in templates (can be specified multiple times)')
|
|
51
65
|
parser.add_argument('-o', '--output', type=str,
|
|
52
66
|
choices=['console', 'file'], default=os.getenv('STRUCTKIT_OUTPUT_MODE', 'file'), help='Output mode (env: STRUCTKIT_OUTPUT_MODE)')
|
|
67
|
+
parser.add_argument('--no-hooks', action='store_true', help='Skip all pre/post hooks (env: STRUCTKIT_NO_HOOKS)', default=os.getenv('STRUCTKIT_NO_HOOKS', '').lower() in ('true', '1', 'yes'))
|
|
68
|
+
parser.add_argument('--hooks-allowlist', type=str, help='Path to hooks allowlist file (env: STRUCTKIT_HOOKS_ALLOWLIST)', default=os.getenv('STRUCTKIT_HOOKS_ALLOWLIST', None))
|
|
53
69
|
parser.set_defaults(func=self.execute)
|
|
54
70
|
|
|
55
71
|
def _parse_template_vars(self, vars_str):
|
|
@@ -91,9 +107,108 @@ class GenerateCommand(Command):
|
|
|
91
107
|
result[key] = value
|
|
92
108
|
return result
|
|
93
109
|
|
|
94
|
-
def
|
|
110
|
+
def _load_hooks_allowlist(self, allowlist_path):
|
|
111
|
+
"""Load the hooks allowlist from a file.
|
|
112
|
+
Returns a set of allowed commands or None if file doesn't exist.
|
|
113
|
+
"""
|
|
114
|
+
if not allowlist_path:
|
|
115
|
+
return None
|
|
116
|
+
|
|
117
|
+
allowlist_file = None
|
|
118
|
+
if os.path.isabs(allowlist_path):
|
|
119
|
+
allowlist_file = allowlist_path
|
|
120
|
+
else:
|
|
121
|
+
allowlist_file = os.path.join(os.getcwd(), allowlist_path)
|
|
122
|
+
|
|
123
|
+
if not os.path.exists(allowlist_file):
|
|
124
|
+
# Also check for .struct-hooks-allowlist in current directory if no explicit path given
|
|
125
|
+
default_allowlist = os.path.join(os.getcwd(), '.struct-hooks-allowlist')
|
|
126
|
+
if allowlist_path == default_allowlist and not os.path.exists(default_allowlist):
|
|
127
|
+
return None
|
|
128
|
+
self.logger.warning(f"Hooks allowlist file not found: {allowlist_file}")
|
|
129
|
+
return None
|
|
130
|
+
|
|
131
|
+
try:
|
|
132
|
+
with open(allowlist_file, 'r') as f:
|
|
133
|
+
lines = f.readlines()
|
|
134
|
+
# Parse allowlist: ignore empty lines and comments (lines starting with #)
|
|
135
|
+
allowlist = set()
|
|
136
|
+
for line in lines:
|
|
137
|
+
line = line.strip()
|
|
138
|
+
if line and not line.startswith('#'):
|
|
139
|
+
allowlist.add(line)
|
|
140
|
+
return allowlist
|
|
141
|
+
except Exception as e:
|
|
142
|
+
self.logger.error(f"Failed to read hooks allowlist: {e}")
|
|
143
|
+
return None
|
|
144
|
+
|
|
145
|
+
def _check_hook_allowed(self, cmd, allowlist):
|
|
146
|
+
"""Check if a command is allowed by the allowlist.
|
|
147
|
+
If allowlist is None, all commands are allowed.
|
|
148
|
+
If allowlist is a set, only commands in the set are allowed.
|
|
149
|
+
"""
|
|
150
|
+
if allowlist is None:
|
|
151
|
+
return True
|
|
152
|
+
|
|
153
|
+
# Check exact match first
|
|
154
|
+
if cmd in allowlist:
|
|
155
|
+
return True
|
|
156
|
+
|
|
157
|
+
# Check if the base command (first word) is allowed
|
|
158
|
+
base_cmd = cmd.split()[0] if cmd.split() else cmd
|
|
159
|
+
if base_cmd in allowlist:
|
|
160
|
+
return True
|
|
161
|
+
|
|
162
|
+
return False
|
|
163
|
+
|
|
164
|
+
def _confirm_hooks(self, hooks, hook_type="pre"):
|
|
165
|
+
"""Ask user to confirm hook execution.
|
|
166
|
+
Returns True if user confirms, False otherwise.
|
|
167
|
+
"""
|
|
95
168
|
if not hooks:
|
|
96
169
|
return True
|
|
170
|
+
|
|
171
|
+
print(f"\n⚠️ The following {hook_type}-hooks will be executed:")
|
|
172
|
+
for cmd in hooks:
|
|
173
|
+
print(f" - {cmd}")
|
|
174
|
+
|
|
175
|
+
response = input(f"\nDo you want to run these {hook_type}-hooks? [y/N]: ").strip().lower()
|
|
176
|
+
return response in ('y', 'yes')
|
|
177
|
+
|
|
178
|
+
def _run_hooks(self, hooks, hook_type="pre", skip_hooks=False, non_interactive=False, allowlist=None):
|
|
179
|
+
"""Run pre/post hooks with safety controls.
|
|
180
|
+
|
|
181
|
+
Args:
|
|
182
|
+
hooks: List of shell commands to run
|
|
183
|
+
hook_type: Type of hooks ("pre" or "post")
|
|
184
|
+
skip_hooks: If True, skip all hooks
|
|
185
|
+
non_interactive: If True, skip confirmation prompt
|
|
186
|
+
allowlist: Set of allowed commands or None to allow all
|
|
187
|
+
|
|
188
|
+
Returns:
|
|
189
|
+
True if all hooks succeeded or were skipped, False if any failed
|
|
190
|
+
"""
|
|
191
|
+
if not hooks or skip_hooks:
|
|
192
|
+
if skip_hooks and hooks:
|
|
193
|
+
self.logger.info(f"Skipping {hook_type}-hooks (--no-hooks enabled)")
|
|
194
|
+
return True
|
|
195
|
+
|
|
196
|
+
# Check if any hooks are blocked by allowlist
|
|
197
|
+
if allowlist is not None:
|
|
198
|
+
blocked_hooks = [cmd for cmd in hooks if not self._check_hook_allowed(cmd, allowlist)]
|
|
199
|
+
if blocked_hooks:
|
|
200
|
+
self.logger.error(f"The following {hook_type}-hooks are not in the allowlist:")
|
|
201
|
+
for cmd in blocked_hooks:
|
|
202
|
+
self.logger.error(f" - {cmd}")
|
|
203
|
+
self.logger.error("Hook execution blocked. Update allowlist or use --no-hooks to skip.")
|
|
204
|
+
return False
|
|
205
|
+
|
|
206
|
+
# Ask for confirmation in interactive mode
|
|
207
|
+
if not non_interactive:
|
|
208
|
+
if not self._confirm_hooks(hooks, hook_type):
|
|
209
|
+
self.logger.info(f"User declined to run {hook_type}-hooks. Aborting.")
|
|
210
|
+
return False
|
|
211
|
+
|
|
97
212
|
for cmd in hooks:
|
|
98
213
|
self.logger.info(f"Running {hook_type}-hook: {cmd}")
|
|
99
214
|
try:
|
|
@@ -145,6 +260,9 @@ class GenerateCommand(Command):
|
|
|
145
260
|
return config
|
|
146
261
|
|
|
147
262
|
def execute(self, args):
|
|
263
|
+
args.structure_definition = resolve_project_struct_file(
|
|
264
|
+
explicit_path=getattr(args, 'structure_definition', None),
|
|
265
|
+
)
|
|
148
266
|
try:
|
|
149
267
|
args.structures_path, args.structure_definition = resolve_structures_path(
|
|
150
268
|
args.structures_path,
|
|
@@ -201,8 +319,23 @@ class GenerateCommand(Command):
|
|
|
201
319
|
pre_hooks = config.get('pre_hooks', [])
|
|
202
320
|
post_hooks = config.get('post_hooks', [])
|
|
203
321
|
|
|
322
|
+
skip_hooks = getattr(args, 'no_hooks', False)
|
|
323
|
+
non_interactive = getattr(args, 'non_interactive', False)
|
|
324
|
+
|
|
325
|
+
# Load hooks allowlist if provided (only if hooks are enabled)
|
|
326
|
+
allowlist = None
|
|
327
|
+
if not skip_hooks:
|
|
328
|
+
allowlist_path = getattr(args, 'hooks_allowlist', None)
|
|
329
|
+
if not allowlist_path:
|
|
330
|
+
# Check for default .struct-hooks-allowlist in current directory
|
|
331
|
+
default_allowlist = os.path.join(os.getcwd(), '.struct-hooks-allowlist')
|
|
332
|
+
if os.path.exists(default_allowlist):
|
|
333
|
+
allowlist_path = default_allowlist
|
|
334
|
+
|
|
335
|
+
allowlist = self._load_hooks_allowlist(allowlist_path) if allowlist_path else None
|
|
336
|
+
|
|
204
337
|
# Run pre-hooks
|
|
205
|
-
if not self._run_hooks(pre_hooks, hook_type="pre"):
|
|
338
|
+
if not self._run_hooks(pre_hooks, hook_type="pre", skip_hooks=skip_hooks, non_interactive=non_interactive, allowlist=allowlist):
|
|
206
339
|
self.logger.error("Aborting generation due to pre-hook failure.")
|
|
207
340
|
return
|
|
208
341
|
|
|
@@ -214,7 +347,7 @@ class GenerateCommand(Command):
|
|
|
214
347
|
raise SystemExit(1) from None
|
|
215
348
|
|
|
216
349
|
# Run post-hooks
|
|
217
|
-
if not self._run_hooks(post_hooks, hook_type="post"):
|
|
350
|
+
if not self._run_hooks(post_hooks, hook_type="post", skip_hooks=skip_hooks, non_interactive=non_interactive, allowlist=allowlist):
|
|
218
351
|
self.logger.error("Post-hook failed.")
|
|
219
352
|
return
|
|
220
353
|
|
structkit/commands/init.py
CHANGED
|
@@ -1,6 +1,10 @@
|
|
|
1
1
|
from structkit.commands import Command
|
|
2
2
|
import os
|
|
3
3
|
import textwrap
|
|
4
|
+
from structkit.project_file import (
|
|
5
|
+
CANONICAL_PROJECT_STRUCT_FILE,
|
|
6
|
+
LEGACY_PROJECT_STRUCT_FILE,
|
|
7
|
+
)
|
|
4
8
|
|
|
5
9
|
BASIC_STRUCTKIT_YAML = textwrap.dedent(
|
|
6
10
|
"""
|
|
@@ -17,7 +21,7 @@ BASIC_STRUCTKIT_YAML = textwrap.dedent(
|
|
|
17
21
|
- README.md: |
|
|
18
22
|
# Project
|
|
19
23
|
|
|
20
|
-
Initialized with
|
|
24
|
+
Initialized with structkit.
|
|
21
25
|
|
|
22
26
|
folders:
|
|
23
27
|
- ./:
|
|
@@ -30,24 +34,33 @@ BASIC_STRUCTKIT_YAML = textwrap.dedent(
|
|
|
30
34
|
class InitCommand(Command):
|
|
31
35
|
def __init__(self, parser):
|
|
32
36
|
super().__init__(parser)
|
|
33
|
-
parser.description = "Initialize a basic
|
|
37
|
+
parser.description = f"Initialize a basic {CANONICAL_PROJECT_STRUCT_FILE} in the target directory"
|
|
34
38
|
parser.add_argument('path', nargs='?', default='.', help='Directory to initialize (default: current directory)')
|
|
35
39
|
parser.set_defaults(func=self.execute)
|
|
36
40
|
|
|
37
41
|
def execute(self, args):
|
|
38
42
|
base_path = os.path.abspath(args.path or '.')
|
|
39
|
-
target = os.path.join(base_path,
|
|
43
|
+
target = os.path.join(base_path, CANONICAL_PROJECT_STRUCT_FILE)
|
|
44
|
+
legacy = os.path.join(base_path, LEGACY_PROJECT_STRUCT_FILE)
|
|
40
45
|
|
|
41
46
|
os.makedirs(base_path, exist_ok=True)
|
|
42
47
|
|
|
43
|
-
# If file exists, do not overwrite
|
|
48
|
+
# If either canonical or legacy file exists, do not overwrite.
|
|
44
49
|
if os.path.exists(target):
|
|
45
|
-
self.logger.info(f"
|
|
46
|
-
print(f"⚠️
|
|
50
|
+
self.logger.info(f"{CANONICAL_PROJECT_STRUCT_FILE} already exists at {target}, skipping creation")
|
|
51
|
+
print(f"⚠️ {CANONICAL_PROJECT_STRUCT_FILE} already exists at: {target}")
|
|
52
|
+
return
|
|
53
|
+
|
|
54
|
+
if os.path.exists(legacy):
|
|
55
|
+
self.logger.info(
|
|
56
|
+
f"{LEGACY_PROJECT_STRUCT_FILE} already exists at {legacy}, skipping creation"
|
|
57
|
+
)
|
|
58
|
+
print(f"⚠️ {LEGACY_PROJECT_STRUCT_FILE} already exists at: {legacy}")
|
|
59
|
+
print(f" Consider renaming it to {CANONICAL_PROJECT_STRUCT_FILE}.")
|
|
47
60
|
return
|
|
48
61
|
|
|
49
62
|
with open(target, 'w') as f:
|
|
50
63
|
f.write(BASIC_STRUCTKIT_YAML)
|
|
51
64
|
|
|
52
|
-
print("✅ Created
|
|
65
|
+
print(f"✅ Created {CANONICAL_PROJECT_STRUCT_FILE}")
|
|
53
66
|
print(f" - {target}")
|
structkit/config.py
ADDED
|
@@ -0,0 +1,202 @@
|
|
|
1
|
+
"""Configuration layering system for structkit.
|
|
2
|
+
|
|
3
|
+
Supports loading and merging configuration from multiple sources:
|
|
4
|
+
1. Built-in defaults
|
|
5
|
+
2. User config (~/.config/struct/config.yaml)
|
|
6
|
+
3. Project config (.structkit.yaml, legacy .struct.yaml, or --config-file)
|
|
7
|
+
4. CLI arguments
|
|
8
|
+
|
|
9
|
+
Priority order: CLI args > Project config > User config > Built-in defaults
|
|
10
|
+
"""
|
|
11
|
+
|
|
12
|
+
import os
|
|
13
|
+
import yaml
|
|
14
|
+
from pathlib import Path
|
|
15
|
+
from typing import Dict, Any, Optional
|
|
16
|
+
import logging
|
|
17
|
+
|
|
18
|
+
logger = logging.getLogger(__name__)
|
|
19
|
+
|
|
20
|
+
|
|
21
|
+
def get_user_config_path() -> Path:
|
|
22
|
+
"""Get the path to the user config file.
|
|
23
|
+
|
|
24
|
+
Returns ~/.config/struct/config.yaml
|
|
25
|
+
"""
|
|
26
|
+
return Path.home() / ".config" / "struct" / "config.yaml"
|
|
27
|
+
|
|
28
|
+
|
|
29
|
+
def get_builtin_defaults() -> Dict[str, Any]:
|
|
30
|
+
"""Return built-in default configuration values.
|
|
31
|
+
|
|
32
|
+
These are the lowest priority defaults used when no other config is provided.
|
|
33
|
+
"""
|
|
34
|
+
return {
|
|
35
|
+
'file_strategy': 'overwrite',
|
|
36
|
+
'input_store': '/tmp/structkit/input.json',
|
|
37
|
+
'log': 'INFO',
|
|
38
|
+
'non_interactive': False,
|
|
39
|
+
'output': 'file',
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
|
|
43
|
+
def load_yaml_config(config_path: str) -> Optional[Dict[str, Any]]:
|
|
44
|
+
"""Load a YAML config file and return its contents.
|
|
45
|
+
|
|
46
|
+
Args:
|
|
47
|
+
config_path: Path to the YAML config file
|
|
48
|
+
|
|
49
|
+
Returns:
|
|
50
|
+
Dictionary with config values, or None if file doesn't exist or is empty
|
|
51
|
+
"""
|
|
52
|
+
if not config_path or not os.path.exists(config_path):
|
|
53
|
+
return None
|
|
54
|
+
|
|
55
|
+
try:
|
|
56
|
+
with open(config_path, 'r') as f:
|
|
57
|
+
config = yaml.safe_load(f)
|
|
58
|
+
if config is None:
|
|
59
|
+
return {}
|
|
60
|
+
if not isinstance(config, dict):
|
|
61
|
+
logger.warning(f"Config file {config_path} does not contain a mapping, ignoring")
|
|
62
|
+
return {}
|
|
63
|
+
return config
|
|
64
|
+
except yaml.YAMLError as exc:
|
|
65
|
+
logger.warning(f"Failed to parse YAML in {config_path}: {exc}")
|
|
66
|
+
return {}
|
|
67
|
+
except OSError as exc:
|
|
68
|
+
logger.warning(f"Failed to read {config_path}: {exc}")
|
|
69
|
+
return {}
|
|
70
|
+
|
|
71
|
+
|
|
72
|
+
def merge_config_layer(base: Dict[str, Any], override: Optional[Dict[str, Any]]) -> Dict[str, Any]:
|
|
73
|
+
"""Merge an override config layer into a base config.
|
|
74
|
+
|
|
75
|
+
Override values take precedence over base values. Only merges top-level keys.
|
|
76
|
+
|
|
77
|
+
Args:
|
|
78
|
+
base: Base configuration dictionary
|
|
79
|
+
override: Override configuration dictionary (can be None)
|
|
80
|
+
|
|
81
|
+
Returns:
|
|
82
|
+
Merged configuration dictionary
|
|
83
|
+
"""
|
|
84
|
+
if override is None:
|
|
85
|
+
return base.copy()
|
|
86
|
+
|
|
87
|
+
result = base.copy()
|
|
88
|
+
for key, value in override.items():
|
|
89
|
+
if value is not None:
|
|
90
|
+
result[key] = value
|
|
91
|
+
return result
|
|
92
|
+
|
|
93
|
+
|
|
94
|
+
def load_layered_config(project_config_path: Optional[str] = None) -> Dict[str, Any]:
|
|
95
|
+
"""Load configuration from all layers and merge them.
|
|
96
|
+
|
|
97
|
+
Merge order (lowest to highest priority):
|
|
98
|
+
1. Built-in defaults
|
|
99
|
+
2. User config (~/.config/struct/config.yaml)
|
|
100
|
+
3. Project config (if provided)
|
|
101
|
+
|
|
102
|
+
Args:
|
|
103
|
+
project_config_path: Path to project-specific config file
|
|
104
|
+
|
|
105
|
+
Returns:
|
|
106
|
+
Merged configuration dictionary
|
|
107
|
+
"""
|
|
108
|
+
# Start with built-in defaults
|
|
109
|
+
config = get_builtin_defaults()
|
|
110
|
+
|
|
111
|
+
# Layer in user config
|
|
112
|
+
user_config_path = get_user_config_path()
|
|
113
|
+
if user_config_path.exists():
|
|
114
|
+
logger.debug(f"Loading user config from {user_config_path}")
|
|
115
|
+
user_config = load_yaml_config(str(user_config_path))
|
|
116
|
+
config = merge_config_layer(config, user_config)
|
|
117
|
+
|
|
118
|
+
# Layer in project config
|
|
119
|
+
if project_config_path:
|
|
120
|
+
logger.debug(f"Loading project config from {project_config_path}")
|
|
121
|
+
project_config = load_yaml_config(project_config_path)
|
|
122
|
+
config = merge_config_layer(config, project_config)
|
|
123
|
+
|
|
124
|
+
return config
|
|
125
|
+
|
|
126
|
+
|
|
127
|
+
def merge_cli_args(config: Dict[str, Any], args) -> Dict[str, Any]:
|
|
128
|
+
"""Merge CLI arguments into configuration, giving CLI args highest priority.
|
|
129
|
+
|
|
130
|
+
Args:
|
|
131
|
+
config: Configuration dictionary from layered config files
|
|
132
|
+
args: argparse Namespace with CLI arguments
|
|
133
|
+
|
|
134
|
+
Returns:
|
|
135
|
+
Final merged configuration dictionary
|
|
136
|
+
"""
|
|
137
|
+
result = config.copy()
|
|
138
|
+
args_dict = vars(args)
|
|
139
|
+
|
|
140
|
+
# List of config keys that can be set via CLI args
|
|
141
|
+
# We only override config file values if the CLI arg was explicitly provided
|
|
142
|
+
# (i.e., it's not None and differs from the default)
|
|
143
|
+
cli_overridable_keys = [
|
|
144
|
+
'structures_path',
|
|
145
|
+
'input_store',
|
|
146
|
+
'file_strategy',
|
|
147
|
+
'backup',
|
|
148
|
+
'global_system_prompt',
|
|
149
|
+
'non_interactive',
|
|
150
|
+
'output',
|
|
151
|
+
'log',
|
|
152
|
+
'log_file',
|
|
153
|
+
'source',
|
|
154
|
+
]
|
|
155
|
+
|
|
156
|
+
for key in cli_overridable_keys:
|
|
157
|
+
if key in args_dict and args_dict[key] is not None:
|
|
158
|
+
result[key] = args_dict[key]
|
|
159
|
+
|
|
160
|
+
return result
|
|
161
|
+
|
|
162
|
+
|
|
163
|
+
def apply_config_to_args(config: Dict[str, Any], args):
|
|
164
|
+
"""Apply configuration values to argparse namespace.
|
|
165
|
+
|
|
166
|
+
This modifies the args namespace in place, setting values from the config
|
|
167
|
+
only if the arg was not explicitly set via CLI.
|
|
168
|
+
|
|
169
|
+
Args:
|
|
170
|
+
config: Configuration dictionary
|
|
171
|
+
args: argparse Namespace to update
|
|
172
|
+
"""
|
|
173
|
+
args_dict = vars(args)
|
|
174
|
+
|
|
175
|
+
for key, value in config.items():
|
|
176
|
+
# Only set the value if the arg doesn't already have a non-None value
|
|
177
|
+
# This ensures CLI args take precedence
|
|
178
|
+
if key in args_dict and args_dict[key] is None:
|
|
179
|
+
args_dict[key] = value
|
|
180
|
+
|
|
181
|
+
|
|
182
|
+
def get_effective_config(args) -> Dict[str, Any]:
|
|
183
|
+
"""Get the effective configuration by merging all layers including CLI args.
|
|
184
|
+
|
|
185
|
+
This is the final configuration that would be used after all merging is complete.
|
|
186
|
+
|
|
187
|
+
Args:
|
|
188
|
+
args: argparse Namespace with CLI arguments
|
|
189
|
+
|
|
190
|
+
Returns:
|
|
191
|
+
Effective configuration dictionary
|
|
192
|
+
"""
|
|
193
|
+
# Get the project config file path from args if present
|
|
194
|
+
project_config_path = getattr(args, 'config_file', None)
|
|
195
|
+
|
|
196
|
+
# Load layered config from files
|
|
197
|
+
config = load_layered_config(project_config_path)
|
|
198
|
+
|
|
199
|
+
# Merge in CLI args (highest priority)
|
|
200
|
+
config = merge_cli_args(config, args)
|
|
201
|
+
|
|
202
|
+
return config
|
structkit/contribs/README.md
CHANGED
|
@@ -194,8 +194,8 @@ The `contribs` folder contains various sub-structs that can be used to generate
|
|
|
194
194
|
|
|
195
195
|
#### `github/prompts/struct`
|
|
196
196
|
|
|
197
|
-
- **Description**: Provides a prompt for creating a new .
|
|
198
|
-
- **When to Use**: Use this sub-structkit when you need to create a new .
|
|
197
|
+
- **Description**: Provides a prompt for creating a new .structkit.yaml file and workflow to run struct.
|
|
198
|
+
- **When to Use**: Use this sub-structkit when you need to create a new .structkit.yaml file and workflow to run struct.
|
|
199
199
|
|
|
200
200
|
### Project
|
|
201
201
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
description: >
|
|
2
2
|
Creates a GitHub Copilot prompt that configures an AI assistant for generating
|
|
3
|
-
valid .
|
|
3
|
+
valid .structkit.yaml files for the StructKit tool, with schema references and usage examples.
|
|
4
4
|
|
|
5
5
|
files:
|
|
6
6
|
- .github/prompts/struct.prompt.md:
|
|
@@ -9,9 +9,9 @@ files:
|
|
|
9
9
|
|
|
10
10
|
## Role
|
|
11
11
|
|
|
12
|
-
You are an expert assistant that generates valid `.
|
|
12
|
+
You are an expert assistant that generates valid `.structkit.yaml` files for the [StructKit tool](https://github.com/httpdss/struct), which automates project structure generation from YAML configuration.
|
|
13
13
|
|
|
14
|
-
## Defining the `.
|
|
14
|
+
## Defining the `.structkit.yaml` file
|
|
15
15
|
|
|
16
16
|
this file has 3 main keys: `structures`, `folders`, and `variables`.
|
|
17
17
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
description: >
|
|
2
2
|
Creates a GitHub Actions workflow (run-struct.yaml) that can be manually triggered
|
|
3
|
-
via workflow_dispatch to run struct file generation, plus a starter .
|
|
3
|
+
via workflow_dispatch to run struct file generation, plus a starter .structkit.yaml file.
|
|
4
4
|
|
|
5
5
|
files:
|
|
6
6
|
- .github/workflows/run-struct.yaml:
|
|
@@ -15,11 +15,11 @@ files:
|
|
|
15
15
|
generate:
|
|
16
16
|
uses: httpdss/structkit/.github/workflows/struct-generate.yaml@main
|
|
17
17
|
with:
|
|
18
|
-
struct_file: 'file://.
|
|
18
|
+
struct_file: 'file://.structkit.yaml'
|
|
19
19
|
output_dir: '.'
|
|
20
20
|
secrets:
|
|
21
21
|
token: {{@ github_token @}}
|
|
22
|
-
- .
|
|
22
|
+
- .structkit.yaml:
|
|
23
23
|
skip_if_exists: true
|
|
24
24
|
content: |
|
|
25
25
|
files:
|
structkit/file_item.py
CHANGED
structkit/filters.py
CHANGED
|
@@ -12,31 +12,95 @@ from cachetools import TTLCache, cached
|
|
|
12
12
|
cache = TTLCache(maxsize=100, ttl=600)
|
|
13
13
|
|
|
14
14
|
|
|
15
|
+
def _is_git_object_id(value):
|
|
16
|
+
return (
|
|
17
|
+
isinstance(value, str)
|
|
18
|
+
and re.fullmatch(r"(?:[0-9a-fA-F]{40}|[0-9a-fA-F]{64})", value) is not None
|
|
19
|
+
)
|
|
20
|
+
|
|
21
|
+
|
|
22
|
+
def _resolve_commit_sha(repo, git_object, peel_tags=True, max_depth=10):
|
|
23
|
+
"""Resolve a GitHub Git object to its commit object ID."""
|
|
24
|
+
seen = set()
|
|
25
|
+
|
|
26
|
+
for _ in range(max_depth):
|
|
27
|
+
object_type = getattr(git_object, "type", None)
|
|
28
|
+
sha = getattr(git_object, "sha", None)
|
|
29
|
+
if not isinstance(object_type, str) or not _is_git_object_id(sha):
|
|
30
|
+
raise ValueError("Malformed Git object")
|
|
31
|
+
|
|
32
|
+
if object_type == "commit":
|
|
33
|
+
return sha
|
|
34
|
+
if object_type != "tag" or not peel_tags or sha in seen:
|
|
35
|
+
raise ValueError("Git object does not resolve to a commit")
|
|
36
|
+
|
|
37
|
+
seen.add(sha)
|
|
38
|
+
git_tag = repo.get_git_tag(sha)
|
|
39
|
+
git_object = getattr(git_tag, "object", None)
|
|
40
|
+
|
|
41
|
+
raise ValueError("Annotated tag nesting limit exceeded")
|
|
42
|
+
|
|
43
|
+
|
|
44
|
+
def _resolve_tag_sha(repo, tag_name):
|
|
45
|
+
if not isinstance(tag_name, str) or not tag_name:
|
|
46
|
+
raise ValueError("Malformed release tag name")
|
|
47
|
+
git_ref = repo.get_git_ref(f"tags/{tag_name}")
|
|
48
|
+
return _resolve_commit_sha(repo, getattr(git_ref, "object", None))
|
|
49
|
+
|
|
50
|
+
|
|
51
|
+
def _resolve_branch_sha(repo, branch_name):
|
|
52
|
+
if not isinstance(branch_name, str) or not branch_name:
|
|
53
|
+
raise ValueError("Malformed default branch name")
|
|
54
|
+
git_ref = repo.get_git_ref(f"heads/{branch_name}")
|
|
55
|
+
return _resolve_commit_sha(repo, getattr(git_ref, "object", None), peel_tags=False)
|
|
56
|
+
|
|
57
|
+
|
|
15
58
|
@cached(cache)
|
|
16
|
-
def get_latest_release(repo_name):
|
|
17
|
-
token = os.getenv(
|
|
59
|
+
def get_latest_release(repo_name, strip_v=False, return_sha=False):
|
|
60
|
+
token = os.getenv("GITHUB_TOKEN")
|
|
18
61
|
|
|
19
62
|
# Use the token if available, otherwise proceed without authentication
|
|
20
63
|
if token:
|
|
21
|
-
|
|
64
|
+
g = Github(token)
|
|
22
65
|
else:
|
|
23
|
-
|
|
66
|
+
g = Github()
|
|
24
67
|
|
|
68
|
+
repo = None
|
|
25
69
|
try:
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
return latest_release.tag_name
|
|
70
|
+
# Get the repository object
|
|
71
|
+
repo = g.get_repo(repo_name)
|
|
72
|
+
# Get the latest release
|
|
73
|
+
latest_release = repo.get_latest_release()
|
|
31
74
|
except Exception:
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
75
|
+
# If an error occurs, return the default branch name
|
|
76
|
+
try:
|
|
77
|
+
if repo is None:
|
|
78
|
+
raise ValueError("Repository lookup failed")
|
|
79
|
+
default_branch = repo.default_branch
|
|
80
|
+
if return_sha:
|
|
81
|
+
return _resolve_branch_sha(repo, default_branch)
|
|
82
|
+
return default_branch
|
|
83
|
+
except Exception as e:
|
|
84
|
+
print(f"Error getting default branch: {e}")
|
|
85
|
+
return "LATEST_RELEASE_ERROR"
|
|
86
|
+
|
|
87
|
+
try:
|
|
88
|
+
tag_name = getattr(latest_release, "tag_name", None)
|
|
89
|
+
except Exception:
|
|
90
|
+
return "LATEST_RELEASE_ERROR"
|
|
91
|
+
if not isinstance(tag_name, str) or not tag_name:
|
|
38
92
|
return "LATEST_RELEASE_ERROR"
|
|
39
93
|
|
|
94
|
+
if return_sha:
|
|
95
|
+
try:
|
|
96
|
+
return _resolve_tag_sha(repo, tag_name)
|
|
97
|
+
except Exception:
|
|
98
|
+
return "LATEST_RELEASE_ERROR"
|
|
99
|
+
|
|
100
|
+
if strip_v and tag_name.startswith("v"):
|
|
101
|
+
return tag_name[1:]
|
|
102
|
+
return tag_name
|
|
103
|
+
|
|
40
104
|
|
|
41
105
|
@cached(cache)
|
|
42
106
|
def get_default_branch(repo_name):
|
structkit/main.py
CHANGED
|
@@ -1,8 +1,10 @@
|
|
|
1
1
|
import argparse
|
|
2
2
|
import logging
|
|
3
3
|
import os
|
|
4
|
+
import shlex
|
|
4
5
|
from dotenv import load_dotenv
|
|
5
6
|
from structkit.utils import read_config_file, merge_configs
|
|
7
|
+
from structkit.config import load_layered_config, apply_config_to_args
|
|
6
8
|
from structkit.commands.generate import GenerateCommand
|
|
7
9
|
from structkit.commands.info import InfoCommand
|
|
8
10
|
from structkit.commands.vars import VarsCommand
|
|
@@ -15,6 +17,7 @@ from structkit.commands.graph import GraphCommand
|
|
|
15
17
|
from structkit.commands.generate_schema import GenerateSchemaCommand
|
|
16
18
|
from structkit.commands.mcp import MCPCommand
|
|
17
19
|
from structkit.commands.sources import SourcesCommand
|
|
20
|
+
from structkit.commands.config import ConfigCommand
|
|
18
21
|
from structkit.logging_config import configure_logging
|
|
19
22
|
|
|
20
23
|
# Optional dependency: shtab for static shell completion generation
|
|
@@ -24,6 +27,94 @@ except Exception: # pragma: no cover - optional at runtime
|
|
|
24
27
|
shtab = None
|
|
25
28
|
|
|
26
29
|
load_dotenv()
|
|
30
|
+
SUPPORTED_COMPLETION_SHELLS = ("bash", "zsh", "tcsh", "fish")
|
|
31
|
+
|
|
32
|
+
|
|
33
|
+
def _fish_quote(value):
|
|
34
|
+
return shlex.quote(str(value))
|
|
35
|
+
|
|
36
|
+
|
|
37
|
+
def _fish_condition(command_path):
|
|
38
|
+
if not command_path:
|
|
39
|
+
return "__fish_structkit_using_command"
|
|
40
|
+
return "__fish_structkit_using_command " + " ".join(_fish_quote(command) for command in command_path)
|
|
41
|
+
|
|
42
|
+
|
|
43
|
+
def _fish_completion_script(parser):
|
|
44
|
+
"""Generate a static Fish completion script from an argparse parser."""
|
|
45
|
+
lines = [
|
|
46
|
+
"function __fish_structkit_using_command",
|
|
47
|
+
" set -l words (commandline -opc)",
|
|
48
|
+
" set -e words[1]",
|
|
49
|
+
" set -l commands",
|
|
50
|
+
" for word in $words",
|
|
51
|
+
" if not string match -qr '^-' -- $word",
|
|
52
|
+
" set -a commands $word",
|
|
53
|
+
" end",
|
|
54
|
+
" end",
|
|
55
|
+
" test (count $commands) -eq (count $argv)",
|
|
56
|
+
" or return 1",
|
|
57
|
+
" for index in (seq (count $argv))",
|
|
58
|
+
" test \"$commands[$index]\" = \"$argv[$index]\"",
|
|
59
|
+
" or return 1",
|
|
60
|
+
" end",
|
|
61
|
+
"end",
|
|
62
|
+
"",
|
|
63
|
+
f"complete -c {_fish_quote(parser.prog)} -f",
|
|
64
|
+
]
|
|
65
|
+
|
|
66
|
+
def add_completions(current_parser, command_path=()):
|
|
67
|
+
condition = _fish_condition(command_path)
|
|
68
|
+
for action in current_parser._actions:
|
|
69
|
+
if isinstance(action, argparse._SubParsersAction):
|
|
70
|
+
for name, subparser in action.choices.items():
|
|
71
|
+
if name not in action._name_parser_map:
|
|
72
|
+
continue
|
|
73
|
+
help_text = action._name_parser_map[name].description or ""
|
|
74
|
+
command = (
|
|
75
|
+
f"complete -c {_fish_quote(parser.prog)} -n {_fish_quote(condition)} "
|
|
76
|
+
f"-a {_fish_quote(name)}"
|
|
77
|
+
)
|
|
78
|
+
if help_text:
|
|
79
|
+
command += f" -d {_fish_quote(help_text)}"
|
|
80
|
+
lines.append(command)
|
|
81
|
+
add_completions(subparser, command_path + (name,))
|
|
82
|
+
continue
|
|
83
|
+
|
|
84
|
+
if action.help is argparse.SUPPRESS:
|
|
85
|
+
continue
|
|
86
|
+
|
|
87
|
+
choices = getattr(action, "choices", None)
|
|
88
|
+
arguments = ""
|
|
89
|
+
if choices:
|
|
90
|
+
arguments = " -a " + _fish_quote(" ".join(map(str, choices)))
|
|
91
|
+
|
|
92
|
+
for option in action.option_strings:
|
|
93
|
+
option_type = "-l" if option.startswith("--") else "-s"
|
|
94
|
+
command = (
|
|
95
|
+
f"complete -c {_fish_quote(parser.prog)} -n {_fish_quote(condition)} "
|
|
96
|
+
f"{option_type} {_fish_quote(option.lstrip('-'))}"
|
|
97
|
+
)
|
|
98
|
+
if action.nargs != 0:
|
|
99
|
+
command += " -r"
|
|
100
|
+
command += arguments
|
|
101
|
+
if action.help:
|
|
102
|
+
command += f" -d {_fish_quote(action.help)}"
|
|
103
|
+
lines.append(command)
|
|
104
|
+
|
|
105
|
+
add_completions(parser)
|
|
106
|
+
return "\n".join(lines)
|
|
107
|
+
|
|
108
|
+
|
|
109
|
+
class PrintCompletionAction(argparse.Action):
|
|
110
|
+
"""Print a completion script for shtab-supported shells or Fish."""
|
|
111
|
+
|
|
112
|
+
def __call__(self, parser, namespace, values, option_string=None):
|
|
113
|
+
if values == "fish":
|
|
114
|
+
print(_fish_completion_script(parser))
|
|
115
|
+
else:
|
|
116
|
+
print(shtab.complete(parser, values))
|
|
117
|
+
parser.exit(0)
|
|
27
118
|
|
|
28
119
|
|
|
29
120
|
def get_parser():
|
|
@@ -48,19 +139,24 @@ def get_parser():
|
|
|
48
139
|
GenerateSchemaCommand(subparsers.add_parser('generate-schema', help='Generate JSON schema for available structures'))
|
|
49
140
|
MCPCommand(subparsers.add_parser('mcp', help='MCP (Model Context Protocol) support'))
|
|
50
141
|
SourcesCommand(subparsers.add_parser('sources', help='Manage named custom structure sources'))
|
|
142
|
+
ConfigCommand(subparsers.add_parser('config', help='Display and manage structkit configuration'))
|
|
51
143
|
|
|
52
|
-
# init to create a basic .
|
|
144
|
+
# init to create a basic .structkit.yaml
|
|
53
145
|
from structkit.commands.init import InitCommand
|
|
54
|
-
InitCommand(subparsers.add_parser('init', help='Initialize a basic .
|
|
146
|
+
InitCommand(subparsers.add_parser('init', help='Initialize a basic .structkit.yaml in the target directory'))
|
|
55
147
|
|
|
56
148
|
# completion manager
|
|
57
149
|
from structkit.commands.completion import CompletionCommand
|
|
58
150
|
CompletionCommand(subparsers.add_parser('completion', help='Manage shell completions'))
|
|
59
151
|
|
|
60
|
-
#
|
|
152
|
+
# shtab supports bash, zsh, and tcsh. Fish is generated locally.
|
|
61
153
|
if shtab is not None:
|
|
62
|
-
|
|
63
|
-
|
|
154
|
+
parser.add_argument(
|
|
155
|
+
"--print-completion",
|
|
156
|
+
choices=SUPPORTED_COMPLETION_SHELLS,
|
|
157
|
+
action=PrintCompletionAction,
|
|
158
|
+
help="print shell completion script",
|
|
159
|
+
)
|
|
64
160
|
|
|
65
161
|
return parser
|
|
66
162
|
|
|
@@ -75,9 +171,18 @@ def main():
|
|
|
75
171
|
parser.print_help()
|
|
76
172
|
parser.exit()
|
|
77
173
|
|
|
78
|
-
#
|
|
79
|
-
|
|
80
|
-
|
|
174
|
+
# Load layered configuration (built-in defaults, user config, project config)
|
|
175
|
+
# This loads from ~/.config/struct/config.yaml and any --config-file
|
|
176
|
+
project_config_path = getattr(args, 'config_file', None)
|
|
177
|
+
layered_config = load_layered_config(project_config_path)
|
|
178
|
+
|
|
179
|
+
# Apply config to args (only for values not set via CLI)
|
|
180
|
+
apply_config_to_args(layered_config, args)
|
|
181
|
+
|
|
182
|
+
# For backward compatibility, also support the old merge_configs approach
|
|
183
|
+
# if config_file was explicitly provided
|
|
184
|
+
if project_config_path:
|
|
185
|
+
file_config = read_config_file(project_config_path)
|
|
81
186
|
args = argparse.Namespace(**merge_configs(file_config, args))
|
|
82
187
|
|
|
83
188
|
# Resolve logging level precedence: STRUCTKIT_LOG_LEVEL env > --debug (if present) > --log
|
structkit/mcp_server.py
CHANGED
|
@@ -136,6 +136,7 @@ class StructMCPServer:
|
|
|
136
136
|
mappings: Optional[Dict[str, str]] = None,
|
|
137
137
|
structures_path: Optional[str] = None,
|
|
138
138
|
source: Optional[str] = None,
|
|
139
|
+
no_hooks: bool = True,
|
|
139
140
|
) -> str:
|
|
140
141
|
try:
|
|
141
142
|
structures_path, structure_definition = resolve_structures_path(structures_path, source, structure_definition)
|
|
@@ -161,6 +162,8 @@ class StructMCPServer:
|
|
|
161
162
|
args.log = "INFO"
|
|
162
163
|
args.config_file = None
|
|
163
164
|
args.log_file = None
|
|
165
|
+
args.no_hooks = no_hooks
|
|
166
|
+
args.hooks_allowlist = None
|
|
164
167
|
|
|
165
168
|
# If mappings provided, convert to vars string consumed by GenerateCommand
|
|
166
169
|
if mappings:
|
|
@@ -452,7 +455,7 @@ class StructMCPServer:
|
|
|
452
455
|
self.logger.debug(f"MCP response: explain_structure len={len(result)} preview=\n{preview}")
|
|
453
456
|
return result
|
|
454
457
|
|
|
455
|
-
@self.app.tool(name="generate_structure", description="Generate a project structure using specified definition and options")
|
|
458
|
+
@self.app.tool(name="generate_structure", description="Generate a project structure using specified definition and options. MCP calls skip hooks by default for safety; set no_hooks=false to enable them.")
|
|
456
459
|
async def generate_structure(
|
|
457
460
|
structure_definition: str,
|
|
458
461
|
base_path: str,
|
|
@@ -461,6 +464,7 @@ class StructMCPServer:
|
|
|
461
464
|
mappings: Optional[Dict[str, str]] = None,
|
|
462
465
|
structures_path: Optional[str] = None,
|
|
463
466
|
source: Optional[str] = None,
|
|
467
|
+
no_hooks: bool = True,
|
|
464
468
|
) -> str:
|
|
465
469
|
self.logger.debug(
|
|
466
470
|
"MCP request: generate_structure args=%s",
|
|
@@ -472,6 +476,7 @@ class StructMCPServer:
|
|
|
472
476
|
"mappings": mappings,
|
|
473
477
|
"structures_path": structures_path,
|
|
474
478
|
"source": source,
|
|
479
|
+
"no_hooks": no_hooks,
|
|
475
480
|
},
|
|
476
481
|
)
|
|
477
482
|
result = self._generate_structure_logic(
|
|
@@ -482,6 +487,7 @@ class StructMCPServer:
|
|
|
482
487
|
mappings,
|
|
483
488
|
structures_path,
|
|
484
489
|
source,
|
|
490
|
+
no_hooks,
|
|
485
491
|
)
|
|
486
492
|
preview = result if len(result) <= 1000 else result[:1000] + f"... [truncated {len(result)-1000} chars]"
|
|
487
493
|
self.logger.debug(f"MCP response: generate_structure len={len(result)} preview=\n{preview}")
|
|
@@ -0,0 +1,113 @@
|
|
|
1
|
+
"""Canonical and legacy project structure filenames.
|
|
2
|
+
|
|
3
|
+
The product was originally named STRUCT, so repositories commonly commit
|
|
4
|
+
``.struct.yaml``. The canonical name is now ``.structkit.yaml``. Commands that
|
|
5
|
+
default to the project structure file prefer the canonical name and fall back
|
|
6
|
+
to the legacy name when it is the only one present.
|
|
7
|
+
"""
|
|
8
|
+
|
|
9
|
+
import logging
|
|
10
|
+
import os
|
|
11
|
+
from typing import Optional, Tuple
|
|
12
|
+
|
|
13
|
+
logger = logging.getLogger(__name__)
|
|
14
|
+
|
|
15
|
+
CANONICAL_PROJECT_STRUCT_FILE = ".structkit.yaml"
|
|
16
|
+
LEGACY_PROJECT_STRUCT_FILE = ".struct.yaml"
|
|
17
|
+
PROJECT_STRUCT_FILES = (
|
|
18
|
+
CANONICAL_PROJECT_STRUCT_FILE,
|
|
19
|
+
LEGACY_PROJECT_STRUCT_FILE,
|
|
20
|
+
)
|
|
21
|
+
|
|
22
|
+
|
|
23
|
+
def strip_file_scheme(path: str) -> Tuple[str, bool]:
|
|
24
|
+
"""Return (local_path, had_file_scheme) for a structure path."""
|
|
25
|
+
if path.startswith("file://"):
|
|
26
|
+
return path[7:], True
|
|
27
|
+
return path, False
|
|
28
|
+
|
|
29
|
+
|
|
30
|
+
def is_default_project_struct_path(path: Optional[str]) -> bool:
|
|
31
|
+
"""Return True when path is omitted or names a default project file."""
|
|
32
|
+
if not path:
|
|
33
|
+
return True
|
|
34
|
+
local_path, _ = strip_file_scheme(path)
|
|
35
|
+
return os.path.basename(local_path) in PROJECT_STRUCT_FILES
|
|
36
|
+
|
|
37
|
+
|
|
38
|
+
def find_existing_project_struct_file(directory: str = ".") -> Optional[str]:
|
|
39
|
+
"""Return the existing default project file in directory, if any.
|
|
40
|
+
|
|
41
|
+
Prefers ``.structkit.yaml`` over the legacy ``.struct.yaml``.
|
|
42
|
+
"""
|
|
43
|
+
canonical = os.path.join(directory, CANONICAL_PROJECT_STRUCT_FILE)
|
|
44
|
+
if os.path.isfile(canonical):
|
|
45
|
+
return canonical
|
|
46
|
+
|
|
47
|
+
legacy = os.path.join(directory, LEGACY_PROJECT_STRUCT_FILE)
|
|
48
|
+
if os.path.isfile(legacy):
|
|
49
|
+
return legacy
|
|
50
|
+
|
|
51
|
+
return None
|
|
52
|
+
|
|
53
|
+
|
|
54
|
+
def resolve_project_struct_file(
|
|
55
|
+
explicit_path: Optional[str] = None,
|
|
56
|
+
directory: str = ".",
|
|
57
|
+
) -> str:
|
|
58
|
+
"""Resolve which project structure file a command should use.
|
|
59
|
+
|
|
60
|
+
Non-default paths (named structures, custom YAML files) are returned
|
|
61
|
+
unchanged. Default names prefer ``.structkit.yaml`` and fall back to
|
|
62
|
+
``.struct.yaml`` when the canonical file is missing.
|
|
63
|
+
|
|
64
|
+
If neither default file exists, the canonical name is returned so error
|
|
65
|
+
messages mention ``.structkit.yaml``.
|
|
66
|
+
"""
|
|
67
|
+
if explicit_path and not is_default_project_struct_path(explicit_path):
|
|
68
|
+
return explicit_path
|
|
69
|
+
|
|
70
|
+
file_scheme = False
|
|
71
|
+
search_dir = directory
|
|
72
|
+
if explicit_path:
|
|
73
|
+
local_path, file_scheme = strip_file_scheme(explicit_path)
|
|
74
|
+
parent = os.path.dirname(local_path)
|
|
75
|
+
if parent:
|
|
76
|
+
search_dir = parent
|
|
77
|
+
existing_path = local_path
|
|
78
|
+
else:
|
|
79
|
+
existing_path = os.path.join(directory, os.path.basename(local_path))
|
|
80
|
+
if os.path.isfile(existing_path):
|
|
81
|
+
return explicit_path
|
|
82
|
+
|
|
83
|
+
canonical = os.path.normpath(os.path.join(search_dir, CANONICAL_PROJECT_STRUCT_FILE))
|
|
84
|
+
legacy = os.path.normpath(os.path.join(search_dir, LEGACY_PROJECT_STRUCT_FILE))
|
|
85
|
+
|
|
86
|
+
if os.path.isfile(canonical):
|
|
87
|
+
if os.path.isfile(legacy):
|
|
88
|
+
logger.info(
|
|
89
|
+
"Both %s and %s exist; using %s. Rename or remove %s to avoid ambiguity.",
|
|
90
|
+
CANONICAL_PROJECT_STRUCT_FILE,
|
|
91
|
+
LEGACY_PROJECT_STRUCT_FILE,
|
|
92
|
+
CANONICAL_PROJECT_STRUCT_FILE,
|
|
93
|
+
LEGACY_PROJECT_STRUCT_FILE,
|
|
94
|
+
)
|
|
95
|
+
chosen = canonical
|
|
96
|
+
elif os.path.isfile(legacy):
|
|
97
|
+
logger.info(
|
|
98
|
+
"Using legacy %s; prefer renaming it to %s.",
|
|
99
|
+
LEGACY_PROJECT_STRUCT_FILE,
|
|
100
|
+
CANONICAL_PROJECT_STRUCT_FILE,
|
|
101
|
+
)
|
|
102
|
+
chosen = legacy
|
|
103
|
+
else:
|
|
104
|
+
chosen = canonical
|
|
105
|
+
|
|
106
|
+
if file_scheme:
|
|
107
|
+
return f"file://{chosen}"
|
|
108
|
+
if explicit_path and os.path.dirname(explicit_path) in ("", "."):
|
|
109
|
+
# Keep a bare filename when the caller passed one (argparse default).
|
|
110
|
+
return os.path.basename(chosen)
|
|
111
|
+
if explicit_path is None and search_dir in ("", "."):
|
|
112
|
+
return os.path.basename(chosen)
|
|
113
|
+
return chosen
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: structkit
|
|
3
|
-
Version: 3.
|
|
3
|
+
Version: 3.3.0
|
|
4
4
|
Summary: YAML-first project scaffolding tool with remote content fetching, AI/MCP integration, and DevOps automation
|
|
5
5
|
Author: httpdss
|
|
6
6
|
License: MIT
|
|
@@ -55,20 +55,20 @@ Requires-Dist: flake8>=4.0.0; extra == "dev"
|
|
|
55
55
|
Requires-Dist: mypy>=0.990; extra == "dev"
|
|
56
56
|
Dynamic: license-file
|
|
57
57
|
|
|
58
|
-
#
|
|
58
|
+
# StructKit
|
|
59
59
|
|
|
60
|
-
|
|
60
|
+
YAML scaffolding your AI assistant can actually run.
|
|
61
|
+
|
|
62
|
+
Define a repo once (files, CI, Terraform, app layout). Generate it from the CLI, from CI, or through an assistant over MCP. When the org template on GitHub changes, the next generate picks it up. No golden repo. No separate Cookiecutter tree.
|
|
61
63
|
|
|
62
64
|
[](https://codecov.io/github/httpdss/structkit)
|
|
63
65
|

|
|
64
66
|

|
|
65
67
|

|
|
66
68
|
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
> 🚀 **[Quick Start](docs/quickstart.md)** | 📚 **[Docs](docs/index.md)** | 🧩 **[Examples](examples/)** | 🤖 **[MCP / AI Agent Guide](docs/mcp-integration.md)** | 🧠 **[Agent Skills](docs/agent-skills.md)** | 💬 **[Discussions](https://github.com/httpdss/structkit/discussions)**
|
|
69
|
+
> 🚀 **[Quick Start](docs/quickstart.md)** | 📚 **[Docs](docs/index.md)** | 🤖 **[MCP / AI Agent Guide](docs/mcp-integration.md)** | 💬 **[Discussions](https://github.com/httpdss/structkit/discussions)**
|
|
70
70
|
|
|
71
|
-
##
|
|
71
|
+
## Try it in 60 seconds
|
|
72
72
|
|
|
73
73
|
```bash
|
|
74
74
|
# Install the CLI
|
|
@@ -79,6 +79,9 @@ structkit list
|
|
|
79
79
|
|
|
80
80
|
# Generate a ready-made Terraform module scaffold
|
|
81
81
|
structkit generate --vars module_name=my-terraform-module terraform/modules/generic ./my-terraform-module
|
|
82
|
+
|
|
83
|
+
# Start MCP server for AI integration
|
|
84
|
+
structkit mcp --server
|
|
82
85
|
```
|
|
83
86
|
|
|
84
87
|
Prefer Docker?
|
|
@@ -88,6 +91,18 @@ docker run --rm -v "$(pwd):/workdir" ghcr.io/httpdss/structkit:main \
|
|
|
88
91
|
generate --vars module_name=my-terraform-module terraform/modules/generic ./my-terraform-module
|
|
89
92
|
```
|
|
90
93
|
|
|
94
|
+
## Ecosystem
|
|
95
|
+
|
|
96
|
+
These are install paths for [StructKit](https://github.com/httpdss/structkit), not separate products. Star this repo.
|
|
97
|
+
|
|
98
|
+
- [GitHub Action](https://github.com/httpdss/structkit-action) — validate, generate, or drift-check in CI
|
|
99
|
+
- [VS Code / Cursor](https://github.com/httpdss/vscode-structkit) — schema and autocomplete for `.structkit.yaml`
|
|
100
|
+
- [Agent skills](https://github.com/httpdss/structkit-skills) — inspect, preview, generate, validate from an assistant
|
|
101
|
+
- [pre-commit](https://github.com/httpdss/structkit-pre-commit) — validate structures before they land
|
|
102
|
+
- [Homebrew](https://github.com/httpdss/homebrew-structkit) — `brew tap httpdss/structkit && brew install structkit`
|
|
103
|
+
- [Backstage](https://github.com/httpdss/backstage-plugin-structkit) — scaffolder actions for platform teams
|
|
104
|
+
- [Hermes plugin](https://github.com/httpdss/hermes-plugin-structkit) — safe StructKit tools inside Hermes
|
|
105
|
+
|
|
91
106
|
## 👤 Who StructKit is for
|
|
92
107
|
|
|
93
108
|
- **Platform / DevEx teams** standardizing service layouts, CI baselines, and engineering conventions across many repos.
|
|
@@ -1,26 +1,29 @@
|
|
|
1
1
|
structkit/__init__.py,sha256=NUdm0byilRA0-t0KCBmbJJvVbeNyC0q-XuQyQX4wFnE,160
|
|
2
2
|
structkit/completers.py,sha256=3kOzXygY3lno8RdJgM2ri3AH_koxzJOGmXYJsoUuMuk,2018
|
|
3
|
+
structkit/config.py,sha256=FlChEA5EEBFWaUTtiPBNWMwINtTC-1FFVwJnAR8n8B4,6039
|
|
3
4
|
structkit/content_fetcher.py,sha256=5dgjv2J_9SIBgVvetYb12Vs_BN2MoD_gPdEXUcPTvsI,9609
|
|
4
|
-
structkit/file_item.py,sha256=
|
|
5
|
-
structkit/filters.py,sha256=
|
|
5
|
+
structkit/file_item.py,sha256=j0fogUoGk5PkUPrOadaXMKsyth-PZihx0awNgK0olkw,7336
|
|
6
|
+
structkit/filters.py,sha256=AXbYxEM_pKHhJUeAuQyN1CGfNvfZHThc0j_XQCmLbvI,4796
|
|
6
7
|
structkit/input_store.py,sha256=gd8_m15MMtyG_neKSRt4BFlpcU_jX7xZnFF5XAj1GR0,1702
|
|
7
8
|
structkit/logging_config.py,sha256=lYRWf8PGZ1CKMeu0PCFPklXx2FHtgyKl1t6ZnIe46nQ,1071
|
|
8
|
-
structkit/main.py,sha256=
|
|
9
|
-
structkit/mcp_server.py,sha256=
|
|
9
|
+
structkit/main.py,sha256=YpL7Ow6zjocrjtKfTHVzZ6YQ9_SQ5ENGoXCA3Gkf4Tg,8165
|
|
10
|
+
structkit/mcp_server.py,sha256=7K-LdJjEBkgV3rpm6PjFU7qe527P80eVSseTUA7_NDc,30578
|
|
10
11
|
structkit/model_wrapper.py,sha256=3OhaB5bVyHoec7AJS_kLbcV1z2_aGJ7FHY1mdX9SZd8,2054
|
|
12
|
+
structkit/project_file.py,sha256=lZ4lZS9dnBemL7LewkPb6U2giW0TYfsXAhx8DHoFT9c,3890
|
|
11
13
|
structkit/sources.py,sha256=UvZ2pPyUHIpFOrYJbZHzOi2g0oymWNzvkLPVGuxqsBc,13831
|
|
12
14
|
structkit/struct_refs.py,sha256=VJixm6sx0ElGogbnwhcRcQhfvNjkdrUv2hMp8T5nAOc,5808
|
|
13
15
|
structkit/template_renderer.py,sha256=4haUlbAoz_f8GmC8tU8HBYdFiSBDBT7Q_yiadEDOOmU,10441
|
|
14
16
|
structkit/utils.py,sha256=3xCt3p91r7SRnmJB3ke1D6vszR30sdmH1K6LxxwWGG4,1238
|
|
15
17
|
structkit/commands/__init__.py,sha256=SZqu6rM7TBOtPnAV6GPbSnt7awJ63DS5pHDmn6eEeYg,746
|
|
16
|
-
structkit/commands/completion.py,sha256=
|
|
18
|
+
structkit/commands/completion.py,sha256=fKB9Nao2sSWCDaA1i_L7m7rSC1JX-iCRZI1KjoLZ0lo,2648
|
|
19
|
+
structkit/commands/config.py,sha256=QR1wZnER5dGCp0YKk-qczpJfc_jsFgJZ_ytjCO-Qp1Y,3379
|
|
17
20
|
structkit/commands/explain.py,sha256=P8zAZBw7oM3mwhTmH1ZGY3Nhq663fpGzaXXngPpvx0A,15562
|
|
18
|
-
structkit/commands/generate.py,sha256=
|
|
21
|
+
structkit/commands/generate.py,sha256=WYd7K6gBDovPn0izw7NfogJhyCsbCNWjGasD1Kiy15k,25993
|
|
19
22
|
structkit/commands/generate_schema.py,sha256=UIYvp46zb5l5ouQHA1Usxzt20r2QS5fgHOIQ26g8B_E,2657
|
|
20
23
|
structkit/commands/graph.py,sha256=aA26oh5v3z9tddOURMAgERbmAKY29MB911vWpFuZKZA,11320
|
|
21
24
|
structkit/commands/import.py,sha256=p4u5NJCwWwp7FKemAz7oQfT3Uu9uKxrCa3Q2wcG2Pqw,2483
|
|
22
25
|
structkit/commands/info.py,sha256=ZBnOGBp4Y9ppiHJbW0RC9Whpu2A-czdB9kdpHbFuIHY,3528
|
|
23
|
-
structkit/commands/init.py,sha256=
|
|
26
|
+
structkit/commands/init.py,sha256=N1nOAO7bTuaOQxfP3fWlAmE59kojxwgnNtFBkK2PrcM,2016
|
|
24
27
|
structkit/commands/lint.py,sha256=3o9ovN9Ebnh6r0YTG6G9MIlXCU2hhpxzaDJwZ0lM7e4,14030
|
|
25
28
|
structkit/commands/list.py,sha256=0KZ9VHPtkqSHLnEGN5-bH9YsIx0NxcbXFaw6MXQrRg4,3548
|
|
26
29
|
structkit/commands/mcp.py,sha256=UE-yGmblGs0hCBc10qqZhkYEntT1544szyw3PzGyzRU,6072
|
|
@@ -28,7 +31,7 @@ structkit/commands/search.py,sha256=GNlvis4uE2X1FAEnOUCeiu3iGTLF6Yolx13lxJ4Wd1M,
|
|
|
28
31
|
structkit/commands/sources.py,sha256=xsiwRya8HqsD4fWEN2cbqZLfx9ev3nMZ5DNOqvrJqqw,3422
|
|
29
32
|
structkit/commands/validate.py,sha256=QGBrvOFOIOWRx01DT69tpQI5lTtlxDsgbmRYCavGDWU,7852
|
|
30
33
|
structkit/commands/vars.py,sha256=6RasC2Hq1uZ-uyRQmqFow_ML3gqHIElV8jAO5VDkQWU,5249
|
|
31
|
-
structkit/contribs/README.md,sha256=
|
|
34
|
+
structkit/contribs/README.md,sha256=0aPaE1VTGZgmXoRJZpMP-qdEgkBMd2L5qwYC1dAWB-0,13277
|
|
32
35
|
structkit/contribs/ansible-playbook.yaml,sha256=3yFjCExmSBi5t-BPROVnrrKVJEDgmb946Si8Mq78LvI,1088
|
|
33
36
|
structkit/contribs/chef-cookbook.yaml,sha256=P2OQd63B6PHU6u3kuRi_sU7CVd4Jb_Le9rHzr-InPJw,1596
|
|
34
37
|
structkit/contribs/ci-cd-pipelines.yaml,sha256=BaE9CjkTEAgadBUsly5Q5cSiJ2ULwQjnV7pvhb_fnWg,1933
|
|
@@ -53,13 +56,13 @@ structkit/contribs/github/instructions/generic.yaml,sha256=enF0mSUsmv_uSVbiD5c2j
|
|
|
53
56
|
structkit/contribs/github/prompts/generic.yaml,sha256=L37Ez5fFdY2xUtnITJTnKJ8jZNMgvkds3kgIYd37s08,251
|
|
54
57
|
structkit/contribs/github/prompts/react-form.yaml,sha256=xTPpO1pZ4AkTTnxcsOf5rJ3AYoHlWrGChCod5v4zX3U,936
|
|
55
58
|
structkit/contribs/github/prompts/security-api.yaml,sha256=roJpIFJiwc0uPbDPKgR8clAJSCLAkqFb6oceWSdb2QI,517
|
|
56
|
-
structkit/contribs/github/prompts/struct.yaml,sha256=
|
|
59
|
+
structkit/contribs/github/prompts/struct.yaml,sha256=DBJLBI198OPVQphD4npfWu_Tf11vfBPZGo55ou0DtoY,4548
|
|
57
60
|
structkit/contribs/github/workflows/codeql.yaml,sha256=NzUH2cHjgOwQBc3IDaKVFYPsfhVo151g6AOfTTIi8Ls,4648
|
|
58
61
|
structkit/contribs/github/workflows/execute-tf-workflow.yaml,sha256=NRieIgePO9enk65kGOzLBZck7I-E974fhUbqY3Zuhxs,1464
|
|
59
62
|
structkit/contribs/github/workflows/labeler.yaml,sha256=lpszSNFmaoFiXat-eAXEf-QHtg4B-3kpMNvcBaleF_U,2950
|
|
60
63
|
structkit/contribs/github/workflows/pre-commit.yaml,sha256=feQtHcs8nwB57lJ5fcnDPtwLuQZo_YKNbOEpTZuco8g,1113
|
|
61
64
|
structkit/contribs/github/workflows/release-drafter.yaml,sha256=hg9DicbqW_JdI3Z0CeC1fmvUWk-C6XN0lA1012QnsxM,2530
|
|
62
|
-
structkit/contribs/github/workflows/run-struct.yaml,sha256=
|
|
65
|
+
structkit/contribs/github/workflows/run-struct.yaml,sha256=Kmiv3DaTRRzCyc8uj1W1_eX1kvS-FwM9KU-YxTgX8E0,921
|
|
63
66
|
structkit/contribs/github/workflows/stale.yaml,sha256=aIsOOai99I3oGXNkPKTIduT87e-NfCLwagh2GQctIGI,747
|
|
64
67
|
structkit/contribs/project/custom-structures.yaml,sha256=27EO-YFaVKi6I9p5eIqGy4V4n9YJFRwYQ4ETr8_0sNs,884
|
|
65
68
|
structkit/contribs/project/generic.yaml,sha256=aymgJ1GRfCICtAMJGxQNJQvzjatandou-A4IS7ywDJY,9656
|
|
@@ -77,9 +80,9 @@ structkit/contribs/terraform/apps/generic.yaml,sha256=RClgHvjyeiHGkW3MqbMzuxPk4o
|
|
|
77
80
|
structkit/contribs/terraform/apps/github-organization.yaml,sha256=-JJf691uoK286KllE6boWkDZhpK4Q_8ry26YXlqtav0,1155
|
|
78
81
|
structkit/contribs/terraform/apps/init.yaml,sha256=BhZc4LqHfe_T1tmBmC-w_xGn5Ad2hhl0TdNhBJNEapM,489
|
|
79
82
|
structkit/contribs/terraform/modules/generic.yaml,sha256=tflQFhe9RAUOwP4lGSd6_bKuFOkFswkNAyMVWTjuXBY,1787
|
|
80
|
-
structkit-3.
|
|
81
|
-
structkit-3.
|
|
82
|
-
structkit-3.
|
|
83
|
-
structkit-3.
|
|
84
|
-
structkit-3.
|
|
85
|
-
structkit-3.
|
|
83
|
+
structkit-3.3.0.dist-info/licenses/LICENSE,sha256=xx0jnfkXJvxRnG63LTGOxlggYnIysveWIZ6H3PNdCrQ,11357
|
|
84
|
+
structkit-3.3.0.dist-info/METADATA,sha256=1VCgo4isgtNNviQJrV1eEJGJn9OA61QeOlkcBL3T86M,11254
|
|
85
|
+
structkit-3.3.0.dist-info/WHEEL,sha256=YVMoNqKzERt-wjUZwJ33xBGAwnFl-4cqbYkTtWa4itE,91
|
|
86
|
+
structkit-3.3.0.dist-info/entry_points.txt,sha256=xJ-CjU6FUT2--cnTVqYIvHvvjihRQCZfel75L0iLvj8,50
|
|
87
|
+
structkit-3.3.0.dist-info/top_level.txt,sha256=hXn8F2XQ9ZStiqI_jAcqJYUI9S362zBTzElR4rhOBbI,10
|
|
88
|
+
structkit-3.3.0.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|
|
File without changes
|