Hi, trying to sort the attribs on a freshly created collection, I used the CLI appwrite deploy collection command but I ended with a new collection much more messy than what I created at first! I expected the attributes to be sorted as they appear in my appwrite.json file. Is there a way to achieve this? Thx.
You'll have to write a script using a server SDK
Or fork the CLI lol
You might also want to add a π to this issue: https://github.com/appwrite/sdk-for-cli/issues/79
The reason why is all the attributes are created at once: https://github.com/appwrite/sdk-for-cli/blob/ae7f9fecbbe5cc0cc702e878fd48cc8559fa18b2/lib/commands/deploy.js#L640 and so when they actually get created or finish creating is "random"
OK thx, I suspected something with the asynchronous way of creating the attribs... π Well, I think I will stick with the randomness of my initial attribs as they are less random than what I ended up! π
[SOLVED] CLI deploy = mess in the attribs
I submitted a PR with a --preserve option for deploy collection.
Recommended threads
- Framework categorization for Sites
Hello, I want to deploy my web app via Appwrite SItes. My web app is vite+reactjs. In the Appwrite docs, it creates a vite+react app, and chooses React from the...
- How to use Appwrite MCP on Claude Deskto...
Hello I'd like to use the Appwrite MCP with Claude Desktop and have set up the connector, but asking questions about my Appwrite instance does not work. Any ide...
- Impossible to create project via CLI?
Is it possible to create a new project via the appwrite CLI ? I need to create a few projects for something I'm working on and because i don't want to do it man...