diff options
author | dan <dan.abramov@gmail.com> | 2024-12-19 04:00:27 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-12-19 04:00:27 +0000 |
commit | c390c3278869df4df54b7831b515c91536cee4f0 (patch) | |
tree | dc6c28d8ae919df25aaf4614c54fb5b9f88487db /plugins | |
parent | c2ca84c636fe022c92f0e0d6fdf54033ceeb80a7 (diff) | |
download | voidsky-c390c3278869df4df54b7831b515c91536cee4f0.tar.zst |
Remove unreliable repository (#7176)
Diffstat (limited to 'plugins')
-rw-r--r-- | plugins/withAndroidNoJitpackPlugin.js | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/plugins/withAndroidNoJitpackPlugin.js b/plugins/withAndroidNoJitpackPlugin.js new file mode 100644 index 000000000..959eb1028 --- /dev/null +++ b/plugins/withAndroidNoJitpackPlugin.js @@ -0,0 +1,20 @@ +const {withProjectBuildGradle} = require('@expo/config-plugins') + +const jitpackRepository = "maven { url 'https://www.jitpack.io' }" + +module.exports = function withAndroidNoJitpackPlugin(config) { + return withProjectBuildGradle(config, config => { + if (!config.modResults.contents.includes(jitpackRepository)) { + throw Error( + 'Expected to find the jitpack string in the config. ' + + 'You MUST verify whether it was actually removed upstream, ' + + 'or if the format has changed and this plugin no longer recognizes it.', + ) + } + config.modResults.contents = config.modResults.contents.replaceAll( + jitpackRepository, + '', + ) + return config + }) +} |