Skip to content

Ensure templates create a proper AppID#18322

Merged
mattleibow merged 1 commit into
net8.0from
dev/jd/templates2
Oct 25, 2023
Merged

Ensure templates create a proper AppID#18322
mattleibow merged 1 commit into
net8.0from
dev/jd/templates2

Conversation

@jknaudt21
Copy link
Copy Markdown
Contributor

@jknaudt21 jknaudt21 commented Oct 24, 2023

Problem

After a template change that allowed new apps to specify the ApplicationID through the command line (#13509), if new apps created with spaces or non-alphanumeric characters in the name didn't specify an ApplicationID, they would be generated with an invalid ApplicationID.

Solution

Added an extra symbol created during template processing nameToAppId that grabs the app's lowercased name and creates a valid AppID that:

  • replaces any non-alphanumeric character that's not an underscore or period with "_"

Example: 123 Cats.Fishy+) => 123_cats.fishy__
 

Issues Fixed

Fixes #18177

@jknaudt21 jknaudt21 requested review from a team as code owners October 24, 2023 22:47
Comment thread src/Templates/src/templates/maui-blazor/.template.config/template.json Outdated
Comment thread src/Templates/src/templates/maui-blazor/.template.config/template.json Outdated
@mattleibow
Copy link
Copy Markdown
Member

Can this be rebased on net8.0 so it can be part of GA?

@jknaudt21 jknaudt21 changed the base branch from main to net8.0 October 24, 2023 23:03
@mattleibow mattleibow enabled auto-merge (squash) October 24, 2023 23:11
@mattleibow mattleibow merged commit 64da395 into net8.0 Oct 25, 2023
@mattleibow mattleibow deleted the dev/jd/templates2 branch October 25, 2023 00:54
@github-actions github-actions Bot locked and limited conversation to collaborators Dec 5, 2023
@samhouts samhouts added the fixed-in-8.0.100-rc.2.9530 Look for this fix in 8.0.100-rc.2.9530 label Aug 2, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

fixed-in-8.0.100-rc.2.9530 Look for this fix in 8.0.100-rc.2.9530

Projects

None yet

4 participants