question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Support for installing NugetForUnity via UPM

See original GitHub issue

Unity recently implemented support for the package manager to be able to reference github repos as packages using the following format: "com.popcron.console": "https://github.com/popcron/console.git"

With support for commitish identifiers, so you are able to target a specific branch if you add #branch. They don’t have any support for targeting a specific directory within a repository, so organizing it by folder isn’t possible. Though they are planning on supporting it later on according to their forum replies here.

The format for making a repository recognizable as a package by UPM, is to have a package.json file inside, and any .meta files included and up to date (documentation). My workflow with this, is to work with the repository cloned to my desktop, and reference it locally so that I am able to generate valid .meta files. "com.popcron.console": "file:/Users/phill/source/repos/Popcron.Console"

Cheers!

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Reactions:6
  • Comments:17

github_iconTop GitHub Comments

8reactions
assert-not-singularitycommented, Sep 30, 2020

I refactored the project so it is a valid UPM project using the reference provided by the Unity Manual. You can try out by pressing the + button in the Unity Package Manager, clicking Add package from git URL... and entering https://github.com/assert-not-singularity/NuGetForUnity.git#upm-package or by adding the dependency "com.glitchenzo.nugetforunity": "https://github.com/assert-not-singularity/NuGetForUnity.git#upm-package" to the manifest.json.

There are still the CreateDLL and Packager folders in this branch it but they are not required anymore. Therefore, I did not try out if creating the .unitypackage still works. In my opinion, providing this package using UPM makes these redundant.

Please try out if downloading the package via UPM works for you as well. I would then open a PR, if desired. But be aware to not use this in any productive project since I will might delete this testing branch some day.

2reactions
JoC0decommented, Feb 4, 2023

Implemented in #480

Read more comments on GitHub >

github_iconTop Results From Across the Web

📦 NuGet for Unity - com.glitchenzo.nugetforunity | OpenUPM
Package Management. This repository has UPM support. Use https://github.com/mob-sakai/UpmGitExtension for installing it directly in Unity.
Read more >
Nuget Package in UPM Package and Assembly definition
So I'm currently trying to make a UPM Package that contains some Nuget packages (currently imported as Dlls) and I have some questions...
Read more >
NuGetForUnity
Support for installing NugetForUnity via UPM $ 0. Created 4 years ago in GlitchEnzo/NuGetForUnity with 15 comments. Unity recently implemented support for the ......
Read more >
Install NuGet packages via UPM : r/Unity3D
Great idea! Unity definitely needs an easy way to pull in and manage compatible, non-Unity packages. Thanks for creating this service.
Read more >
Manual: Switching to another package version
If you want to update packages that were installed from a Git URL, you can use any of the following methods: Locate the...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found