-
Notifications
You must be signed in to change notification settings - Fork 525
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
[Aapt2] Aapt2 throws an error if a Resources/values/* file contains a dash #1780
Labels
Area: App+Library Build
Issues when building Library projects or Application projects.
vs-sync
For internal use only; creates a VSTS "mirror" issue.
Milestone
Comments
Looks like we forgot to include a |
dellis1972
added a commit
to dellis1972/xamarin-android
that referenced
this issue
Jun 7, 2018
…ames Fixes dotnet#1780 We forgot to include `-` as a valid character for the Resource filenames when implementing the `CheckForInvalidResourceFileNames` Task. As a result many working samples, when using `aapt2`, failed with. Resources\values\base-strings.xml : error APT0000: Invalid file name: It must contain only [a-zA-Z0-9_.]. [C:\xms\monodroid-samples\android-m\FingerprintDialog\FingerprintDialog\FingerprintDialog.csproj] The fix is to allow `-` as a filename character.
dellis1972
added a commit
to dellis1972/xamarin-android
that referenced
this issue
Jun 13, 2018
…ames Fixes dotnet#1780 We forgot to include `-` as a valid character for the Resource filenames when implementing the `CheckForInvalidResourceFileNames` Task. As a result many working samples, when using `aapt2`, failed with. Resources\values\base-strings.xml : error APT0000: Invalid file name: It must contain only [a-zA-Z0-9_.]. [C:\xms\monodroid-samples\android-m\FingerprintDialog\FingerprintDialog\FingerprintDialog.csproj] The fix is to allow `-` as a filename character.
dellis1972
added a commit
to dellis1972/xamarin-android
that referenced
this issue
Jun 13, 2018
…ames Fixes dotnet#1780 We forgot to include `-` as a valid character for the Resource filenames when implementing the `CheckForInvalidResourceFileNames` Task. As a result many working samples, when using `aapt2`, failed with. APT0000: Invalid file name: It must contain only [a-zA-Z0-9_.]. The fix is to allow `-` as a filename character. This is only done for `values` filenames, since they are the only ones which support `-`. For all other resource types `-` is invalid.
dellis1972
added a commit
to dellis1972/xamarin-android
that referenced
this issue
Jun 15, 2018
…ames Fixes dotnet#1780 We forgot to include `-` as a valid character for the Resource filenames when implementing the `CheckForInvalidResourceFileNames` Task. As a result many working samples, when using `aapt2`, failed with. APT0000: Invalid file name: It must contain only [a-zA-Z0-9_.]. The fix is to allow `-` as a filename character. This is only done for `values-*` resources, since they are the only ones which support `-`. For all other resource types `-` is invalid.
jonpryor
pushed a commit
that referenced
this issue
Jun 15, 2018
…1789) Fixes: #1780 If a project has an `@(AndroidResource)` with a filename that contains a `-`, `aapt2` will not support it *unless* the filename is in the `values` directory. Unfortunately, the `<CheckForInvalidResourceFileNames/>` task didn't special-case the `values*` directories, resulting in errors for files which `aapt2` would otherwise support: Resources\values\base-strings.xml : error APT0000: Invalid file name: It must contain only [a-zA-Z0-9_.]. Update the `<CheckForInvalidResourceFileNames/>` task so that it supports `-` within filename characters for files within the `values*` directories. For all other resource directories, `-` is still not permissable.
dellis1972
added a commit
that referenced
this issue
Jun 18, 2018
…1789) Fixes: #1780 If a project has an `@(AndroidResource)` with a filename that contains a `-`, `aapt2` will not support it *unless* the filename is in the `values` directory. Unfortunately, the `<CheckForInvalidResourceFileNames/>` task didn't special-case the `values*` directories, resulting in errors for files which `aapt2` would otherwise support: Resources\values\base-strings.xml : error APT0000: Invalid file name: It must contain only [a-zA-Z0-9_.]. Update the `<CheckForInvalidResourceFileNames/>` task so that it supports `-` within filename characters for files within the `values*` directories. For all other resource directories, `-` is still not permissable.
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Labels
Area: App+Library Build
Issues when building Library projects or Application projects.
vs-sync
For internal use only; creates a VSTS "mirror" issue.
This is currently a breaking change as compared to the original aapt tool. It seems our aapt2 support rejects all files which contain a dash. I haven't yet tested this behavior from within Android Studio, however the upstream version of the project in question here still uses dashes in certain resource file names:
https://github.com/googlesamples/android-FingerprintDialog/tree/master/Application/src/main/res/values.
Steps to Reproduce
https://github.com/xamarin/monodroid-samples/tree/master/android-m/FingerprintDialog
Actual Behavior
Version Information
XA version: 8.3.99.25 (monodroid/HEAD/620da263b)
Log File
http://xqa.blob.core.windows.net/gist/log-56f828c3e11b4542adead00a424bfd1f.txt
The text was updated successfully, but these errors were encountered: