create-domis 1.0.5 → 1.0.7
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/LICENSE +14 -15
- package/README.md +3 -2
- package/dist/index.d.ts +2 -1
- package/dist/index.js +29 -40
- package/package.json +2 -3
package/LICENSE
CHANGED
|
@@ -1,39 +1,38 @@
|
|
|
1
|
-
|
|
1
|
+
PRIVATE COMMERCIAL LICENSE
|
|
2
|
+
|
|
2
3
|
Version 1.0 - 2026 - DomisDev
|
|
3
4
|
|
|
4
5
|
Copyright (c) 2026 DomisDev (Domisnnet)
|
|
5
6
|
|
|
6
7
|
1. DEFINIÇÃO DO SOFTWARE
|
|
7
8
|
Este "Software" refere-se aos templates, firebase.json, firestore.rules,
|
|
8
|
-
workflows e documentações contidas no repositório DomisPacks-Technical,
|
|
9
|
-
adquiridos via PRO_KEY ou Pack Lite/Pro.
|
|
9
|
+
workflows e documentações contidas no repositório DomisPacks-Technical, adquiridos via PRO_KEY ou Pack Lite/Pro.
|
|
10
10
|
|
|
11
11
|
2. DIREITOS CONCEDIDOS AO COMPRADOR (LICENCIADO)
|
|
12
12
|
|
|
13
|
-
Ao adquirir uma PRO_KEY válida, é concedido ao Licenciado, de forma
|
|
14
|
-
|
|
13
|
+
Ao adquirir uma PRO_KEY válida, é concedido ao Licenciado, de forma não-exclusiva e intransferível:
|
|
14
|
+
|
|
15
|
+
a) USO PRIVADO E COMERCIAL: Usar, modificar e construir projetos próprios e para clientes finais.
|
|
15
16
|
|
|
16
|
-
a) USO PRIVADO E COMERCIAL: Usar, modificar e construir projetos próprios
|
|
17
|
-
e para clientes finais.
|
|
18
17
|
b) MODIFICAÇÃO: Alterar o código para adequar ao seu projeto.
|
|
18
|
+
|
|
19
19
|
c) PROJETOS ILIMITADOS: Usar o mesmo Pack em N projetos seus.
|
|
20
20
|
|
|
21
21
|
3. PROIBIÇÕES EXPRESSAS (O QUE VOCÊ NÃO PODE FAZER)
|
|
22
22
|
|
|
23
23
|
Sem autorização escrita do DomisDev, é EXPRESSAMENTE PROIBIDO:
|
|
24
24
|
|
|
25
|
-
a) REVENDER, REDISTRIBUIR OU COMPARTILHAR: Revender, doar, postar em
|
|
26
|
-
|
|
27
|
-
b) REEMBALAR COMO PRODUTO: Criar um "Novo Pack", CLI ou curso usando
|
|
28
|
-
|
|
25
|
+
a) REVENDER, REDISTRIBUIR OU COMPARTILHAR: Revender, doar, postar em GitHub público, Discord, Telegram, cursos ou qualquer outro meio físico e/ou DIGITAL integral ou em partes este código, bem como template.
|
|
26
|
+
|
|
27
|
+
b) REEMBALAR COMO PRODUTO: Criar um "Novo Pack", CLI ou curso usando este código como base para venda.
|
|
28
|
+
|
|
29
29
|
c) REMOVER COPYRIGHT: Remover avisos de autoria DomisDev.
|
|
30
|
-
|
|
31
|
-
|
|
30
|
+
|
|
31
|
+
d) COMPARTILHAR PRO_KEY: Uma key = 1 desenvolvedor. Compartilhamento não autorizado gera banimento imediato.
|
|
32
32
|
|
|
33
33
|
4. GARANTIA E SUPORTE
|
|
34
34
|
|
|
35
|
-
O Software é fornecido "COMO ESTÁ" (AS IS), sem garantias. O suporte
|
|
36
|
-
é garantido apenas para detentores de PRO_KEY ativa conforme o plano
|
|
35
|
+
O Software é fornecido "COMO ESTÁ" (AS IS), sem garantias. O suporte é garantido apenas para detentores de PRO_KEY ativa conforme o plano
|
|
37
36
|
(Lite = docs, Pro = 7 dias via GitHub Issues privado).
|
|
38
37
|
|
|
39
38
|
5. VIOLAÇÃO
|
package/README.md
CHANGED
|
@@ -165,8 +165,9 @@ Este CLI é código aberto, mas os Packs são sob:
|
|
|
165
165
|
<img src="src/assets/DomisDev.png" width="90" style="border-radius: 50%" alt="DomisDev">
|
|
166
166
|
</a>
|
|
167
167
|
|
|
168
|
+
|
|
168
169
|
<p align="center">
|
|
169
|
-
<a href="#sobre-o-
|
|
170
|
-
<img src="https://img.shields.io/badge
|
|
170
|
+
<a href="#sobre-o-projeto">
|
|
171
|
+
<img src="https://img.shields.io/badge/⬆️%20VOLTAR%20AO%20TOPO-26FF00?style=flat&labelColor=111827&color=0A0F1C" alt="Voltar ao topo" style="height: 30px;">
|
|
171
172
|
</a>
|
|
172
173
|
</p>
|
package/dist/index.d.ts
CHANGED
|
@@ -1 +1,2 @@
|
|
|
1
|
-
|
|
1
|
+
|
|
2
|
+
export { }
|
package/dist/index.js
CHANGED
|
@@ -1,5 +1,3 @@
|
|
|
1
|
-
#!/usr/bin/env node
|
|
2
|
-
|
|
3
1
|
// src/index.ts
|
|
4
2
|
import prompts from "prompts";
|
|
5
3
|
import pc from "picocolors";
|
|
@@ -8,6 +6,18 @@ import fs from "fs";
|
|
|
8
6
|
import path from "path";
|
|
9
7
|
console.log(pc.bgMagenta(pc.black(" DOMIS CLI ")), pc.magenta("v0.1.0 - Acelere seu Angular + Firebase\n"));
|
|
10
8
|
var args = process.argv.slice(2);
|
|
9
|
+
if (args.includes("--help") || args.includes("-h")) {
|
|
10
|
+
console.log(
|
|
11
|
+
`USO: npx create-domis@latest [nome] --template [template] --key [PRO_KEY]
|
|
12
|
+
TEMPLATES:
|
|
13
|
+
domisdocs-firebase-lite
|
|
14
|
+
domisdocs-firebase-pro
|
|
15
|
+
EXEMPLOS:
|
|
16
|
+
npx create-domis@latest meu-app
|
|
17
|
+
npx create-domis@latest meu-app --template domisdocs-firebase-lite`
|
|
18
|
+
);
|
|
19
|
+
process.exit(0);
|
|
20
|
+
}
|
|
11
21
|
var hasTemplateArg = args.find((a) => a.includes("template"))?.split("=")[1] || args[args.indexOf("--template") + 1];
|
|
12
22
|
var hasKeyArg = args.find((a) => a.includes("key"))?.split("=")[1] || args[args.indexOf("--key") + 1];
|
|
13
23
|
async function main() {
|
|
@@ -16,27 +26,12 @@ async function main() {
|
|
|
16
26
|
let projectName = "meu-app-domis";
|
|
17
27
|
if (!template) {
|
|
18
28
|
const res = await prompts([
|
|
19
|
-
{
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
{ title: "\u{1F680} Domflix PRO - Completo com TMDB + Auth (PAGO)", value: "domflix-firebase-pro" },
|
|
26
|
-
{ title: "\u{1F4DA} Angular + Firestore SaaS Starter (PAGO)", value: "angular-firestore-pro" }
|
|
27
|
-
]
|
|
28
|
-
},
|
|
29
|
-
{
|
|
30
|
-
type: (prev) => prev.includes("pro") ? "text" : null,
|
|
31
|
-
name: "key",
|
|
32
|
-
message: "Digite sua PRO_KEY (comprada na Kiwify):"
|
|
33
|
-
},
|
|
34
|
-
{
|
|
35
|
-
type: "text",
|
|
36
|
-
name: "projectName",
|
|
37
|
-
message: "Nome do projeto?",
|
|
38
|
-
initial: "meu-app-domis"
|
|
39
|
-
}
|
|
29
|
+
{ type: "select", name: "template", message: "Qual pack?", choices: [
|
|
30
|
+
{ title: "\u{1F525} Domflix LITE", value: "domflix-firebase-lite" },
|
|
31
|
+
{ title: "\u{1F680} Domflix PRO", value: "domflix-firebase-pro" }
|
|
32
|
+
] },
|
|
33
|
+
{ type: (prev) => prev.includes("pro") ? "text" : null, name: "key", message: "Digite sua PRO_KEY:" },
|
|
34
|
+
{ type: "text", name: "projectName", message: "Nome do projeto?", initial: "meu-app-domis" }
|
|
40
35
|
]);
|
|
41
36
|
template = res.template;
|
|
42
37
|
proKey = res.key;
|
|
@@ -48,33 +43,27 @@ async function main() {
|
|
|
48
43
|
await scaffold(template, cliProjectName, proKey);
|
|
49
44
|
}
|
|
50
45
|
async function scaffold(template, projectName, proKey) {
|
|
51
|
-
const spinner = ora(`Baixando
|
|
46
|
+
const spinner = ora(`Baixando ${pc.cyan(template)}...`).start();
|
|
52
47
|
try {
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
spinner.fail(pc.red("Template PRO precisa de PRO_KEY v\xE1lida."));
|
|
48
|
+
if (template.includes("pro") && (!proKey || proKey.length < 5)) {
|
|
49
|
+
spinner.fail(pc.red("Precisa de PRO_KEY"));
|
|
56
50
|
process.exit(1);
|
|
57
51
|
}
|
|
58
|
-
let source = `gh:Domisnnet/DomisPacks-Private/packs/${template}#main`;
|
|
59
52
|
const localTemplatePath = path.resolve(process.cwd(), "templates", template);
|
|
60
|
-
const
|
|
61
|
-
const srcPath = fs.existsSync(localTemplatePath) ? localTemplatePath : altPath;
|
|
53
|
+
const srcPath = localTemplatePath;
|
|
62
54
|
if (fs.existsSync(srcPath)) {
|
|
63
55
|
fs.cpSync(srcPath, path.resolve(process.cwd(), projectName), { recursive: true });
|
|
64
56
|
} else {
|
|
65
57
|
fs.mkdirSync(projectName, { recursive: true });
|
|
66
|
-
fs.writeFileSync(path.join(projectName, "firebase.json"), JSON.stringify({
|
|
67
|
-
hosting: { public: "dist/seu-projeto/browser", ignore: ["firebase.json", "**/.*", "**/node_modules/**"], rewrites: [{ source: "**", destination: "/index.html" }] }
|
|
68
|
-
}, null, 2));
|
|
58
|
+
fs.writeFileSync(path.join(projectName, "firebase.json"), JSON.stringify({ hosting: { public: "dist/seu-projeto/browser", rewrites: [{ source: "**", destination: "/index.html" }] } }, null, 2));
|
|
69
59
|
}
|
|
70
|
-
spinner.succeed(pc.green(`Template ${
|
|
71
|
-
console.log(
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
firebase deploy --only hosting`);
|
|
60
|
+
spinner.succeed(pc.green(`Template ${template} em./${projectName}`));
|
|
61
|
+
console.log(`
|
|
62
|
+
cd ${projectName}
|
|
63
|
+
npm install
|
|
64
|
+
firebase deploy`);
|
|
76
65
|
} catch (e) {
|
|
77
|
-
spinner.fail(pc.red("Falha
|
|
66
|
+
spinner.fail(pc.red("Falha"));
|
|
78
67
|
console.error(e.message);
|
|
79
68
|
}
|
|
80
69
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "create-domis",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.7",
|
|
4
4
|
"description": "CLI oficial do ecossistema Domis - Acelere seus projetos Angular + Firebase",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"bin": {
|
|
@@ -18,13 +18,12 @@
|
|
|
18
18
|
"angular",
|
|
19
19
|
"firebase",
|
|
20
20
|
"domis",
|
|
21
|
-
"domflix",
|
|
22
21
|
"create",
|
|
23
22
|
"cli",
|
|
24
23
|
"vitepress"
|
|
25
24
|
],
|
|
26
25
|
"author": "Domisnnet",
|
|
27
|
-
"license": "
|
|
26
|
+
"license": "LICENSE",
|
|
28
27
|
"dependencies": {
|
|
29
28
|
"chalk": "^5.3.0",
|
|
30
29
|
"giget": "^1.2.3",
|