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

[Localization] Fix build for path containing spaces #381

Merged
merged 2 commits into from Feb 16, 2019

Conversation

@Kryptos-FR
Copy link
Collaborator

Kryptos-FR commented Feb 16, 2019

PR Details

If the path to the project contains any spaces, then the build steps for the localization files will fail.

Description

Escape all paths in the command line. Special case for$(TargetDir) that needs an extra . since otherwise the last quote is escaped as well.

Related Issue

None.

Motivation and Context

Building from sources will fail for users that have a space in the path where the sources are located. Especially annoying if the space is in the username.

Types of changes

  • Docs change / refactoring / dependency upgrade
  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)

Checklist

  • My change requires a change to the documentation.
  • I have added tests to cover my changes.
  • All new and existing tests passed.
@dfkeenan

This comment has been minimized.

Copy link
Contributor

dfkeenan commented Feb 16, 2019

You should probably also update "\docs\technical\editor-localization.md".

@xen2

This comment has been minimized.

Copy link
Member

xen2 commented Feb 16, 2019

Curious, shouldn't it be " rather than "?

Also, note that if I create a new csproj, it uses <Target Name="PreBuild" BeforeTargets="PreBuildEvent"> rather than PostBuildEvent. Xml values vs attribute might have different escape rules (esp. attribute you can use single quote as main delimiter so that double quote works as is).

@dfkeenan

This comment has been minimized.

Copy link
Contributor

dfkeenan commented Feb 16, 2019

According to the XML spec &quot; is only required for attribute values.

@xen2

This comment has been minimized.

Copy link
Member

xen2 commented Feb 16, 2019

@dfkeenan ok thanks for the clarification (not a XML expert).

I will probably merge this PR as is then.

@dfkeenan

This comment has been minimized.

Copy link
Contributor

dfkeenan commented Feb 16, 2019

I'm no expert either. But I did some googling and everything I found only mentioned &quot; in regards to attributes.

There were already " in there just not on all file paths. And seeing how it builds (I assume) I don't think it will make things worse. :)

@xen2 xen2 merged commit 7c63ed9 into xenko3d:master Feb 16, 2019
2 checks passed
2 checks passed
WIP ready for review
Details
license/cla Contributor License Agreement is signed.
Details
@xen2

This comment has been minimized.

Copy link
Member

xen2 commented Feb 16, 2019

Thanks, merged!

@Kryptos-FR Kryptos-FR deleted the Kryptos-FR:bugfix/localization-build branch Feb 16, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
3 participants
You can’t perform that action at this time.