Skip to content

Commit 7828514

Browse files
committed
chore: wip
1 parent c21ef72 commit 7828514

File tree

6 files changed

+27
-19
lines changed

6 files changed

+27
-19
lines changed

config/ai.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,5 +26,5 @@ export default {
2626
'meta.llama2-70b-chat-v1',
2727
],
2828

29-
deploy: true,
29+
deploy: true, // deploys AI endpoints
3030
} satisfies AiConfig

storage/framework/core/actions/src/bump.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ const bumpCommand = options?.dryRun
1212
? 'bunx bumpp ./package.json ./core/**/package.json ./ide/vscode/package.json --no-push'
1313
: 'bunx bumpp ./package.json ./core/**/package.json ./ide/vscode/package.json --all'
1414

15-
await runCommand(
16-
bumpCommand,
17-
{ cwd: p.frameworkPath(), stdin: 'inherit' },
18-
)
15+
await runCommand(bumpCommand, {
16+
cwd: p.frameworkPath(),
17+
stdin: 'inherit',
18+
})

storage/framework/core/actions/src/helpers/utils.ts

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import * as storage from '@stacksjs/storage'
2-
import { buddyOptions, italic, parseOptions, runCommand, runCommands, underline } from '@stacksjs/cli'
2+
import { buddyOptions, runCommand, runCommands } from '@stacksjs/cli'
33
import { log } from '@stacksjs/logging'
44
import * as p from '@stacksjs/path'
55
import type { ActionOptions, StacksError, Subprocess } from '@stacksjs/types'
@@ -22,8 +22,8 @@ export async function runAction(action: string, options?: ActionOptions): Promis
2222
...options,
2323
}
2424

25-
log.debug('runAction:', underline(italic(cmd)))
26-
log.debug('runAction Options:', optionsWithCwd)
25+
log.debug('runAction:', cmd)
26+
log.debug('action options:', optionsWithCwd)
2727

2828
if (!hasAction(action))
2929
return err(handleError(`The specified action "${action}" does not exist`))
@@ -39,6 +39,9 @@ export async function runAction(action: string, options?: ActionOptions): Promis
3939
* @returns The result of the command.
4040
*/
4141
export async function runActions(actions: string[], options?: ActionOptions) {
42+
log.debug('runActions:', actions)
43+
log.debug('actions options:', options)
44+
4245
if (!actions.length)
4346
return err('No actions were specified')
4447

@@ -51,11 +54,13 @@ export async function runActions(actions: string[], options?: ActionOptions) {
5154

5255
const o = {
5356
cwd: options?.cwd || p.projectPath(),
54-
...parseOptions(),
57+
...options,
5558
}
5659

5760
const commands = actions.map(action => `bun --bun ${p.relativeActionsPath(`${action}.ts`)} ${opts}`)
5861

62+
// eslint-disable-next-line no-console
63+
console.log('this should have inherit:', o)
5964
return await runCommands(commands, o)
6065
}
6166

storage/framework/core/actions/src/release.ts

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,9 @@ await runActions([
1010
Action.LintFix, // ensure there are no lint errors
1111
// Action.Test, // run the tests
1212
Action.Bump, // bump the versions, create the git tag, generate the changelog, commit & push the changes
13-
], { cwd: projectPath(), stdin: 'inherit' }) // debug mode needs to be enabled to see the output due to the interactive prompts
13+
], { // debug mode needs to be enabled to see the output due to the interactive prompts
14+
cwd: projectPath(),
15+
stdin: 'inherit',
16+
})
1417

1518
log.success(`Successfully released ${app.name}`)

storage/framework/core/cli/src/exec.ts

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -33,9 +33,9 @@ export async function exec(command: string | string[], options?: CliOptions): Pr
3333
if (!cmd)
3434
return err(handleError(`Failed to parse command: ${cmd}`, options))
3535

36-
log.debug('Running exec:', Array.isArray(command) ? command.join(' ') : command)
36+
log.debug('exec:', Array.isArray(command) ? command.join(' ') : command)
3737
log.debug('cmd:', cmd)
38-
log.debug('Options:', options)
38+
log.debug('exec options:', options)
3939

4040
const proc = Bun.spawn(cmd, {
4141
...options,
@@ -51,12 +51,12 @@ export async function exec(command: string | string[], options?: CliOptions): Pr
5151
})
5252

5353
// Check if we need to write to stdin
54-
if (options?.stdin === 'pipe' && options.input) {
55-
if (proc.stdin) {
56-
proc.stdin.write(options.input)
57-
proc.stdin.end()
58-
}
59-
}
54+
// if (options?.stdin === 'pipe' && options.input) {
55+
// if (proc.stdin) {
56+
// proc.stdin.write(options.input)
57+
// proc.stdin.end()
58+
// }
59+
// }
6060

6161
const exited = await proc.exited
6262
if (exited === ExitCode.Success)

storage/framework/core/cli/src/run.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ import { log } from './console'
3131
*/
3232
export async function runCommand(command: string, options?: CliOptions): Promise<Result<Subprocess, CommandError>> {
3333
log.debug('runCommand:', command)
34-
log.debug('runCommand Options:', options)
34+
log.debug('options:', options)
3535

3636
return await exec(command, options)
3737
}

0 commit comments

Comments
 (0)