Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(cli-dxns): Default deploy path is out/<encoded-dxn> #504

Merged
merged 3 commits into from
May 12, 2022

Conversation

wittjosiah
Copy link
Member

No description provided.


const publishFolder = path.join(process.cwd(), distPath || module.build!.outdir!);
const outPath = path ?? module.build?.outdir ?? `out/${encodeName(module.name!)}`;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

hey @wittjosiah it's kinda not intuitive, but module.build.outdir will always be defined because of https://github.com/dxos/cli/blob/main/packages/cli-dxns/src/utils/config.ts#L66

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh interesting. Is this value used anywhere else that you're aware of? Would removing that default value when the config is loaded and determining it dynamically here break things elsewhere?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think it's used only here;
I guess the idea was to have all "default" consts & logic inside config.ts (to have it in one place), and on the level of command handler allow only override with cli args

@wittjosiah wittjosiah merged commit 2f209bf into main May 12, 2022
@wittjosiah wittjosiah deleted the wittjosiah/default-out branch May 12, 2022 16:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants