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

fix dollar sign in public file #2356

Closed

Conversation

realityJie
Copy link

I try to remove some item with dollar sign in public.xml file.
If we use aapt2 command to create R.java file, it will cause some error:

/home/jerry/git_code/AgentPack/temp/9dc1d1ce-9f15-11ea-95ce-e0d55ebafe0d/res/values/public.xml:983: error: resource 'drawable/$avd_hide_password__0' has invalid entry name '$avd_hide_password__0'. Invalid character '$avd_hide_password__0'.
/home/jerry/git_code/AgentPack/temp/9dc1d1ce-9f15-11ea-95ce-e0d55ebafe0d/res/values/public.xml:984: error: resource 'drawable/$avd_hide_password__1' has invalid entry name '$avd_hide_password__1'. Invalid character '$avd_hide_password__1'.
/home/jerry/git_code/AgentPack/temp/9dc1d1ce-9f15-11ea-95ce-e0d55ebafe0d/res/values/public.xml:985: error: resource 'drawable/$avd_hide_password__2' has invalid entry name '$avd_hide_password__2'. Invalid character '$avd_hide_password__2'.
/home/jerry/git_code/AgentPack/temp/9dc1d1ce-9f15-11ea-95ce-e0d55ebafe0d/res/values/public.xml:986: error: resource 'drawable/$avd_show_password__0' has invalid entry name '$avd_show_password__0'. Invalid character '$avd_show_password__0'.
/home/jerry/git_code/AgentPack/temp/9dc1d1ce-9f15-11ea-95ce-e0d55ebafe0d/res/values/public.xml:987: error: resource 'drawable/$avd_show_password__1' has invalid entry name '$avd_show_password__1'. Invalid character '$avd_show_password__1'.
/home/jerry/git_code/AgentPack/temp/9dc1d1ce-9f15-11ea-95ce-e0d55ebafe0d/res/values/public.xml:988: error: resource 'drawable/$avd_show_password__2' has invalid entry name '$avd_show_password__2'. Invalid character '$avd_show_password__2'.

on the other hand to fix #1776

@realityJie realityJie force-pushed the fix-dollar-sign-in-public-file branch from 24d0a6c to 0304218 Compare May 26, 2020 06:07
@realityJie realityJie force-pushed the fix-dollar-sign-in-public-file branch from f520c5d to 81d430f Compare May 26, 2020 06:17
@iBotPeaches
Copy link
Owner

Hey, I don't think this is the right path. We can't just remove characters. The correct fix is allowing a more restrictive aapt/aapt2 to not care about these chars as they were allowed in older builds.

Thanks for the PR, but I'm going to close this route.

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.

Use aapt2 build apk failed
2 participants