-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathcre8magic-experimental.config.json
More file actions
143 lines (143 loc) · 3.78 KB
/
cre8magic-experimental.config.json
File metadata and controls
143 lines (143 loc) · 3.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
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
{
// Experimental idea... ask 2dm
"messages": {
"before": "This will convert the cre8magic Oqtane Basic Theme to template for custom themes.\n\n To learn more about the Basic Theme, visit http://go.cre8magic.org/theme-basic"
},
// Experimental idea... ask 2dm
"parameters": {
// The owner of the template, used in the namespace and folder structure.
"Owner": {
"type": "string",
"default": "[Owner]"
},
"ThemeName": {
"type": "string",
"default": "[Theme]"
},
"FrameworkVersion": {
"type": "string",
"default": "[FrameworkVersion]"
}
},
// The path where generated templates will be placed.
// Could be absolute "c:\\Projects\\oqtane.framework\\Oqtane.Server\\wwwroot\\Themes\\Templates\\YourTemplate"
// or relative to the current working directory.
// Take a care to stop Oqtane before generating with in Oqtane.Server folders.
"destinationPath": "..\\..\\2Templates\\cre8magic",
// Source file selection rules
// We have 3 set of rules for demonstration. In practice you can have just one.
"source": [
{
// 1st rule: Include all files
"include": [
"**/*.*"
],
// Exclude version control, IDE, and specific folders/files
"exclude": [
".git/",
".github/",
".vs/",
"Client/",
"Package/",
".gitignore",
"**/*.DotSettings",
"cre8magic-transformer.config.json"
]
},
{
// 2nd rule: Include all files in the Client folder
"include": [
"Client/**/*.*"
],
// Exclude build artifacts and settings
"exclude": [
"**/bin/",
"**/node_modules/",
"**/obj/",
"**/package-lock.json",
"**/*.DotSettings"
]
},
{
// 3rd rule: Include all files in the Package folder
"include": [
"Package/**/*.*"
],
// Exclude build artifacts and package files
"exclude": [
"**/bin/",
"**/obj/",
"**/*.nupkg"
]
}
],
// Folder and file renaming rules
"rename": [
{
// Apply to all files and folders
"include": [
"**/*.*"
],
// Replace namespace and theme placeholders
"replace": {
"ToSic.Cre8magic.Theme.Basic": "[Owner].Theme.[Theme]"
}
}
],
// Content processing and token replacement rules
"process": [
{
// File types with text content to process for replacements.
// Everything else (images, binaries) will be just copied as is.
"include": [
"**/*.sln",
"**/*.csproj",
"**/*.cs",
"**/*.cshtml",
"**/*.razor",
"**/*.resx",
"**/*.config",
"**/*.xml",
"**/*.json",
"**/*.js",
"**/*.map",
"**/*.ts",
"**/*.css",
"**/*.sass",
"**/*.scss",
"**/*.html",
"**/*.md",
"**/*.txt",
"**/*.nuspec",
"**/*.bat",
"**/*.cmd",
"**/*.ps1",
"**/*.sh"
],
// Exclude specific files from replacement.
// This is useful for files that should not be modified, like readme files.
"exclude": [
"**/styles/readme.md",
"template.json"
],
// Replace tokens with template variables.
"replace": {
"ToSic.Cre8magic.Theme.Basic": "[Owner].Theme.[Theme]",
"ToSic": "[Owner]",
"Basic": "[Theme]",
"6.1.3": "[FrameworkVersion]"
}
},
{
// File types with text content to process for replacements.
// Everything else (images, binaries) will be just copied as is.
"include": [
"template.json"
],
// Replace tokens with template variables.
"replace": {
"ToSic.Cre8magic.Theme.Basic": "[Owner].Theme.[Theme]"
}
}
]
}