Skip to content

Commit

Permalink
Merge pull request #663 from f1yingbanana/master
Browse files Browse the repository at this point in the history
Add and release OpenUPM support.
  • Loading branch information
a-maurice authored Dec 21, 2023
2 parents ae200af + da0779a commit ecae23d
Show file tree
Hide file tree
Showing 96 changed files with 4,405 additions and 1,295 deletions.
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
# Version 1.2.178 - Dec 20, 2023
* Added [OpenUPM support](https://openupm.com/packages/com.google.external-dependency-manager/).

# Version 1.2.177 - Aug 14, 2023
* iOS Resolver - Added `/opt/homebrew/bin` to Cocoapod executable search path.
Fixes #627
Expand Down
1,296 changes: 677 additions & 619 deletions README.md

Large diffs are not rendered by default.

23 changes: 19 additions & 4 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -255,7 +255,7 @@ project.ext {
// Directory for testing.
testDir = new File(scriptDirectory, "test_output")
// Version of the plugin (update this with CHANGELOG.md on each release).
pluginVersion = "1.2.177"
pluginVersion = "1.2.178"
// Directory that contains the template plugin.
// Files under this directory are copied into the staging area for the
// plugin.
Expand All @@ -264,14 +264,18 @@ project.ext {
pluginStagingAreaDir = new File(buildDir, "staging")
// Directory where the build plugin is unpacked to.
pluginExplodedDir = new File(scriptDirectory, "exploded")
// Directory where the UPM package is unpacked to.
pluginUpmDir = new File(scriptDirectory, "upm")
// Base filename of the released plugin.
currentPluginBasename = "external-dependency-manager"
// Base UPM package name of the released plugin.
currentPluginUpmPackageName = "com.google.external-dependency-manager"
// Where the exported plugin file is built before it's copied to the release
// location.
pluginExportFile = new File(buildDir, currentPluginBasename + ".unitypackage")
// Where the exported UPM plugin file is built.
pluginUpmExportFile = new File(buildDir,
currentPluginBasename + pluginVersion + ".tgz")
currentPluginUpmPackageName + "-" + pluginVersion + ".tgz")
// Directory within the plugin staging area that just contains the plugin.
pluginAssetsDir = new File("Assets", "ExternalDependencyManager")
// Directories within the staging area to export.
Expand Down Expand Up @@ -2069,8 +2073,7 @@ buildPlugin.with {
}

// Guid paths for UPM package.
File upmPluginPackageDir = new File("com.google.external-dependency-manager",
"ExternalDependencyManager")
File upmPluginPackageDir = new File(currentPluginUpmPackageName, "ExternalDependencyManager")
File upmPluginEditorDir = new File(upmPluginPackageDir, "Editor")
File upmPluginDllDir = new File(upmPluginEditorDir, project.ext.pluginVersion)

Expand Down Expand Up @@ -2121,6 +2124,7 @@ task releasePlugin(dependsOn: [buildPlugin, buildUpmPlugin]) {
fileTree(dir: project.ext.pluginExplodedDir),
pluginTemplateFilesMap.values())
doLast {
// Delete and regenerate built .unitypackage in the repo.
delete fileTree(
dir: project.ext.pluginReleaseFile.parentFile,
includes: [project.ext.currentPluginBasename + "-*.unitypackage"])
Expand All @@ -2134,6 +2138,7 @@ task releasePlugin(dependsOn: [buildPlugin, buildUpmPlugin]) {
into project.ext.pluginReleaseFileUnversioned.parentFile
rename { src_filename -> project.ext.pluginReleaseFileUnversioned.name }
}
// Delete and regenerate the exploded plugin folder in the repo.
delete fileTree(dir: project.ext.pluginExplodedDir)
copy {
from project.ext.pluginStagingAreaDir
Expand All @@ -2142,6 +2147,16 @@ task releasePlugin(dependsOn: [buildPlugin, buildUpmPlugin]) {
it.path + "/**/*"
}
}
// Delete and regenerate the UPM package in the repo.
delete fileTree(dir: project.ext.pluginUpmDir)
copy {
// Rename the top-level package folder to upm.
eachFile {
path = path.replaceFirst(/^.+?\//, "upm/")
}
from tarTree(project.ext.pluginUpmExportFile)
into project.ext.scriptDirectory
}
pluginTemplateFilesMap.each {
sourceFile, targetFile -> copyFile(sourceFile, targetFile)
}
Expand Down
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.

This file was deleted.

Binary file not shown.
Binary file not shown.

This file was deleted.

Binary file not shown.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Binary file not shown.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Binary file not shown.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Binary file not shown.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Binary file not shown.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Binary file not shown.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Binary file not shown.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Binary file not shown.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 3 additions & 0 deletions exploded/Assets/ExternalDependencyManager/Editor/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
# Version 1.2.178 - Dec 20, 2023
* Added [OpenUPM support](https://openupm.com/packages/com.google.external-dependency-manager/).

# Version 1.2.177 - Aug 14, 2023
* iOS Resolver - Added `/opt/homebrew/bin` to Cocoapod executable search path.
Fixes #627
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Binary file not shown.
Binary file not shown.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Binary file not shown.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions exploded/Assets/ExternalDependencyManager/Editor/LICENSE.meta

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit ecae23d

Please sign in to comment.