ittai/README.md

102 lines
3.1 KiB
Markdown

<p align="center">
<img src="./assets/png/dark/Background.png" alt="Ittai Logo made by Sylix#8103" width="2000">
</p>
<p align="center">
<i>
<strong>What the heck</strong>?! I only need to use <strong>one style</strong> for my plugin?<br>
<strong>Ittai</strong>?! I only need to use <strong>Ittai</strong> for my plugin?<br>
<i>Ittai is a plugin bundler for most Discord client mods, making your plugin cross-compatible with multiple client mods easy!</i>
</i>
</p>
<p align="center">
<a href="#features">Features</a> |
<a href="#installation">Installation</a> |
<a href="#how-to-build">How to Build</a>
</p>
<hr>
## Features
- Build even single-file BD plugins from multi-file projects.
- Write one codebase, run it anywhere.
- Hot rebuild your plugins.
- Use various flavors of JS to create your plugins.
- [x] [JSX and TSX support](https://reactjs.org/docs/introducing-jsx.html)
- [x] [TypeScript](https://www.typescriptlang.org/)
- [x] [ES6 Modules](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Guide/Modules)
- [x] [CoffeeScript](https://coffeescript.org/)
- I didn't forget about CSS!
- [x] Load your stylesheets easily.
- `import style from "./style.css";`
- [x] [SASS (SCSS)](https://sass-lang.com/)
- [x] [Stylus](https://stylus-lang.com/)
- [x] [LESS](http://lesscss.org/)
- Build to the most popular mods <sup><i>PRs adding more mod support accepted</i></sup>
- [x] [BetterDiscord](https://betterdiscord.app)
- [x] [Powercord](https://powercord.dev/) (v2)
- [x] [GooseMod](https://goosemod.com/)
## Installation
### Requirements
- [Git](https://git-scm.com/)
- [NodeJS](https://nodejs.org/)
- [pnpm](https://pnpm.js.org/) (optional)
### Installation Steps
#### From NPM
```bash
pnpm i -g @ittai/builder # this anywhere
pnpm i ittai # on your plugin's folder
```
#### From this repo <sup>**(Building Ittai for local development)**</sup>
```bash
git clone https://git.catvibers.me/Ittai/ittai
cd ittai
# linking the builder
cd builder
pnpm i
pnpm link --global
# linking the core
cd ..
cd core
pnpm i
pnpm link --global
```
Then, in your plugin's folder
```bash
pnpm link --global ittai
```
## How to Build
### Command Options
- `--plugin="path/to/your/plugin"`
- `--betterdiscord` (optional)
- Specify `="path/to/plugin/folder"` to copy the built file to the folder.
- Builds for BetterDiscord.
- `--powercordv2` (optional)
- Specify `="path/to/plugin/folder"` to copy the built files to the folder.
- Builds for Powercord v2.
- `--goosemod` (optional)
- Specify `="path/to/plugin/folder"` to copy the built files to the folder.
- Builds for GooseMod.
- `--watch` (optional)
- Will watch for changes in your plugin's unbuilt files and automatically run the command again for you.
### Build Command
This command will build your plugin for BetterDiscord, Powercord v2, and GooseMod, but will only copy it to BetterDiscord's plugins folder. It will also hot rebuild your plugin for you.
```bash
ittai --plugin="./test/plugin" --betterdiscord="/path/to/plugins/fgbd" --powercordv2="/path/to/plugins/fgbd" --goosemod-"/path/to/plugins/fgbd" --watch
```