Skip to content

Commit 7a29f2d

Browse files
committed
Update MDs
1 parent f7bd5fa commit 7a29f2d

File tree

4 files changed

+121
-107
lines changed

4 files changed

+121
-107
lines changed

CONTRIBUTING.md

Lines changed: 68 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,68 @@
1+
# Contributing to CommandKit
2+
3+
Firstly, thank you for considering contributing to CommandKit! Whether you're looking to fix bugs, add new features, or just ask questions, your input is valuable to us.
4+
5+
## Setup
6+
7+
### Prerequisites
8+
9+
1. Ensure you have `Node.js` and `pnpm` installed.
10+
- Node.js: [Download here](https://nodejs.org/)
11+
- pnpm: Install via `npm install -g pnpm` if you haven't.
12+
13+
### Fork & Clone
14+
15+
1. Fork the repository to your own GitHub account.
16+
2. Clone your fork to your local machine:
17+
18+
```bash
19+
git clone https://github.com/<YOUR_USERNAME>/commandkit.git
20+
```
21+
22+
### Installing Dependencies
23+
24+
Since we use `pnpm` workspaces, it's essential to use `pnpm` for installing dependencies.
25+
26+
```bash
27+
cd commandkit
28+
pnpm install # Make sure to run this from the root directory
29+
```
30+
31+
### Workflow
32+
33+
1. Create a new branch for your work:
34+
35+
```bash
36+
git checkout -b your-feature-or-bugfix
37+
```
38+
39+
2. Make your changes. Please make sure to use the [Prettier](https://marketplace.visualstudio.com/items?itemName=esbenp.prettier-vscode) extension for consistent formatting and comments wherever necessary.
40+
41+
3. Ensure that your changes don't break any existing functionality. You can test the functionality of your code depending on where you've made changes:
42+
43+
1. If you've made changes to the CommandKit package, you can use the "tests" folder in the "packages/commandkit" directory to test your own bot. Just make sure to create a new `.env` file with the template from the `.env.example` file provided. You can run the application using `pnpm test`.
44+
2. If you've made changes to the docs, you can run `pnpm dev` inside "apps/docs" to spin up a local development server.
45+
46+
4. Run `pnpm lint` from the root directory to ensure all lint scripts and formatting is valid.
47+
48+
5. Commit your changes:
49+
50+
```bash
51+
git commit -m "Describe your change here"
52+
```
53+
54+
6. Push your changes to your fork:
55+
56+
```bash
57+
git push origin your-feature-or-bugfix
58+
```
59+
60+
7. Open a pull request in the main project repository (master branch). Describe your changes and any relevant information.
61+
62+
## Submitting Issues
63+
64+
When submitting a new issue, please provide a detailed description of the problem, steps to reproduce it, and any relevant screenshots or error messages.
65+
66+
---
67+
68+
Thank you for making CommandKit better! We appreciate your effort and look forward to collaborating with you.

LICENSE

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
MIT License
2+
3+
Copyright (c) 2023 Under Ctrl
4+
5+
Permission is hereby granted, free of charge, to any person obtaining a copy
6+
of this software and associated documentation files (the "Software"), to deal
7+
in the Software without restriction, including without limitation the rights
8+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9+
copies of the Software, and to permit persons to whom the Software is
10+
furnished to do so, subject to the following conditions:
11+
12+
The above copyright notice and this permission notice shall be included in all
13+
copies or substantial portions of the Software.
14+
15+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21+
SOFTWARE.

README.md

Lines changed: 16 additions & 98 deletions
Original file line numberDiff line numberDiff line change
@@ -1,104 +1,22 @@
1-
<h1 align="center">
2-
<img src="https://raw.githubusercontent.com/underctrl-io/commandkit/master/apps/docs/public/ckit_logo.png" width="50%">
3-
<br>
4-
</h1>
1+
<div align="center">
2+
<img src="https://raw.githubusercontent.com/underctrl-io/commandkit/master/apps/docs/public/ckit_logo.png" width="60%" />
3+
<br />
4+
<a href="https://ctrl.lol/discord"><img src="https://img.shields.io/discord/1055188344188973066?color=5865F2&logo=discord&logoColor=white" alt="support server" /></a>
5+
<a href="https://www.npmjs.com/package/commandkit"><img src="https://img.shields.io/npm/v/commandkit?maxAge=3600" alt="npm version" /></a>
6+
<a href="https://www.npmjs.com/package/commandkit"><img src="https://img.shields.io/npm/dt/commandkit?maxAge=3600" alt="npm downloads" /></a>
7+
</div>
58

6-
# CommandKit
9+
## Support and Suggestions
710

8-
CommandKit is a library that makes it easy to handle commands and events in your Discord.js projects.
11+
If you are looking for support or want to provide suggestions, check out the [Discord](https://ctrl.lol/discord).
912

10-
**Supports Discord.js version 14**
13+
## Links
1114

12-
## Features
15+
- [Website](https://commandkit.js.org) ([source](https://github.com/underctrl-io/commandkit/tree/master/apps/docs))
16+
- [Support Server](https://ctrl.lol/discord)
17+
- [CommandKit source](https://github.com/underctrl-io/commandkit/tree/master/packages/commandkit)
18+
- [npm](https://www.npmjs.com/package/commandkit)
1319

14-
- Very beginner friendly 🚀
15-
- Support for slash and context menu commands ✅
16-
- Automatic command registration, edits, and deletion 🤖
17-
- Supports multiple development servers 🤝
18-
- Supports multiple users as bot developers 👥
19-
- Object oriented 💻
20+
## Contributing
2021

21-
## Documentation
22-
23-
You can find the full documentation [here](https://commandkit.js.org)
24-
25-
## Installation
26-
27-
[![npm](https://nodei.co/npm/commandkit.png)](https://nodei.co/npm/commandkit/)
28-
29-
To install CommandKit, simply run the following command:
30-
31-
For npm:
32-
33-
```bash
34-
npm install commandkit
35-
```
36-
37-
Yarn:
38-
39-
```bash
40-
yarn add commandkit
41-
```
42-
43-
pnpm:
44-
45-
```bash
46-
pnpm add commandkit
47-
```
48-
49-
### Install development version
50-
51-
To install the development version of CommandKit, run the following command:
52-
53-
```bash
54-
npm install commandkit@dev
55-
```
56-
57-
> ⚠️ The development version is likely to have bugs.
58-
59-
## Usage
60-
61-
This is a simple overview of how to set up this library with all the options. You can read more in the [full documentation](https://commandkit.js.org)
62-
63-
```js
64-
// index.js
65-
const { Client, GatewayIntentBits } = require('discord.js');
66-
const { CommandKit } = require('commandkit');
67-
const path = require('path');
68-
69-
const client = new Client({
70-
intents: [
71-
GatewayIntentBits.Guilds,
72-
GatewayIntentBits.GuildMessages,
73-
GatewayIntentBits.MessageContent,
74-
],
75-
});
76-
77-
new CommandKit({
78-
// Your discord.js client object
79-
client,
80-
81-
// Path to the commands folder
82-
commandsPath: path.join(__dirname, 'commands'),
83-
84-
// Path to the events folder
85-
eventsPath: path.join(__dirname, 'events'),
86-
87-
// Path to the validations folder (only valid if "commandsPath" was provided)
88-
validationsPath: path.join(__dirname, 'validations'),
89-
90-
// Array of development server IDs (used to register and run devOnly commands)
91-
devGuildIds: ['DEV_SERVER_ID_1', 'DEV_SERVER_ID_2'],
92-
93-
// Array of developer user IDs (used for devOnly commands)
94-
devUserIds: ['DEV_USER_ID_1', 'DEV_USER_ID_2'],
95-
96-
// Array of developer role IDs (used for devOnly commands)
97-
devRoleIds: ['DEV_ROLE_ID_1', 'DEV_ROLE_ID_2'],
98-
99-
// A property that disables CommandKit's built-in validations
100-
skipBuiltInValidations: true,
101-
});
102-
103-
client.login('YOUR_TOKEN_HERE');
104-
```
22+
Check out the [contributors guide](https://github.com/underctrl-io/commandkit/blob/master/CONTRIBUTING.md)

packages/commandkit/README.md

Lines changed: 16 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,16 @@
1-
<h1 align="center">
2-
<img src="https://raw.githubusercontent.com/underctrl-io/commandkit/master/apps/docs/public/ckit_logo.png" width="50%">
3-
<br>
4-
</h1>
1+
<div align="center">
2+
<img src="https://raw.githubusercontent.com/underctrl-io/commandkit/master/apps/docs/public/ckit_logo.png" width="60%" />
3+
<br />
4+
<a href="https://ctrl.lol/discord"><img src="https://img.shields.io/discord/1055188344188973066?color=5865F2&logo=discord&logoColor=white" alt="support server" /></a>
5+
<a href="https://www.npmjs.com/package/commandkit"><img src="https://img.shields.io/npm/v/commandkit?maxAge=3600" alt="npm version" /></a>
6+
<a href="https://www.npmjs.com/package/commandkit"><img src="https://img.shields.io/npm/dt/commandkit?maxAge=3600" alt="npm downloads" /></a>
7+
</div>
58

69
# CommandKit
710

811
CommandKit is a library that makes it easy to handle commands and events in your Discord.js projects.
912

10-
**Supports Discord.js version 14**
13+
> **Supports Discord.js version 14**
1114
1215
## Features
1316

@@ -20,7 +23,7 @@ CommandKit is a library that makes it easy to handle commands and events in your
2023

2124
## Documentation
2225

23-
You can find the full documentation [here](https://commandkit.js.org)
26+
You can find the full documentation [here](https://commandkit.js.org).
2427

2528
## Installation
2629

@@ -88,17 +91,21 @@ new CommandKit({
8891
validationsPath: path.join(__dirname, 'validations'),
8992

9093
// Array of development server IDs (used to register and run devOnly commands)
91-
devGuildIds: ['DEV_SERVER_ID_1', 'DEV_SERVER_ID_2'],
94+
devGuildIds: ['1234567890', '0987654321'],
9295

9396
// Array of developer user IDs (used for devOnly commands)
94-
devUserIds: ['DEV_USER_ID_1', 'DEV_USER_ID_2'],
97+
devUserIds: ['1234567890', '0987654321'],
9598

9699
// Array of developer role IDs (used for devOnly commands)
97-
devRoleIds: ['DEV_ROLE_ID_1', 'DEV_ROLE_ID_2'],
100+
devRoleIds: ['1234567890', '0987654321'],
98101

99102
// A property that disables CommandKit's built-in validations
100103
skipBuiltInValidations: true,
101104
});
102105

103106
client.login('YOUR_TOKEN_HERE');
104107
```
108+
109+
## Support and Suggestions
110+
111+
If you are looking for support or want to provide suggestions, check out the [Discord](https://ctrl.lol/discord).

0 commit comments

Comments
 (0)