Install packages from command line. Possible or not?

Hi there,
Does anyone know is there a way to install asset store packages from command line? Of course I mean that assets what I bought and download before.

I store my projects at github and I don’t wanna commit a 3rd party content there. It would be great if I could install all dependencies of my project, like NPM or Nuget do it, after clone repo.

Maybe someone from such big guys as @andeeeee , @Eric5h5 or @anon_85768832 know answer? :wink:

Thanks a million.

You could use the -importPackage command line argument? Ok you have to have it allready installed on your maschine, then you have it in your asset store foleder (C:\Users\USERNAME\AppData\Roaming\Unity\Asset Store-5.x.…).

1 Like

Wow, it’s great
I known about -importPackages, but I did not know anything about place where downloaded assets stored
Seems it could give me all what I need.

I believe that the command line option calls this method under the hood: Unity - Scripting API: AssetDatabase.ImportPackage

If you need to customize the process (e.g: run some stuff before/after import), you can use it to create your own custom package importer and then use that with the -executeMethod command line argument.

1 Like

Thanks a lot @liortal , it really help to figure out how everything works. I have implemented my own tool for that :wink:

But I still interesting how other developers manage a projects with big amount of 3rd party assets :roll_eyes:. My point still the same - we should not store all these stuff under the source control, but in this case we should manage used dependencies somehow.

UPD: Maybe someone know the way to get a list of assets (from AssetStore) used in particular project?

I don’t think the assets are tagged in any way, so there’s no way of really knowing whether an asset came from the asset store or from any other source…

I don’t meant knowing from what source asset came. I wondering if there is information what asset was imported or was created by user. Everything look like there are no such info :face_with_spiral_eyes:

Fast forward to 2021…

Can this be used to add packages from manifest.json under Packages??
For instance if I added a new dependency in the CI pipeline for the project…

3 Likes