-
Notifications
You must be signed in to change notification settings - Fork 564
[Xamarin.Android.Build.Tasks] Generate an R.txt for DesignTime Builds. #1094
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
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Member
|
Just a thought, could |
Contributor
Author
|
D'oh , it will. That will need fixing
…Sent from my Windows 10 phone
From: Jonathan Peppers
Sent: 11 December 2017 23:20
To: xamarin/xamarin-android
Cc: Dean Ellis; Author
Subject: Re: [xamarin/xamarin-android] [Xamarin.Android.Build.Tasks] Generatean R.txt for DesignTime Builds. (#1094)
@jonpryor
Just a thought, could IncrementalClean potentially delete R.txt with this PR as-is? If so, I can fix this tomorrow (and maybe add one test).
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub, or mute the thread.
|
Member
|
I’ll fix it tomorrow, enjoy your vacation!
… On Dec 11, 2017, at 5:38 PM, Dean Ellis ***@***.***> wrote:
D'oh , it will. That will need fixing
Sent from my Windows 10 phone
From: Jonathan Peppers
Sent: 11 December 2017 23:20
To: xamarin/xamarin-android
Cc: Dean Ellis; Author
Subject: Re: [xamarin/xamarin-android] [Xamarin.Android.Build.Tasks] Generatean R.txt for DesignTime Builds. (#1094)
@jonpryor
Just a thought, could IncrementalClean potentially delete R.txt with this PR as-is? If so, I can fix this tomorrow (and maybe add one test).
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub, or mute the thread.
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub, or mute the thread.
|
Member
|
build |
Commit fd96998 added support for reading and parsing R.txt files. This commit adds support for generating the file as part of the `_UpdateAndroidResgen` target. The idea is that if the R.txt file is present we should use that for our design time build Resource.Designer.cs.
Added `R.txt` to the `FileWrites` `<ItemGroup />`. Updated the `DesignTimeBuild` test: - Checks for the existance of `R.txt` after a `Build` - Refactor to keep `IntermediateOutputPath` in a variable - Use `FileAssert.Exists` instead of `Assert.IsTrue(File.Exists())`
jonpryor
pushed a commit
that referenced
this pull request
Dec 9, 2020
Context: #5331 Changes: xamarin/monodroid@0eef889...27736a7 * xamarin/monodroid@27736a7ff: [tools/msbuild] Fix App Bundle deployment (#1142) * xamarin/monodroid@f38dbc7ab: [tools/msbuild] use @(_AndroidMSBuildAllProjects) (#1140) * xamarin/monodroid@cfa21d57b: [tools/msbuild] Fix some issues with FastDev (#1139) * xamarin/monodroid@3ba648386: [tools/msbuild] Add missing parameter to BuildAppBundle. (#1138) * xamarin/monodroid@5bb29971b: [tools/msbuild] Add Multi User Support for Debugging. (#1135) * xamarin/monodroid@156abf47c: [tools/msbuild] default $(_AndroidAllowDeltaInstall) to false (#1137) * xamarin/monodroid@fbc961218: [build] Pass EnableCompression to BuildApk (#1094) Add support for running multi-user unit tests on device. It makes use of various adb commands to create test users and remove them. Create a guest user with name `{name}`: adb shell pm create-user --guest {name} Remove a guest user with the specified user id `{userId}`: adb shell pm remove-user --guest {userId} Note that user creation takes a "name", while deletion takes an id. To obtain the mapping, use: $ adb shell pm list users Users: UserInfo{0:Owner:c13} running UserInfo{10:guest1:414} The userId is the number *between* the `{` and the `:` and user name. The userId for `Owner` is 0, while the userId for `guest1` is 10. We can then use a `Regex` to pull out the required `userId` for a specific user. To switch a device to use user `{userId}`: adb shell am switch-user {userId} Emulators seem to create the main user with the name "Owner", so that should be the default name we use for the main user. In the unit tests if we cannot find a user named "Owner" when looking for "Owner" we will default to a `userId` of `0`. User ID 0 always means the default user. This is to handle the case where we are testing locally on devices where the main user is not called "Owner".
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Commit fd96998 added support for reading and parsing R.txt
files. This commit adds support for generating the file as
part of the
_UpdateAndroidResgentarget.The idea is that if the R.txt file is present we should use
that for our design time build Resource.Designer.cs.