appwrite / sdk-for-cli

[READ-ONLY] Official Appwrite CLI >_
BSD 3-Clause "New" or "Revised" License
85 stars 29 forks source link

feat: give a hint to run init and deploy command #90

Closed adarshjhaa100 closed 9 months ago

adarshjhaa100 commented 10 months ago

What does this PR do?

The existing appwrite deploy [subcommand] gives a cryptic error message in absence of appwrite.json file in the working directory. ✗ Error No functions found in the current directory.

The feature has fixed this issue and now displays the following message instead:

✗ Error: No appwrite.json file found in the current directory. This command must be run in the folder holding your appwrite.json file. Please run this command again in the folder containing your appwrite.json file, or run [command to init appwrite.json].

The changes have been made for all of the services where where the cryptic message was displayed: function, collection, bucket and team

Test Plan

Testing Type : Manual

Scenario: When appwrite.json is not present in the working directory

image

Before :

image

After:

image image image image

Related PRs and Issues

Issue #87 , Feature: Give a hint to where you should run init and deploy commands

Have you read the Contributing Guidelines on issues?

Yes

stnguyen90 commented 10 months ago

@adarshjhaa100 thanks for creating this PR! Unfortunately, this is a read-only repo as the code is generated by our SDK Generator, and changes made only here would be wiped in the next release.