Skip to content
Merged

Dev #193

Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ Once the installation is complete, you can verify the install using

```sh
$ appwrite -v
9.0.2
9.1.0
```

### Install using prebuilt binaries
Expand Down Expand Up @@ -60,7 +60,7 @@ $ scoop install https://raw.githubusercontent.com/appwrite/sdk-for-cli/master/sc
Once the installation completes, you can verify your install using
```
$ appwrite -v
9.0.2
9.1.0
```

## Getting Started
Expand Down
5 changes: 5 additions & 0 deletions docs/examples/databases/create-line-attribute.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
appwrite databases create-line-attribute \
--database-id <DATABASE_ID> \
--collection-id <COLLECTION_ID> \
--key '' \
--required false
Comment on lines +1 to +5
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue

Fix invalid example: --key '' is misleading/likely invalid

Users copy-pasting this will create an attribute with an empty key, which should be rejected. Show a concrete placeholder or example instead.

Apply this diff:

 appwrite databases create-line-attribute \
     --database-id <DATABASE_ID> \
     --collection-id <COLLECTION_ID> \
-    --key '' \
+    --key <KEY> \
     --required false
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
appwrite databases create-line-attribute \
--database-id <DATABASE_ID> \
--collection-id <COLLECTION_ID> \
--key '' \
--required false
appwrite databases create-line-attribute \
--database-id <DATABASE_ID> \
--collection-id <COLLECTION_ID> \
--key <KEY> \
--required false
🤖 Prompt for AI Agents
In docs/examples/databases/create-line-attribute.md around lines 1 to 5, the
example uses --key '' which is misleading and may create an empty/invalid
attribute key; replace the empty key with a concrete placeholder or realistic
example (e.g. --key example_key or --key username) so users can copy-paste
safely and understand the expected format; update the example command to use
that placeholder and ensure any accompanying text clarifies it should be
replaced with a real attribute key.

5 changes: 5 additions & 0 deletions docs/examples/databases/create-point-attribute.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
appwrite databases create-point-attribute \
--database-id <DATABASE_ID> \
--collection-id <COLLECTION_ID> \
--key '' \
--required false
5 changes: 5 additions & 0 deletions docs/examples/databases/create-polygon-attribute.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
appwrite databases create-polygon-attribute \
--database-id <DATABASE_ID> \
--collection-id <COLLECTION_ID> \
--key '' \
--required false
5 changes: 5 additions & 0 deletions docs/examples/databases/update-line-attribute.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
appwrite databases update-line-attribute \
--database-id <DATABASE_ID> \
--collection-id <COLLECTION_ID> \
--key '' \
--required false
5 changes: 5 additions & 0 deletions docs/examples/databases/update-point-attribute.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
appwrite databases update-point-attribute \
--database-id <DATABASE_ID> \
--collection-id <COLLECTION_ID> \
--key '' \
--required false
5 changes: 5 additions & 0 deletions docs/examples/databases/update-polygon-attribute.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
appwrite databases update-polygon-attribute \
--database-id <DATABASE_ID> \
--collection-id <COLLECTION_ID> \
--key '' \
--required false
Comment on lines +1 to +5
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue

Fix placeholder: avoid empty --key ('') which yields an invalid command.

Use an explicit placeholder to prevent copy-paste failures.

 appwrite databases update-polygon-attribute \
     --database-id <DATABASE_ID> \
     --collection-id <COLLECTION_ID> \
-    --key '' \
+    --key <ATTRIBUTE_KEY> \
     --required false
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
appwrite databases update-polygon-attribute \
--database-id <DATABASE_ID> \
--collection-id <COLLECTION_ID> \
--key '' \
--required false
appwrite databases update-polygon-attribute \
--database-id <DATABASE_ID> \
--collection-id <COLLECTION_ID> \
--key <ATTRIBUTE_KEY> \
--required false
🤖 Prompt for AI Agents
In docs/examples/databases/update-polygon-attribute.md around lines 1 to 5, the
example uses an empty --key ('') placeholder which produces an invalid command;
replace the empty string with a clear explicit placeholder such as --key
<ATTRIBUTE_KEY> (or --key "ATTRIBUTE_KEY") so copy-pasters supply a real
attribute key and the command remains valid; ensure the placeholder name is
descriptive and quoted only if needed.

5 changes: 5 additions & 0 deletions docs/examples/tablesdb/create-line-column.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
appwrite tables-db create-line-column \
--database-id <DATABASE_ID> \
--table-id <TABLE_ID> \
--key '' \
--required false
Comment on lines +1 to +5
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue

