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

[eas-cli] verify that "name" in app.sjon can be used as iOS target name #280

Merged
merged 1 commit into from
Mar 18, 2021

Conversation

wkozyra95
Copy link
Contributor

@wkozyra95 wkozyra95 commented Mar 18, 2021

Checklist

Why

If the name does not contain any alphanumeric characters sanitized version is empty string and can't be used as target name

How

verify before and after sanitization whether exp.name is empty

Test Plan

run build with invalid name

@wkozyra95 wkozyra95 force-pushed the @wkozyra95/verify-that-target-name-is-not-empty branch from 0eca64b to 7b243ba Compare March 18, 2021 11:02
@wkozyra95 wkozyra95 requested a review from dsokal March 18, 2021 11:03
@github-actions
Copy link

github-actions bot commented Mar 18, 2021

Size Change: +622 B (0%)

Total Size: 32.8 MB

Filename Size Change
./packages/eas-cli/dist/eas-linux-x64.tar.gz 32.8 MB +622 B (0%)

compressed-size-action

Comment on lines +49 to +51
if (!commandCtx.exp.name) {
throw new Error('"expo.name" is required in your app.json');
}
Copy link
Contributor

Choose a reason for hiding this comment

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

Is this check necessary? I think it is always defined.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I prefer to check that just in case, e.g. someone can have name: '' in app.json

@wkozyra95 wkozyra95 requested a review from dsokal March 18, 2021 11:13
@wkozyra95 wkozyra95 merged commit 0117dbf into main Mar 18, 2021
@wkozyra95 wkozyra95 deleted the @wkozyra95/verify-that-target-name-is-not-empty branch March 18, 2021 11:15
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.

2 participants