This repository has been archived by the owner on Jan 18, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 478
Conversation
This file contains 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
created facebook app id string plugin
Closed
brentvatne
approved these changes
Nov 10, 2020
i took a stab at clarifying wording in a few places in 44a9391 - feel free to revert / correct anything that is factually incorrect or that you think i made worse |
EvanBacon
commented
Nov 10, 2020
Co-authored-by: Brent Vatne <brentvatne@gmail.com>
Co-authored-by: Brent Vatne <brentvatne@gmail.com>
bbarthec
approved these changes
Nov 10, 2020
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I really like the direction it is going! 👍
So, my understanding is that we have built-in suport for modified limited set of files (AndroidManifest
, two .gradle
files and a bunch of files in res
directory), but we also can modify arbitrary xml/java/kt
file by using some dangerous
technique? 🤔
Comment on lines
+62
to
+106
// project build.gradle | ||
AndroidConfig.GoogleServices.withClassPath, | ||
|
||
// app/build.gradle | ||
AndroidConfig.GoogleServices.withApplyPlugin, | ||
AndroidConfig.Package.withPackageGradle, | ||
AndroidConfig.Version.withVersion, | ||
|
||
// AndroidManifest.xml | ||
AndroidConfig.Package.withPackageManifest, | ||
AndroidConfig.AllowBackup.withAllowBackup, | ||
AndroidConfig.Scheme.withScheme, | ||
AndroidConfig.Orientation.withOrientation, | ||
AndroidConfig.Permissions.withPermissions, | ||
AndroidConfig.Branch.withBranch, | ||
AndroidConfig.Facebook.withFacebookManifest, | ||
|
||
AndroidConfig.UserInterfaceStyle.withUiModeManifest, | ||
AndroidConfig.GoogleMobileAds.withGoogleMobileAdsConfig, | ||
AndroidConfig.GoogleMapsApiKey.withGoogleMapsApiKey, | ||
AndroidConfig.IntentFilters.withAndroidIntentFilters, | ||
[AndroidConfig.Updates.withUpdates, { expoUsername }], | ||
|
||
// MainActivity.* | ||
AndroidConfig.UserInterfaceStyle.withUiModeMainActivity, | ||
|
||
// strings.xml | ||
AndroidConfig.Name.withName, | ||
AndroidConfig.Facebook.withFacebookAppIdString, | ||
|
||
// Dangerous -- these plugins run in reverse order. | ||
AndroidConfig.GoogleServices.withGoogleServicesFile, | ||
|
||
// Modify colors.xml and styles.xml | ||
AndroidConfig.RootViewBackgroundColor.withRootViewBackgroundColor, | ||
AndroidConfig.NavigationBar.withNavigationBar, | ||
AndroidConfig.StatusBar.withStatusBar, | ||
AndroidConfig.PrimaryColor.withPrimaryColor, | ||
|
||
AndroidConfig.Icon.withIcons, | ||
AndroidConfig.SplashScreen.withSplashScreen, | ||
|
||
// If we renamed the package, we should also move it around and rename it in source files | ||
// Added last to ensure this plugin runs first. Out of tree solutions will mistakenly resolve the package incorrectly otherwise. | ||
AndroidConfig.Package.withPackageRefactor, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks awesome 🤩
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.
Wrap all existing config methods in plugins and unify the file writing for common operations. A lot of complex functionality is wrapped in dangerous mods pending more investigation on how to make them safer. mods like "android.strings" currently don't account for any kind of localization but this could possibly be provided to the mod as a
modRequest
property.Test Plan