0

I have multiple sanity projects in my account. How can I switch to a particular account/project in my sanity cli for deploying the schema to correct project ?

evolutionxbox
  • 3,932
  • 6
  • 34
  • 51
user9040429
  • 690
  • 1
  • 8
  • 29
  • 1
    What commands are you using? Usually the CLI is run in the folder of the sanity project. If you want a different project, why not try and change the folder? – evolutionxbox Feb 03 '22 at 14:46
  • Yes, I using it in folder of sanity project. It seems currently sanity CLI does not provide a way to deploy to particular project id. – user9040429 Feb 04 '22 at 13:37

1 Answers1

0

Currently sanity CLI does not provide a direct way to deploy schema to particular projectID. But it can be done in to ways:

  • Type sanity init in your sanity project and then select your project id.
  • Just change the projectID in sanity.json.
user9040429
  • 690
  • 1
  • 8
  • 29