Fix example: avoid empty key placeholder

Using --key '' yields an invalid empty key. Match the other placeholders.

 appwrite tables-db create-line-column \
     --database-id <DATABASE_ID> \
     --table-id <TABLE_ID> \
-    --key '' \
+    --key <KEY> \
     --required false

Consider adding an example --xdefault showing a valid JSON string if the API expects a JSON object.

📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
appwrite tables-db create-line-column \
--database-id <DATABASE_ID> \
--table-id <TABLE_ID> \
--key '' \
--required false
appwrite tables-db create-line-column \
--database-id <DATABASE_ID> \
--table-id <TABLE_ID> \
--key <KEY> \
--required false
🤖 Prompt for AI Agents
In docs/examples/tablesdb/create-line-column.md lines 1-5, the example uses an
empty key placeholder (--key '') which is invalid; replace it with a normal
placeholder (e.g. --key <KEY>) to match the other flags and show a realistic key
value, and add an optional example flag --xdefault with a valid JSON string
(e.g. --xdefault '{"foo":"bar"}') if the API expects a JSON object so users see
the correct format.

5 changes: 5 additions & 0 deletions docs/examples/tablesdb/create-point-column.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
appwrite tables-db create-point-column \
--database-id <DATABASE_ID> \
--table-id <TABLE_ID> \
--key '' \
--required false
5 changes: 5 additions & 0 deletions docs/examples/tablesdb/create-polygon-column.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
appwrite tables-db create-polygon-column \
--database-id <DATABASE_ID> \
--table-id <TABLE_ID> \
--key '' \
--required false
5 changes: 5 additions & 0 deletions docs/examples/tablesdb/update-line-column.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
appwrite tables-db update-line-column \
--database-id <DATABASE_ID> \
--table-id <TABLE_ID> \
--key '' \
--required false
5 changes: 5 additions & 0 deletions docs/examples/tablesdb/update-point-column.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
appwrite tables-db update-point-column \
--database-id <DATABASE_ID> \
--table-id <TABLE_ID> \
--key '' \
--required false
5 changes: 5 additions & 0 deletions docs/examples/tablesdb/update-polygon-column.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
appwrite tables-db update-polygon-column \
--database-id <DATABASE_ID> \
--table-id <TABLE_ID> \
--key '' \
--required false
4 changes: 2 additions & 2 deletions install.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@
# You can use "View source" of this page to see the full script.

# REPO
$GITHUB_x64_URL = "https://github.com/appwrite/sdk-for-cli/releases/download/9.0.2/appwrite-cli-win-x64.exe"
$GITHUB_arm64_URL = "https://github.com/appwrite/sdk-for-cli/releases/download/9.0.2/appwrite-cli-win-arm64.exe"
$GITHUB_x64_URL = "https://github.com/appwrite/sdk-for-cli/releases/download/9.1.0/appwrite-cli-win-x64.exe"
$GITHUB_arm64_URL = "https://github.com/appwrite/sdk-for-cli/releases/download/9.1.0/appwrite-cli-win-arm64.exe"

$APPWRITE_BINARY_NAME = "appwrite.exe"

Expand Down
2 changes: 1 addition & 1 deletion install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ printSuccess() {
downloadBinary() {
echo "[2/4] Downloading executable for $OS ($ARCH) ..."

GITHUB_LATEST_VERSION="9.0.2"
GITHUB_LATEST_VERSION="9.1.0"
GITHUB_FILE="appwrite-cli-${OS}-${ARCH}"
GITHUB_URL="https://github.com/$GITHUB_REPOSITORY_NAME/releases/download/$GITHUB_LATEST_VERSION/$GITHUB_FILE"

Expand Down
4 changes: 2 additions & 2 deletions lib/client.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,8 @@ class Client {
'x-sdk-name': 'Command Line',
'x-sdk-platform': 'console',
'x-sdk-language': 'cli',
'x-sdk-version': '9.0.2',
'user-agent' : `AppwriteCLI/9.0.2 (${os.type()} ${os.version()}; ${os.arch()})`,
'x-sdk-version': '9.1.0',
'user-agent' : `AppwriteCLI/9.1.0 (${os.type()} ${os.version()}; ${os.arch()})`,
'X-Appwrite-Response-Format' : '1.8.0',
};
}
Expand Down
Loading