@stacksjs/actions 0.58.73 → 0.59.2
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/dist/action.d.ts +36 -0
- package/dist/add.d.ts +6 -0
- package/dist/build/component-libs.d.ts +1 -0
- package/dist/build/core.d.ts +1 -0
- package/dist/build/stacks.d.ts +1 -0
- package/dist/build.d.ts +9 -0
- package/dist/bump.d.ts +1 -0
- package/dist/changelog.d.ts +1 -0
- package/dist/clean.d.ts +1 -0
- package/dist/commit.d.ts +3 -0
- package/dist/copy-types.d.ts +5 -0
- package/dist/database/seed.d.ts +1 -0
- package/dist/deploy/index.d.ts +1 -0
- package/dist/dev/components.d.ts +1 -0
- package/dist/dev/docs.d.ts +1 -0
- package/dist/dev/index.d.ts +10 -0
- package/dist/examples.d.ts +5 -0
- package/dist/fresh.d.ts +1 -0
- package/dist/generate/component-meta.d.ts +5 -0
- package/dist/generate/ide-helpers.d.ts +6 -0
- package/dist/generate/index.d.ts +13 -0
- package/dist/generate/lib-entries.d.ts +2 -0
- package/dist/generate/vscode-custom-data.d.ts +6 -0
- package/dist/helpers/component-meta.d.ts +22 -0
- package/dist/helpers/lib-entries.d.ts +13 -0
- package/dist/helpers/package-json.d.ts +3 -0
- package/dist/helpers/utils.d.ts +18 -0
- package/dist/helpers/vscode-custom-data.d.ts +2 -0
- package/dist/index.d.ts +7 -0
- package/dist/key-generate.d.ts +1 -0
- package/dist/lint/fix.d.ts +1 -0
- package/dist/lint/index.d.ts +1 -0
- package/dist/make.d.ts +20 -0
- package/dist/prepublish.d.ts +1 -0
- package/dist/release.d.ts +2 -0
- package/dist/test/coverage.d.ts +1 -0
- package/dist/test/feature.d.ts +1 -0
- package/dist/test/ui.d.ts +1 -0
- package/dist/test/unit.d.ts +1 -0
- package/dist/test.d.ts +1 -0
- package/dist/tinker.d.ts +1 -0
- package/dist/typecheck.d.ts +1 -0
- package/dist/types.d.ts +3 -0
- package/dist/upgrade/dependencies.d.ts +1 -0
- package/dist/upgrade/framework.d.ts +1 -0
- package/dist/upgrade/index.d.ts +1 -0
- package/dist/upgrade.d.ts +4 -0
- package/package.json +5 -3
- package/src/bump.ts +8 -3
- package/src/check/ports.ts +11 -8
- package/src/deploy/index.ts +2 -6
- package/src/dev/index.ts +1 -1
- package/src/find-projects.ts +1 -1
- package/src/generate/index.ts +1 -1
- package/src/helpers/utils.ts +10 -14
- package/src/index.ts +1 -2
- package/src/lint/fix.ts +1 -0
- package/src/upgrade/shell.ts +5 -5
- package/dist/src/add.js +0 -29
- package/dist/src/build/component-libs.js +0 -6
- package/dist/src/build/core.js +0 -21
- package/dist/src/build/stacks.js +0 -8
- package/dist/src/build.js +0 -219
- package/dist/src/bump.js +0 -14
- package/dist/src/changelog.js +0 -17
- package/dist/src/clean.js +0 -6
- package/dist/src/commit.js +0 -17
- package/dist/src/copy-types.js +0 -14
- package/dist/src/database/seed.js +0 -1
- package/dist/src/deploy/index.js +0 -31
- package/dist/src/dev/components.js +0 -11
- package/dist/src/dev/docs.js +0 -7
- package/dist/src/dev/index.js +0 -92
- package/dist/src/examples.js +0 -43
- package/dist/src/fresh.js +0 -18
- package/dist/src/generate/component-meta.js +0 -59
- package/dist/src/generate/ide-helpers.js +0 -91
- package/dist/src/generate/index.js +0 -154
- package/dist/src/generate/lib-entries.js +0 -170
- package/dist/src/generate/vscode-custom-data.js +0 -91
- package/dist/src/helpers/component-meta.js +0 -50
- package/dist/src/helpers/index.js +0 -48
- package/dist/src/helpers/lib-entries.js +0 -161
- package/dist/src/helpers/package-json.js +0 -136
- package/dist/src/helpers/utils.js +0 -48
- package/dist/src/helpers/vscode-custom-data.js +0 -83
- package/dist/src/index.js +0 -590
- package/dist/src/key-generate.js +0 -10
- package/dist/src/lint/fix.js +0 -12
- package/dist/src/lint/index.js +0 -17
- package/dist/src/make.js +0 -291
- package/dist/src/prepublish.js +0 -14
- package/dist/src/release.js +0 -559
- package/dist/src/test/coverage.js +0 -6
- package/dist/src/test/feature.js +0 -6
- package/dist/src/test/ui.js +0 -6
- package/dist/src/test/unit.js +0 -6
- package/dist/src/test.js +0 -6
- package/dist/src/tinker.js +0 -5
- package/dist/src/typecheck.js +0 -6
- package/dist/src/types.js +0 -21
- package/dist/src/upgrade/dependencies.js +0 -6
- package/dist/src/upgrade/framework.js +0 -1
- package/dist/src/upgrade/index.js +0 -58
- package/dist/src/upgrade.js +0 -47
- package/src/generate/caddyfile.ts +0 -44
- package/src/helpers/index.ts +0 -1
- package/src/start-caddy.ts +0 -13
package/dist/src/upgrade.js
DELETED
|
@@ -1,47 +0,0 @@
|
|
|
1
|
-
// @bun
|
|
2
|
-
// src/upgrade.ts
|
|
3
|
-
import process from "process";
|
|
4
|
-
import {intro, outro, runCommand} from "@stacksjs/cli";
|
|
5
|
-
import {log} from "@stacksjs/logging";
|
|
6
|
-
import {projectPath} from "@stacksjs/path";
|
|
7
|
-
import * as storage from "@stacksjs/storage";
|
|
8
|
-
import {NpmScript} from "@stacksjs/enums";
|
|
9
|
-
// package.json
|
|
10
|
-
var version = "0.58.73";
|
|
11
|
-
|
|
12
|
-
// src/upgrade.ts
|
|
13
|
-
function checkForUncommittedChanges(options) {
|
|
14
|
-
try {
|
|
15
|
-
} catch (error) {
|
|
16
|
-
if (error.status === 1) {
|
|
17
|
-
if (!options?.force) {
|
|
18
|
-
}
|
|
19
|
-
}
|
|
20
|
-
}
|
|
21
|
-
}
|
|
22
|
-
async function downloadFrameworkUpdate(options) {
|
|
23
|
-
const tempFolderName = "updates";
|
|
24
|
-
const tempUpdatePath = projectPath(tempFolderName);
|
|
25
|
-
if (storage.doesFolderExist(tempUpdatePath))
|
|
26
|
-
await deleteFolder(tempUpdatePath);
|
|
27
|
-
log.info("Downloading framework updates...");
|
|
28
|
-
await runCommand(`giget stacks ${tempFolderName}`, options);
|
|
29
|
-
log.success(`Your framework updated correctly to version: v${version}`);
|
|
30
|
-
}
|
|
31
|
-
async function updateDependencies() {
|
|
32
|
-
const perf = await intro("buddy upgrade:dependencies");
|
|
33
|
-
const result = await runCommand(NpmScript.UpgradeDependencies, {
|
|
34
|
-
cwd: projectPath()
|
|
35
|
-
});
|
|
36
|
-
if (result.isErr()) {
|
|
37
|
-
await outro("While running the upgrade:dependencies command, there was an issue", { startTime: perf, useSeconds: true }, result.error);
|
|
38
|
-
process.exit();
|
|
39
|
-
}
|
|
40
|
-
await outro("Freshly updated your dependencies.", { startTime: perf, useSeconds: true });
|
|
41
|
-
process.exit();
|
|
42
|
-
}
|
|
43
|
-
export {
|
|
44
|
-
updateDependencies,
|
|
45
|
-
downloadFrameworkUpdate,
|
|
46
|
-
checkForUncommittedChanges
|
|
47
|
-
};
|
|
@@ -1,44 +0,0 @@
|
|
|
1
|
-
import os from 'node:os'
|
|
2
|
-
import { logger } from '@stacksjs/logging'
|
|
3
|
-
import { findStacksProjects } from '@stacksjs/utils'
|
|
4
|
-
|
|
5
|
-
logger.log('Generating Local Reverse Proxy...')
|
|
6
|
-
|
|
7
|
-
const options = { quiet: true }
|
|
8
|
-
const projects = await findStacksProjects(os.homedir(), options)
|
|
9
|
-
|
|
10
|
-
// TODO: need to generate one caddyfile that can be used for all projects on the system (each projects gets its own *.localhost domain)
|
|
11
|
-
// TODO: need to create a watcher
|
|
12
|
-
// TODO: need to create an action that can be run to add a new project
|
|
13
|
-
// TODO: need to an action that checks whether there are an env port clashes aross projects
|
|
14
|
-
|
|
15
|
-
// eslint-disable-next-line no-console
|
|
16
|
-
console.log(projects)
|
|
17
|
-
|
|
18
|
-
// const caddyfile = `stacksjs.localhost {
|
|
19
|
-
// route {
|
|
20
|
-
// @
|
|
21
|
-
|
|
22
|
-
// @libs {
|
|
23
|
-
// path /libs/*
|
|
24
|
-
// }
|
|
25
|
-
|
|
26
|
-
// handle @libs {
|
|
27
|
-
// reverse_proxy localhost:3003
|
|
28
|
-
// }
|
|
29
|
-
|
|
30
|
-
// @api {
|
|
31
|
-
// path /api/*
|
|
32
|
-
// }
|
|
33
|
-
|
|
34
|
-
// handle @api {
|
|
35
|
-
// reverse_proxy localhost:3999
|
|
36
|
-
// }
|
|
37
|
-
|
|
38
|
-
// handle {
|
|
39
|
-
// reverse_proxy localhost:3000
|
|
40
|
-
// }
|
|
41
|
-
// }
|
|
42
|
-
// }`
|
|
43
|
-
|
|
44
|
-
// await storage.writeFile(p.frameworkPath('types/actions.d.ts'), caddyfile)
|
package/src/helpers/index.ts
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from './utils'
|
package/src/start-caddy.ts
DELETED
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import { handleError } from '@stacksjs/error-handling'
|
|
2
|
-
import { runCommand } from '@stacksjs/cli'
|
|
3
|
-
import { path as p } from '@stacksjs/path'
|
|
4
|
-
|
|
5
|
-
// eslint-disable-next-line no-console
|
|
6
|
-
console.log('Starting Caddy...')
|
|
7
|
-
|
|
8
|
-
const result = await runCommand('caddy run', {
|
|
9
|
-
cwd: p.frameworkPath(),
|
|
10
|
-
})
|
|
11
|
-
|
|
12
|
-
if (result.isErr())
|
|
13
|
-
handleError(result.error)
|