Changed formatting of scripts in READMEs

This commit is contained in:
Prozilla 2024-07-07 16:23:13 +02:00
parent 35ae432115
commit 1525995dc9
No known key found for this signature in database
GPG key ID: 5858DFE71CAF31EE
3 changed files with 29 additions and 27 deletions

View file

@ -56,38 +56,40 @@ ProzillaOS uses the package manager [pnpm](https://pnpm.io/) to run scripts.
| Script | Description |
| --- | --- |
| `pnpm run start` | Run [`pnpm run site:start`](#package-prozilla-os-demo). VSCode is configured to run this script whenever the project is opened.
| `pnpm run build` | Build every package in sequential order.
| `pnpm run deploy` | Clear the `dist` directory, build and stage each package that comprises the website, then deploy to GitHub pages. This should then trigger a GitHub Action that deploys the build to production.
| <pre>pnpm&nbsp;run&nbsp;start</pre> | Run [`pnpm run site:start`](#package-prozilla-os-demo). VSCode is configured to run this script whenever the project is opened.
| <pre>pnpm&nbsp;run&nbsp;build</pre> | Build every package in sequential order.
| <pre>pnpm&nbsp;run&nbsp;deploy</pre> | Clear the `dist` directory, build and stage each package that comprises the website, then deploy to GitHub pages. This should then trigger a GitHub Action that deploys the build to production.
### Libraries
| Script | Description |
| --- | --- |
| `pnpm --filter <package_selector> build` | Build a sepecific subset of packages or a single package and output to respective `dist` directory/directories. For more information about selecting specific packages, read [pnpm's documentation on filtering](https://pnpm.io/filtering).
| `pnpm run packages:build` | Build all packages using Vite in sequential order and output to respective `dist` directories.
| `pnpm run packages:update` | Create a new changeset for packages and update their version accordingly.
| `pnpm run packages:release` | Publish the latest versions of each package to the npm registry.
| <pre>pnpm&nbsp;run&nbsp;packages:build</pre> | Build all packages using Vite in sequential order and output to respective `dist` directories.
| <pre>pnpm&nbsp;run&nbsp;packages:update</pre> | Create a new changeset for packages and update their version accordingly.
| <pre>pnpm&nbsp;run&nbsp;packages:release</pre> | Publish the latest versions of each package to the npm registry.
> [!TIP]
> Use `pnpm --filter <package_selector> build` to build a sepecific subset of packages or a single package and output to respective `dist` directory/directories. For more information about selecting/filtering specific packages, read [pnpm's documentation on filtering](https://pnpm.io/filtering).
### Package: `prozilla-os-demo`
| Script | Linked package script |
| --- | --- |
| `pnpm run site:start` | [`pnpm run start`](./packages/demo/README.md#scripts)
| `pnpm run site:build` | [`pnpm run build`](./packages/demo/README.md#scripts)
| `pnpm run site:preview` | [`pnpm run preview`](./packages/demo/README.md#scripts)
| `pnpm run site:stage` | [`pnpm run stage`](./packages/demo/README.md#scripts)
| `pnpm run site:deploy` | [`pnpm run deploy`](./packages/demo/README.md#scripts)
| `pnpm run site:fetch` | [`pnpm run fetch`](./packages/demo/README.md#scripts)
| <pre>pnpm&nbsp;run&nbsp;site:start</pre> | [`pnpm run start`](./packages/demo/README.md#scripts)
| <pre>pnpm&nbsp;run&nbsp;site:build</pre> | [`pnpm run build`](./packages/demo/README.md#scripts)
| <pre>pnpm&nbsp;run&nbsp;site:preview</pre> | [`pnpm run preview`](./packages/demo/README.md#scripts)
| <pre>pnpm&nbsp;run&nbsp;site:stage</pre> | [`pnpm run stage`](./packages/demo/README.md#scripts)
| <pre>pnpm&nbsp;run&nbsp;site:deploy</pre> | [`pnpm run deploy`](./packages/demo/README.md#scripts)
| <pre>pnpm&nbsp;run&nbsp;site:fetch</pre> | [`pnpm run fetch`](./packages/demo/README.md#scripts)
### Package: `prozilla-os-docs`
| Script | Linked package script |
| --- | --- |
| `pnpm run docs:start` | [`pnpm run start`](./packages/docs/README.md#scripts)
| `pnpm run docs:build` | [`pnpm run build`](./packages/docs/README.md#scripts)
| `pnpm run docs:preview` | [`pnpm run preview`](./packages/docs/README.md#scripts)
| `pnpm run docs:stage` | [`pnpm run stage`](./packages/docs/README.md#scripts)
| <pre>pnpm&nbsp;run&nbsp;docs:start</pre> | [`pnpm run start`](./packages/docs/README.md#scripts)
| <pre>pnpm&nbsp;run&nbsp;docs:build</pre> | [`pnpm run build`](./packages/docs/README.md#scripts)
| <pre>pnpm&nbsp;run&nbsp;docs:preview</pre> | [`pnpm run preview`](./packages/docs/README.md#scripts)
| <pre>pnpm&nbsp;run&nbsp;docs:stage</pre> | [`pnpm run stage`](./packages/docs/README.md#scripts)
## Links

View file

@ -21,12 +21,12 @@
| Script | Description |
| --- | --- |
| `pnpm run start` | Start Vite dev server at [localhost:3000](http://localhost:3000/). Changes to module will dynamically be hot-reloaded, so normally there is no need for hard-refreshes. VSCode is configured to run this script whenever the project is opened.
| `pnpm run build` | Compile project using TypeScript and bundle all files into the `dist` directory, or the directory specified in config file. This directory can be uploaded to a web server.
| `pnpm run preview` | Start web server with preview of build at [localhost:8080](http://localhost:8080/). Can be useful for validating build before deploying.
| `pnpm run stage` | Execute [stage.ts](./scripts/stage.ts), which stages the build and prepares it for deployment. Script will generate a sitemap, robots.txt and all other necessary files.
| `pnpm run deploy` | Run `pnpm run build && pnpm run stage`, then execute [deploy.ts](../scripts/deploy.ts), which uploads the staged build to GitHub Pages on branch called `gh-pages`. This should then trigger a GitHub Action that deploys the build to production.
| `pnpm run fetch` | Fetch the repository tree using GitHub's API and store it as a JSON file that will be used to populate the virtual drive. More information can be found on the [virtual drive](./features/virtual-drive/README.md) page.
| <pre>pnpm&nbsp;run&nbsp;start</pre> | Start Vite dev server at [localhost:3000](http://localhost:3000/). Changes to module will dynamically be hot-reloaded, so normally there is no need for hard-refreshes. VSCode is configured to run this script whenever the project is opened.
| <pre>pnpm&nbsp;run&nbsp;build</pre> | Compile project using TypeScript and bundle all files into the `dist` directory, or the directory specified in config file. This directory can be uploaded to a web server.
| <pre>pnpm&nbsp;run&nbsp;preview</pre> | Start web server with preview of build at [localhost:8080](http://localhost:8080/). Can be useful for validating build before deploying.
| <pre>pnpm&nbsp;run&nbsp;stage</pre> | Execute [stage.ts](./scripts/stage.ts), which stages the build and prepares it for deployment. Script will generate a sitemap, robots.txt and all other necessary files.
| <pre>pnpm&nbsp;run&nbsp;deploy</pre> | Run `pnpm run build && pnpm run stage`, then execute [deploy.ts](../scripts/deploy.ts), which uploads the staged build to GitHub Pages on branch called `gh-pages`. This should then trigger a GitHub Action that deploys the build to production.
| <pre>pnpm&nbsp;run&nbsp;fetch</pre> | Fetch the repository tree using GitHub's API and store it as a JSON file that will be used to populate the virtual drive. More information can be found on the [virtual drive](./features/virtual-drive/README.md) page.
## Links

View file

@ -21,10 +21,10 @@
| Script | Description |
| --- | --- |
| `pnpm run start` | Start VitePress dev server at [localhost:3000](http://localhost:3000/). Changes to module will dynamically be hot-reloaded, so normally there is no need for hard-refreshes.
| `pnpm run build` | Compile project using VitePress and output to the `dist` directory.
| `pnpm run preview` | Start web server with preview of build at [localhost:8080](http://localhost:8080/). Can be useful for validating build before deploying.
| `pnpm run stage` | Execute [stage.ts](./scripts/stage.ts), which copies the `./dist` directory of this package into the `/dist/docs` directory at the root, within the build of the demo site.
| <pre>pnpm&nbsp;run&nbsp;start</pre> | Start VitePress dev server at [localhost:3000](http://localhost:3000/). Changes to module will dynamically be hot-reloaded, so normally there is no need for hard-refreshes.
| <pre>pnpm&nbsp;run&nbsp;build</pre> | Compile project using VitePress and output to the `dist` directory.
| <pre>pnpm&nbsp;run&nbsp;preview</pre> | Start web server with preview of build at [localhost:8080](http://localhost:8080/). Can be useful for validating build before deploying.
| <pre>pnpm&nbsp;run&nbsp;stage</pre> | Execute [stage.ts](./scripts/stage.ts), which copies the `./dist` directory of this package into the `/dist/docs` directory at the root, within the build of the demo site.
## Links