Skip to content

Commit 22acc46

Browse files
committed
chore: docs cleanup, styling match the rest of the website, fixed readme files
1 parent 1eb12e1 commit 22acc46

File tree

23 files changed

+326
-553
lines changed

23 files changed

+326
-553
lines changed

.changeset/curvy-doors-jam.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,5 +5,7 @@
55

66
chore: added remote cache with turborepo to the workflows
77
chore: setting up unit-testing structure
8+
chore: unified docs styling to match the rest of the websites... (still needs some work on accessibility)
9+
chore: updated docs, added discord link, cleaned up wrong naming conventions
810
fix: fixing an issue where the json repo generation resulted in duplicate 'api group folders'
911
refactor: cleaned up a remainder console.log, changed imports to use the barrel exports from the cli/utils

README.md

Lines changed: 16 additions & 52 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
+==================================================================================================+
1414
```
1515

16-
[📚 **View Full CLI Documentation**](https://calycode.com/cli/docs)
16+
[📚 **View CLI Documentation**](https://calycode.com/cli/docs)
1717

1818
# xano tools
1919

@@ -41,49 +41,14 @@ xano
4141
```
4242

4343
> _(Optional)_ If you want the CLI globally available during development:
44-
> ```
45-
> pnpm link
46-
> ```
47-
> **Note:** If you use `pnpm link`, remember to `pnpm unlink --global` when done to avoid version confusion.
48-
49-
! See the [documentation](/docs/README.md) for available commands and arguments.
50-
51-
## 🤖 Using in GitHub Actions
52-
53-
You can use this CLI as a GitHub Action to automate your Xano workflows.
54-
55-
Here is an example job that checks out your repository and uses the local composite action (`./dist/actions/master-action.yml`), which in turn securely downloads and runs the Caly-Xano CLI as npm package via the npx command.
56-
57-
```yaml
58-
jobs:
59-
sync:
60-
runs-on: ubuntu-latest
61-
62-
steps:
63-
- uses: actions/checkout@v4
64-
65-
# 1. Setup Node.js and authenticate to the npm registry
66-
- uses: actions/setup-node@v4
67-
with:
68-
node-version: '20'
69-
registry-url: 'https://registry.npmjs.org'
70-
71-
# 2. Use the Xano CLI Action from your repository
72-
# This composite action handles setup and (multiple or single) command execution by calling the published npm package.
73-
- name: Run Caly-Xano Commands
74-
uses: ./dist/actions/master-action.yml
75-
with:
76-
# Xano Instance name, used to identify the created configuration during command execution
77-
instance-name: 'production'
78-
instance-url: ${{ secrets.XANO_URL }}
79-
# Xano Metadata API token. Make sure to set it up as a secret
80-
api-token: ${{ secrets.XANO_API_TOKEN }}
81-
version: 'latest' # or a specific version like '0.1.1'
82-
# You can specify multiple commands in new lines and the action will execute them in order.
83-
# See the [documentation](/docs/README.md) for command docs.
84-
run: |
85-
generate-oas --all
86-
```
44+
>
45+
> ```
46+
> pnpm link
47+
> ```
48+
>
49+
> **Note:** If you use `pnpm link`, remember to `pnpm unlink --global` when done to avoid version confusion.
50+
51+
! See the [documentation](https://calycode.com/cli/docs) for available commands and arguments.
8752
8853
---
8954
@@ -109,10 +74,10 @@ I have been astonished by the shadcn/ui CLI and the core principles of code dist
10974
xano registry-add --components <coma separated component names> --registry <registry url>
11075
```
11176
112-
> **Notes:**
77+
> [!NOTE] > **Notes:**
11378
> Currently there is no way of automatically building the registry from a collection of `xanoscript` files, so this is why
11479
> it is important to always keep the registry/definitions/index.json and the individual definition files in sync.
115-
> Currently there is theoretic support for registry:function and registry:table components, registry:query but registry:snippet is planned.
80+
> Currently there is theoretic support for registry:function and registry:table components, registry:query but registry:snippet is planned to allow installing multiple items at once in predefined order.
11681
> With the registry:snippet I aim to have a shot at fixing Xano's Snippets and make it searchable and reusable by also LLMs.
11782
11883
</details>
@@ -129,16 +94,15 @@ I have been astonished by the shadcn/ui CLI and the core principles of code dist
12994
## ✔️ What Works Now?
13095
13196
- [x] Allow multi-user multi workspace setup.
132-
- [x] Add context-switching to the configuration options.
133-
- [x] Generate improved **OpenAPI sepcification + Scalar** Reference html (hostable anywhere and viewable locally).
134-
- [x] **Generate code** from the backend API groups, powered by openapi tools generator CLI.
135-
- [x] **Processing Xano** queries, functions, and tables **into a browsable repo** structure
97+
- [x] Generate improved **OpenAPI sepcification + Scalar (as UI)** Reference html (hostable anywhere and viewable locally).
98+
- [x] **Generate code** from the backend API groups, powered by openapi tools generator CLI (orval with tanstack query support is coming).
99+
- [x] **Processing Xano** queries, functions, and tables **into a browsable repo** structure (Xano json, not yet `xanoscript`)
136100
- [x] **Export and restore backups** via Metadata API
101+
- [x] Exporting all available `xanoscript` from your instance via metadata API _\*(important note: not all pieces of logic can be exported via metadata API, this especially is fragile on older and bigger instances)_.
137102
- [x] **Scaffolding a registry** of reusable Xano components
138-
- [x] Exporting all available `xanoscript` from your instance via metadata API _*(important note: not all pieces of logic can be exported via metadata API, this especially is fragile on older and bigger instances)_.
139103
- [x] Adding components to Xano from a registry (only functions, tables, queries for now)
140104
- [x] Automated test runner with assertion configuration
141105
142106
---
143107
144-
**Contributions, feedback, and ideas are welcome!** Open an issue, or reach out to me on [State Change](https://statechange.ai/) or [Snappy Community](https://www.skool.com/@mihaly-toth-2040?g=snappy).
108+
**Contributions, feedback, and ideas are welcome!** Open an issue, or reach out to us on [our Discord](https://mee6.xyz/i/8a9p4ORFtm), on [State Change](https://statechange.ai/) or [Snappy Community](https://www.skool.com/@mihaly-toth-2040?g=snappy).

docs/README.md

Lines changed: 20 additions & 56 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ Supercharge your Xano workflow: automate backups, docs, testing, and version con
1717
+==================================================================================================+
1818
```
1919

20-
[📚 **View Full CLI Documentation**](https://calycode.com/cli/docs)
20+
[📚 **View CLI Documentation**](https://calycode.com/cli/docs)
2121

2222
# xano tools
2323

@@ -29,7 +29,7 @@ Supercharge your Xano workflow: automate backups, docs, testing, and version con
2929

3030
---
3131

32-
## 🚀 Quick Start
32+
## 🚀 [Dev] Quick Start
3333

3434
```
3535
# 1. Clone the repo
@@ -38,62 +38,27 @@ Supercharge your Xano workflow: automate backups, docs, testing, and version con
3838
pnpm install
3939
4040
# 3. Build the CLI
41-
pnpm build:packages
41+
pnpm build
4242
4343
# 4. Run any command
4444
xano
4545
```
4646

4747
> _(Optional)_ If you want the CLI globally available during development:
48-
> ```
49-
> pnpm link
50-
> ```
51-
> **Note:** If you use `pnpm link`, remember to `pnpm unlink --global` when done to avoid version confusion.
52-
53-
! See the [documentation](/docs/README.md) for available commands and arguments.
54-
55-
## 🤖 Using in GitHub Actions
56-
57-
You can use this CLI as a GitHub Action to automate your Xano workflows.
58-
59-
Here is an example job that checks out your repository and uses the local composite action (`./dist/actions/master-action.yml`), which in turn securely downloads and runs the Caly-Xano CLI as npm package via the npx command.
60-
61-
```yaml
62-
jobs:
63-
sync:
64-
runs-on: ubuntu-latest
65-
66-
steps:
67-
- uses: actions/checkout@v4
68-
69-
# 1. Setup Node.js and authenticate to the npm registry
70-
- uses: actions/setup-node@v4
71-
with:
72-
node-version: '20'
73-
registry-url: 'https://registry.npmjs.org'
74-
75-
# 2. Use the Xano CLI Action from your repository
76-
# This composite action handles setup and (multiple or single) command execution by calling the published npm package.
77-
- name: Run Caly-Xano Commands
78-
uses: ./dist/actions/master-action.yml
79-
with:
80-
# Xano Instance name, used to identify the created configuration during command execution
81-
instance-name: 'production'
82-
instance-url: ${{ secrets.XANO_URL }}
83-
# Xano Metadata API token. Make sure to set it up as a secret
84-
api-token: ${{ secrets.XANO_API_TOKEN }}
85-
version: 'latest' # or a specific version like '0.1.1'
86-
# You can specify multiple commands in new lines and the action will execute them in order.
87-
# See the [documentation](/docs/README.md) for command docs.
88-
run: |
89-
generate-oas --all
90-
```
48+
>
49+
> ```
50+
> pnpm link
51+
> ```
52+
>
53+
> **Note:** If you use `pnpm link`, remember to `pnpm unlink --global` when done to avoid version confusion.
54+
55+
! See the [documentation](https://calycode.com/cli/docs) for available commands and arguments.
9156
9257
---
9358
9459
### Xano Registry **(WIP)**
9560
96-
I have been astonished by the shadcn/ui CLI and the core principles of code distribution implemented in that tool. While that is primarily for frontend developers, their attempt to generalise their registry pointed me into the direction where I have started rebuilding a registry system for Xano powered by `xanoscript`. The reason for this is to overcome the bugs of Xano Snippets, avoid dependency of external providers of Xano Actions and in general to allow any team to build their own registries. These registries should also server as guidance for LLMs to eventually start generating more and more reliable `xanoscript`.
61+
I have been astonished by the shadcn/ui CLI and the core principles of code distribution implemented in that tool. While that is primarily for frontend developers, their attempt to generalise their registry pointed me into the direction where I have started rebuilding a registry system for Xano powered by `xanoscript`. The reason for this is to overcome the bugs of Xano Snippets, avoid dependency of external providers of Xano Actions and in general to allow any team to build their own registries with ease. These registries should also serve as guidance for LLMs to eventually start generating more and more reliable `xanoscript`.
9762
9863
<details>
9964
<summary>How to use the registry feature?</summary>
@@ -113,10 +78,10 @@ I have been astonished by the shadcn/ui CLI and the core principles of code dist
11378
xano registry-add --components <coma separated component names> --registry <registry url>
11479
```
11580
116-
> **Notes:**
117-
> Currently there is no way of automatically build out the registry from a collection of `xanoscript` files, so this is why
81+
> [!NOTE] > **Notes:**
82+
> Currently there is no way of automatically building the registry from a collection of `xanoscript` files, so this is why
11883
> it is important to always keep the registry/definitions/index.json and the individual definition files in sync.
119-
> Currently there is theoretic support for registry:function and registry:table components, registry:query but registry:snippet is planned.
84+
> Currently there is theoretic support for registry:function and registry:table components, registry:query but registry:snippet is planned to allow installing multiple items at once in predefined order.
12085
> With the registry:snippet I aim to have a shot at fixing Xano's Snippets and make it searchable and reusable by also LLMs.
12186
12287
</details>
@@ -133,19 +98,18 @@ I have been astonished by the shadcn/ui CLI and the core principles of code dist
13398
## ✔️ What Works Now?
13499
135100
- [x] Allow multi-user multi workspace setup.
136-
- [x] Add context-switching to the configuration options.
137-
- [x] Generate improved **OpenAPI sepcification + Scalar** Reference html (hostable anywhere and viewable locally).
138-
- [x] **Generate code** from the backend API groups, powered by openapi tools generator CLI.
139-
- [x] **Processing Xano** queries, functions, and tables **into a browsable repo** structure
101+
- [x] Generate improved **OpenAPI sepcification + Scalar (as UI)** Reference html (hostable anywhere and viewable locally).
102+
- [x] **Generate code** from the backend API groups, powered by openapi tools generator CLI (orval with tanstack query support is coming).
103+
- [x] **Processing Xano** queries, functions, and tables **into a browsable repo** structure (Xano json, not yet `xanoscript`)
140104
- [x] **Export and restore backups** via Metadata API
105+
- [x] Exporting all available `xanoscript` from your instance via metadata API _\*(important note: not all pieces of logic can be exported via metadata API, this especially is fragile on older and bigger instances)_.
141106
- [x] **Scaffolding a registry** of reusable Xano components
142-
- [x] Exporting all available `xanoscript` from your instance via metadata API _*(important note: not all pieces of logic can be exported via metadata API, this especially is fragile on older and bigger instances)_.
143107
- [x] Adding components to Xano from a registry (only functions, tables, queries for now)
144108
- [x] Automated test runner with assertion configuration
145109
146110
---
147111
148-
**Contributions, feedback, and ideas are welcome!** Open an issue, or reach out to me on [State Change](https://statechange.ai/) or [Snappy Community](https://www.skool.com/@mihaly-toth-2040?g=snappy).
112+
**Contributions, feedback, and ideas are welcome!** Open an issue, or reach out to us on [our Discord](https://mee6.xyz/i/8a9p4ORFtm), on [State Change](https://statechange.ai/) or [Snappy Community](https://www.skool.com/@mihaly-toth-2040?g=snappy).
149113
150114
151115
Need further help? Visit [GitHub](https://github.com/calycode/xano-tools) or reach out to Mihály Tóth on [State Change](https://statechange.ai/) or [Snappy Community](https://www.skool.com/@mihaly-toth-2040?g=snappy)

docs/_media/logo.png

-111 KB
Loading

docs/_sidebar.md

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
- Core command
1+
- Core command
22

33
- [xano - the core command](xano.md)
44

@@ -18,11 +18,14 @@
1818
- [`run-test`](commands/run-test.md)
1919
- [`current-context`](commands/current-context.md)
2020

21-
- Changelog
21+
- Changelog
2222

23-
- [CLI](https://github.com/calycode/xano-tools/blob/main/packages/cli/CHANGELOG.md)
24-
- [CORE](https://github.com/calycode/xano-tools/blob/main/packages/core/CHANGELOG.md)
23+
- [CLI](https://github.com/calycode/xano-tools/blob/main/packages/cli/CHANGELOG.md)
24+
- [CORE](https://github.com/calycode/xano-tools/blob/main/packages/core/CHANGELOG.md)
2525

26+
- Community
27+
28+
- [calycode on Discord](https://mee6.xyz/i/8a9p4ORFtm)
2629

2730
<small>For devs with 💖 by devs at [calycode](https://calycode.com).</small>
2831
<small>Documentation powered by [Docsify.js](https://docsifyjs.org)</small>

docs/commands/export-backup.md

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -24,9 +24,12 @@ Usage: xano export-backup [options]
2424
Backup Xano Workspace via Metadata API
2525
2626
Options:
27-
--instance <instance> The instance name. This is used to fetch the instance configuration. The value provided at the setup command.
28-
--workspace <workspace> The workspace name. This is used to fetch the workspace configuration. Same as on Xano interface.
29-
--branch <branch> The branch name. This is used to select the branch configuration. Same as on Xano Interface.
27+
--instance <instance> The instance name. This is used to fetch the instance configuration. The value
28+
provided at the setup command.
29+
--workspace <workspace> The workspace name. This is used to fetch the workspace configuration. Same as on
30+
Xano interface.
31+
--branch <branch> The branch name. This is used to select the branch configuration. Same as on Xano
32+
Interface.
3033
--print-output-dir Expose usable output path for further reuse.
3134
-h, --help display help for command
3235
```

docs/commands/generate-code.md

Lines changed: 14 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -31,17 +31,24 @@ $ xano generate-code [options]
3131
$ xano generate-code --help
3232
Usage: xano generate-code [options]
3333
34-
Create a library based on the OpenAPI specification. If the openapi specification has not yet been generated, this will generate that as well as the first step.
34+
Create a library based on the OpenAPI specification. If the openapi specification has not yet been
35+
generated, this will generate that as well as the first step.
3536
3637
Options:
37-
--instance <instance> The instance name. This is used to fetch the instance configuration. The value provided at the setup command.
38-
--workspace <workspace> The workspace name. This is used to fetch the workspace configuration. Same as on Xano interface.
39-
--branch <branch> The branch name. This is used to select the branch configuration. Same as on Xano Interface.
38+
--instance <instance> The instance name. This is used to fetch the instance configuration. The value
39+
provided at the setup command.
40+
--workspace <workspace> The workspace name. This is used to fetch the workspace configuration. Same as on
41+
Xano interface.
42+
--branch <branch> The branch name. This is used to select the branch configuration. Same as on Xano
43+
Interface.
4044
--group <name> API group name. Same as on Xano Interface.
4145
--all Regenerate for all API groups in the workspace / branch of the current context.
4246
--print-output-dir Expose usable output path for further reuse.
43-
--generator <generator> Generator to use, see all options at: https://openapi-generator.tech/docs/generators
44-
--args <args> Additional arguments to pass to the generator. See https://openapi-generator.tech/docs/usage#generate
45-
--debug Specify this flag in order to allow logging. Logs will appear in output/_logs. Default: false
47+
--generator <generator> Generator to use, see all options at:
48+
https://openapi-generator.tech/docs/generators
49+
--args <args> Additional arguments to pass to the generator. See
50+
https://openapi-generator.tech/docs/usage#generate
51+
--debug Specify this flag in order to allow logging. Logs will appear in output/_logs.
52+
Default: false
4653
-h, --help display help for command
4754
```

docs/commands/generate-oas.md

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -28,9 +28,12 @@ Usage: xano generate-oas [options]
2828
Update and generate OpenAPI spec(s) for the current context.
2929
3030
Options:
31-
--instance <instance> The instance name. This is used to fetch the instance configuration. The value provided at the setup command.
32-
--workspace <workspace> The workspace name. This is used to fetch the workspace configuration. Same as on Xano interface.
33-
--branch <branch> The branch name. This is used to select the branch configuration. Same as on Xano Interface.
31+
--instance <instance> The instance name. This is used to fetch the instance configuration. The value
32+
provided at the setup command.
33+
--workspace <workspace> The workspace name. This is used to fetch the workspace configuration. Same as on
34+
Xano interface.
35+
--branch <branch> The branch name. This is used to select the branch configuration. Same as on Xano
36+
Interface.
3437
--group <name> API group name. Same as on Xano Interface.
3538
--all Regenerate for all API groups in the workspace / branch of the current context.
3639
--print-output-dir Expose usable output path for further reuse.

0 commit comments

Comments
 (0)