Scripts
This is the list of scripts of Versator.
The project includes various scripts designed to enhance your developer experience. You can run any script using your terminal. Please note that some CLI scripts may require you to adjust the height of your terminal window to avoid UI anomalies. The Versator allows you to use the following:
- 💪 Native Scripts: These are commands configured in package.json and run by the package manager like pnpm, [bun ](https://bun .sh), yarn, or npm. You can run these "native" scripts using commands like
bun [dev|build]andbun db:[push|studio]. - ⚙️ Custom-Built Scripts: These scripts are written in TypeScript and Python by Reliverse and the community and are mostly located in the
addonsfolder. 🔥 Please be cautious when using transformation scripts, as they are all in their initial versions. Ensure you commit your changes to your version control provider (such as GitHub) before using any of them. They can be executed via the command line using[appts|addons|reli|lint|fix]:*or manually viabun path/to/fileorpy path/to/file(e.g.,py addons/scripts/reliverse/relimter/python/tasks/math-to-mathjs.py). - 🐍 Python Script Manager: Can be executed using
reli:managerorpy addons/scripts/reliverse/relimter/python/index.py. Before running it, please read the 🐍 Python section below to learn how to prepare your workspace to run this manager.
package.json
Below are some scripts configured in the scripts section of the package.json file (the following text may be outdated in some places, please let us know if you find any inaccuracies):
bun appts/bun appts:putout/bun appts:verbose/bun appts:nobuild: These commands perform a comprehensive codebase check. They sequentially runbun knipfor various codebase checks,bun formatto format code with Biome (or Prettier, coming soon), andbun lintfor linting with Biome and ESLint (bun lint:eslint). Linting may take some time, so please be patient. Thebun appts:putoutcommand also runsbun lint:putout. Usingbun appts:verbosedisplays detailed ESLint progress, useful if you suspect ESLint is stuck (it may be slow, not stuck). You can manually resolve issues by pressingCtrl+Smultiple times in VSCode until there are no issues in the "Problems" tab. Usually, issues are resolved by the second or third run. If some specific issues persist, it may mean they are not automatically fixed. Please try to fix them manually, contact us, or disable the rule. Many rules ineslint.config.jsare disabled by default; enable only what you need. You may also want to runbun reli:setupto choose the RulesDisabled preset if you want to disable all "error" and "warning" rules at once.bun apptsthen runsbun typecheckfor remaining TypeScript errors andbun run build, but you may trybun turbo:appts, which runsbun turbo:buildto speed up builds using Turborepo v2. Note thatbun turbo:apptsis a faster, interactive version ofapptsbut may not work well with the VSCode terminal. Alternatively, you can usebun appts:nobuild, which performs only checking, linting, formatting, and fixing, without building.bun fix:putout-unstable: Putout is a linter and formatter. While the formatter fixes issues reported by the linter, thefix:putout-unstablecommand also makes changes not flagged by the linter. Ensure you commit your code before running this command, as it might cause unexpected changes. After running it, review and adjust the changes in your codebase using VSCode Source Control (Cmd/Ctrl+Shift+G) or GitHub Desktop.bun db:[push|studio|generate|migrate]:pushconverts the TypeScript Drizzle schema to SQL and sends it to the DATABASE_URL;studioruns Drizzle Studio on https://local.drizzle.studio;migrateapplies migrations generated by thegeneratecommand (you may not need this command anymore), based on thedrizzle.config.tsfile.bun stripe:listen: Runs the Stripe webhook listener and helps set up Stripe environment variables. The Stripe CLI must be installed for this command to work.bun addons: This command allows you to headlessly run some of the scripts located in theaddonsfolder. Many scripts are still not added there, so please check theaddonsfolder and run them manually usingbun path/to/fileorpy path/to/file. This also includes the game @reliverse/academy. In the future, it will have many different interesting features. Currently, it is a quiz with a leaderboard and achievements where you can test your knowledge of Versator, JavaScript, TypeScript, React, and even ESLint.reli:manager: Learn more in the 🐍 Python section below. This is the alias for thepy addons/scripts/reliverse/relimter/python/index.pycommand.bun latest: Updates all project packages to their latest stable versions, including some specific packages to their latest versions on rc/beta/alpha/next/canary branches.bun reli:vscode [nothing|minimal|default|ultimate]: Enhances VSCode settings with presets by Reliverse. This script adjusts yoursettings.json,extensions.json, andlaunch.jsonfiles. It will prompt for confirmation before overriding current files. UseRQ20to learn more about.vscodepresets and font installation for theultimatepreset, or use thedefaultpreset (which doesn't contain custom fonts and themes). Choosedefault,minimal, ornothingif your PC or virtual machine is very slow.bun reli:help: Displays useful information about Versator and Reliverse.bun lint:compiler: Runs the React Compiler health check. Note that React Compiler is disabled by default; see the FAQ section for more details.bun tw:[v4|v3]: Switches between Tailwind CSS v3 and the alpha v4 version. Important: After using this command, adjust comments inpostcss.config.cjs. Also: When using Tailwind CSS v4, remove or comment outtailwindPluginfromeslint.config.jsas it doesn't support v4. Some additional changes in the codebase may be required.bun reli:prepare: Learn more about this script in the previous section (Cmd/Ctrl+F "It is recommended").
# bun reliverse.config.ts --details
ℹ ▲ Framework: Versator v1.2.6 ▲ Engine: Reliverse v0.4.0 ▲ Hotline: https://discord.gg/Pb8uKbwpsJ
ℹ Versator v1.2.6 Release Blog Post 👉 https://reliverse.org/versator/v126
ℹ Help Versator become even better! Please star the repo – https://github.com/blefnk/versator
ℹ For experienced users: run 'bun reli:prepare' to update all dependencies to the latest versions and check if the code requires any adjustments.
ℹ Meet quality standards: run 'bun appts' and 'bun fix:putout-unstable' to get linting, formatting, and more.
ℹ Unstable: try 'bun turbo:dev' and faster build with 'bun turbo:build': https://turbo.build/repo
ℹ The reactCompiler is enabled in next.config.js - it uses webpack now, so builds take longer.
ℹ Clerk: make sure to connect the domain in the Clerk dashboard so services like PageSpeed will work.
ℹ Please find Q21 in the FAQ of README.md. Copy the adapted bun scripts and replace the current ones in package.json - scripts for other package managers coming soon.Python
👋 Hello, dear friend! Nice to see you here! I (@blefnk Nazar Kornienko) have a dream of making the open-source world better and of higher quality. I aspire to leave my mark in history by ensuring people genuinely enjoy programming and create quality products. I'm particularly passionate about clean code. The book "Clean Code" by Robert Martin is a must-have!
That's why I've developed numerous tools in Versator. Over the past few months leading up to Versator 1.2.6, I've learned a lot. To avoid manually rewriting code, I've developed a unified script manager. The current version of the manager is still very unstable. You can visit the addons/scripts/reliverse/relimter/python/index.py file to learn more about how this script manager works.
If you want to use this Python Script Manager (refer to ⚙️ Script to read the introduction), then please ensure your workspace is properly prepared for it. Please note that most scripts are largely untested. Commit your code before running any script. Increase your VSCode terminal window size to avoid UI glitches. Need help? Visit my Discord. Follow the steps below to get started (scroll down to learn even more Python commands):
✅ After following the instructions above, you can safely run the script manager.
- Install Python and Ruff. Install the following VSCode extensions: Python and Ruff.
- Create a new
.venvfolder by pressingCmd/Ctrl+Shift+Pand running>Python: Create Environment...(VSCode will prompt you to choose the Python interpreter; choose the one installed in step 1). Then, chooserequirements.txtas the package dependencies file. - Please note, VSCode's terminal automatically activates the environment after each launch. You can verify this by hovering over a [pwsh|bash|cmd] button in VSCode's terminal and looking for something like "
Python: Activated environment for.\.venv\Scripts\python.exe". However, if you are using another IDE or an external terminal, you may need to activate the virtual environment manually: [Windows].venv/Scripts/activate; [macOS/Linux]source .venv/bin/activate. - Ensure all requirement are installed correctly, just run
pip install -r requirements.txt.
🐍 Everything ready? Nice! Congratulations! Try running the Python Script Manager now by executing: reli:manager or py addons/scripts/reliverse/relimter/python/index.py
Useful Python Commands
I'm still working on this section. The following description may currently be slightly incorrect.
# - Install the required dependencies:
pip install -r requirements.txt
# - Make sure you have `pip-tools` installed to use `pip-compile` and `pip-sync`:
pip install pip-tools
# - You can create/update a `requirements.txt` file:
pip freeze > requirements.txt
# - Sync the dependencies:
pip-sync requirements.txt
# - Remove a specific package (e.g., torch):
pip uninstall torch
pip freeze > requirements.txtPlease note: If you have UV installed and you've used a command like uv pip install InquirerPy and it shows an error like "The wheel is invalid", the easiest solution is to just use regular pip commands like pip install InquirerPy.