-
Notifications
You must be signed in to change notification settings - Fork 207
Expand file tree
/
Copy pathCodexPlugin.php
More file actions
100 lines (83 loc) · 2.78 KB
/
Copy pathCodexPlugin.php
File metadata and controls
100 lines (83 loc) · 2.78 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
<?php
declare(strict_types=1);
namespace Appwrite\SDK\Language;
use Override;
class CodexPlugin extends Skills
{
#[Override]
public function getName(): string
{
return 'CodexPlugin';
}
#[Override]
public function getFiles(): array
{
$languages = [
'typescript',
'dart',
'kotlin',
'swift',
'php',
'python',
'ruby',
'go',
'rust',
'dotnet',
'cli',
];
$files = [];
foreach ($languages as $lang) {
$files[] = [
'scope' => 'default',
'destination' => 'plugins/{{ spec.title | caseLower }}/skills/{{ spec.title | caseLower }}-' . $lang . '/SKILL.md',
'template' => 'skills/' . $lang . '.md.twig',
];
}
$files[] = [
'scope' => 'default',
'destination' => 'plugins/{{ spec.title | caseLower }}/.codex-plugin/plugin.json',
'template' => 'codex-plugin/plugin.json.twig',
];
$files[] = [
'scope' => 'default',
'destination' => '.agents/plugins/marketplace.json',
'template' => 'codex-plugin/marketplace.json.twig',
];
$files[] = [
'scope' => 'default',
'destination' => 'plugins/{{ spec.title | caseLower }}/.mcp.json',
'template' => 'codex-plugin/.mcp.json.twig',
];
$files[] = [
'scope' => 'default',
'destination' => 'plugins/{{ spec.title | caseLower }}/skills/{{ spec.title | caseLower }}-deploy-site/SKILL.md',
'template' => 'plugin/commands/deploy-site.md.twig',
];
$files[] = [
'scope' => 'default',
'destination' => 'plugins/{{ spec.title | caseLower }}/skills/{{ spec.title | caseLower }}-deploy-function/SKILL.md',
'template' => 'plugin/commands/deploy-function.md.twig',
];
$files[] = [
'scope' => 'default',
'destination' => 'plugins/{{ spec.title | caseLower }}/config.toml',
'template' => 'codex-plugin/config.toml.twig',
];
$files[] = [
'scope' => 'default',
'destination' => 'README.md',
'template' => 'codex-plugin/README.md.twig',
];
$files[] = [
'scope' => 'default',
'destination' => 'CHANGELOG.md',
'template' => 'skills/CHANGELOG.md.twig',
];
$files[] = [
'scope' => 'default',
'destination' => 'LICENSE',
'template' => 'plugin/LICENSE.twig',
];
return $files;
}
}