-
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
12 changed files
with
422 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
# Folders | ||
/.cache | ||
/.git | ||
/dist | ||
/node_modules | ||
.eslintcache | ||
yarn.lock |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,94 @@ | ||
{ | ||
"root": true, | ||
"parser": "@typescript-eslint/parser", | ||
"parserOptions": { | ||
"project": "./tsconfig.json" | ||
}, | ||
"plugins": ["@typescript-eslint", "import", "unicorn"], | ||
"extends": [ | ||
"eslint:recommended", | ||
"plugin:@typescript-eslint/recommended", | ||
"plugin:@typescript-eslint/recommended-requiring-type-checking", | ||
"plugin:import/recommended", | ||
"plugin:import/typescript" | ||
], | ||
"rules": { | ||
"@typescript-eslint/explicit-function-return-type": [ | ||
"error", | ||
{ | ||
"allowExpressions": true | ||
} | ||
], | ||
"@typescript-eslint/no-explicit-any": "off", | ||
"@typescript-eslint/no-floating-promises": "off", | ||
"@typescript-eslint/no-inferrable-types": [ | ||
"error", | ||
{ | ||
"ignoreParameters": true | ||
} | ||
], | ||
"@typescript-eslint/no-misused-promises": "off", | ||
"@typescript-eslint/no-unsafe-argument": "off", | ||
"@typescript-eslint/no-unsafe-assignment": "off", | ||
"@typescript-eslint/no-unsafe-call": "off", | ||
"@typescript-eslint/no-unsafe-member-access": "off", | ||
"@typescript-eslint/no-unsafe-return": "off", | ||
"@typescript-eslint/no-unused-vars": [ | ||
"error", | ||
{ | ||
"argsIgnorePattern": "^_", | ||
"varsIgnorePattern": "^_" | ||
} | ||
], | ||
"@typescript-eslint/no-var-requires": "off", | ||
"@typescript-eslint/require-await": "off", | ||
"@typescript-eslint/restrict-template-expressions": "off", | ||
"@typescript-eslint/return-await": ["error", "always"], | ||
"@typescript-eslint/typedef": [ | ||
"error", | ||
{ | ||
"parameter": true, | ||
"propertyDeclaration": true | ||
} | ||
], | ||
"import/extensions": ["error", "ignorePackages"], | ||
"import/no-extraneous-dependencies": "error", | ||
"import/no-unresolved": "off", | ||
"import/no-useless-path-segments": "error", | ||
"import/order": [ | ||
"error", | ||
{ | ||
"alphabetize": { | ||
"caseInsensitive": true, | ||
"order": "asc" | ||
}, | ||
"groups": [ | ||
["builtin", "external", "object", "type"], | ||
["internal", "parent", "sibling", "index"] | ||
], | ||
"newlines-between": "always" | ||
} | ||
], | ||
"no-return-await": "off", | ||
"no-unused-vars": "off", | ||
"prefer-const": "off", | ||
"quotes": [ | ||
"error", | ||
"single", | ||
{ | ||
"allowTemplateLiterals": true | ||
} | ||
], | ||
"sort-imports": [ | ||
"error", | ||
{ | ||
"allowSeparatedGroups": true, | ||
"ignoreCase": true, | ||
"ignoreDeclarationSort": true, | ||
"ignoreMemberSort": false, | ||
"memberSyntaxSortOrder": ["none", "all", "multiple", "single"] | ||
} | ||
], | ||
"unicorn/prefer-node-protocol": "error" | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
# These are supported funding model platforms | ||
|
||
github: LucasB25 | ||
custom: ['https://www.paypal.me/battistoloL'] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,75 @@ | ||
# For most projects, this workflow file will not need changing; you simply need | ||
# to commit it to your repository. | ||
# | ||
# You may wish to alter this file to override the set of languages analyzed, | ||
# or to provide custom queries or build logic. | ||
# | ||
# ******** NOTE ******** | ||
# We have attempted to detect the languages in your repository. Please check | ||
# the `language` matrix defined below to confirm you have the correct set of | ||
# supported CodeQL languages. | ||
# | ||
name: 'CodeQL' | ||
|
||
on: | ||
push: | ||
branches: ['main'] | ||
pull_request: | ||
# The branches below must be a subset of the branches above | ||
branches: ['main'] | ||
schedule: | ||
- cron: '18 20 * * 3' | ||
|
||
jobs: | ||
analyze: | ||
name: Analyze | ||
runs-on: ubuntu-latest | ||
permissions: | ||
actions: read | ||
contents: read | ||
security-events: write | ||
|
||
strategy: | ||
fail-fast: false | ||
matrix: | ||
language: ['javascript'] | ||
# CodeQL supports [ 'cpp', 'csharp', 'go', 'java', 'javascript', 'python', 'ruby' ] | ||
# Use only 'java' to analyze code written in Java, Kotlin or both | ||
# Use only 'javascript' to analyze code written in JavaScript, TypeScript or both | ||
# Learn more about CodeQL language support at https://aka.ms/codeql-docs/language-support | ||
|
||
steps: | ||
- name: Checkout repository | ||
uses: actions/checkout@v4 | ||
|
||
# Initializes the CodeQL tools for scanning. | ||
- name: Initialize CodeQL | ||
uses: github/codeql-action/init@v3 | ||
with: | ||
languages: ${{ matrix.language }} | ||
# If you wish to specify custom queries, you can do so here or in a config file. | ||
# By default, queries listed here will override any specified in a config file. | ||
# Prefix the list here with "+" to use these queries and those in the config file. | ||
|
||
# Details on CodeQL's query packs refer to : https://docs.github.com/en/code-security/code-scanning/automatically-scanning-your-code-for-vulnerabilities-and-errors/configuring-code-scanning#using-queries-in-ql-packs | ||
# queries: security-extended,security-and-quality | ||
|
||
# Autobuild attempts to build any compiled languages (C/C++, C#, Go, or Java). | ||
# If this step fails, then you should remove it and run the build manually (see below) | ||
- name: Autobuild | ||
uses: github/codeql-action/autobuild@v3 | ||
|
||
# ℹ️ Command-line programs to run using the OS shell. | ||
# 📚 See https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#jobsjob_idstepsrun | ||
|
||
# If the Autobuild fails above, remove it and uncomment the following three lines. | ||
# modify them (or add more) to build your code if your project, please refer to the EXAMPLE below for guidance. | ||
|
||
# - run: | | ||
# echo "Run, Build Application using script" | ||
# ./location_of_script_within_repo/buildscript.sh | ||
|
||
- name: Perform CodeQL Analysis | ||
uses: github/codeql-action/analyze@v3 | ||
with: | ||
category: '/language:${{matrix.language}}' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
# Folders | ||
/.cache | ||
/.git | ||
/dist | ||
/node_modules | ||
.eslintcache | ||
.env | ||
package-lock.json | ||
yarn.lock |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
{ | ||
"extends": [ | ||
"development" | ||
], | ||
"hints": { | ||
"typescript-config/strict": "off" | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
# Folders | ||
/.cache | ||
/.git | ||
/dist | ||
/node_modules | ||
.eslintcache | ||
yarn.lock |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
{ | ||
"printWidth": 100, | ||
"tabWidth": 4, | ||
"useTabs": false, | ||
"semi": true, | ||
"singleQuote": true, | ||
"quoteProps": "as-needed", | ||
"trailingComma": "es5", | ||
"bracketSpacing": true, | ||
"arrowParens": "avoid", | ||
"endOfLine": "auto" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,108 @@ | ||
<center><img src="https://capsule-render.vercel.app/api?type=waving&color=gradient&height=200§ion=header&text=AikouTicket&fontSize=80&fontAlignY=35&animation=twinkling&fontColor=gradient" /></center> | ||
|
||
[![Version][version-shield]](version-url) | ||
[![Contributors][contributors-shield]][contributors-url] | ||
[![Forks][forks-shield]][forks-url] | ||
[![Stargazers][stars-shield]][stars-url] | ||
[![Issues][issues-shield]][issues-url] | ||
[![Support Server][support-shield]][support-server] | ||
[![MIT License][license-shield]][license-url] | ||
[![Run on Repl.it](https://repl.it/badge/github/LucasB25/AikouTicket)](https://repl.it/github/LucasB25/AikouTicket) | ||
[![Remix on Glitch](https://cdn.glitch.com/2703baf2-b643-4da7-ab91-7ee2a2d00b5b%2Fremix-button.svg)](https://glitch.com/edit/#!/import/github/LucasB25/AikouTicket) | ||
|
||
<!-- PROJECT LOGO --> | ||
<br /> | ||
|
||
<h1 align="center">AikouTicket</h1> | ||
|
||
<p align="center">AikouTicket and TypeScript. | ||
<br /> | ||
<br /> | ||
<a href="https://discord.gg/AhUJa2kdAr">Serveur Support</a> | ||
· | ||
<a href="https://github.com/LucasB25/AikouTicket/issues">Report Bug & Request Feature</a> | ||
</p> | ||
</p> | ||
|
||
# AikouTicket | ||
|
||
AikouTicket is a versatile Discord bot that now also offers text-to-text capabilities through its integration with Google Gemini, an advanced text generation model platform. It automatically responds to specific commands on Discord, generating text or images based on the nature of users' requests. | ||
|
||
## 🔧 Requirements | ||
|
||
- Create Discord Bot and get token and client id from [Discord Developer Portal](https://discord.com/developers/applications) | ||
|
||
- Download [Node.js](https://nodejs.org/en/download/) | ||
|
||
## 🚀 Installation from source | ||
|
||
1. Clone the AikouTicket repository: | ||
|
||
```bash | ||
git clone https://github.com/LucasB25/AikouTicket.git | ||
``` | ||
|
||
2. change the directory to AikouTicket | ||
|
||
```bash | ||
cd AikouTicket | ||
``` | ||
|
||
3. Install the required packages: | ||
|
||
```bash | ||
npm i | ||
or | ||
yarn i | ||
``` | ||
|
||
4. Set up your environment variables: | ||
|
||
Create a `.env` file in the root directory of your project with the following variables: | ||
or you can use the [.env.example](https://raw.githubusercontent.com/LucasB25/AikouTicket/main/.env.example) file | ||
|
||
```bash | ||
TOKEN= #Discord Bot Token | ||
CLIENT_ID= #Discord Bot Client ID | ||
Activity=/help | ||
``` | ||
|
||
5. Run the bot: | ||
|
||
```bash | ||
npm start | ||
``` | ||
|
||
## 📜 Contributing | ||
|
||
Thank you for your interest in contributing to AikouTicket! Here are some guidelines to follow when contributing: | ||
|
||
1. Fork the repository and create a new branch for your feature or bug fix. | ||
2. Write clean and concise code that follows the established coding style. | ||
3. Create detailed and thorough documentation for any new features or changes. | ||
4. Write and run tests for your code. | ||
5. Submit a pull request with your changes. | ||
|
||
Your contribution will be reviewed by the project maintainers, and any necessary feedback or changes will be discussed with you. We appreciate your help in making AikouTicket better! | ||
|
||
## 👥 Contributors | ||
|
||
Thanks goes to these wonderful people : | ||
|
||
<a href="https://github.com/LucasB25/AikouTicket/graphs/contributors"> | ||
<img src="https://contrib.rocks/image?repo=LucasB25/AikouTicket" alt="contributors" width="500" /> | ||
</a> | ||
|
||
[version-shield]: https://img.shields.io/github/package-json/v/LucasB25/AikouTicket?style=for-the-badge | ||
[contributors-shield]: https://img.shields.io/github/contributors/LucasB25/AikouTicket.svg?style=for-the-badge | ||
[contributors-url]: https://github.com/LucasB25/AikouTicket/graphs/contributors | ||
[forks-shield]: https://img.shields.io/github/forks/LucasB25/AikouTicket.svg?style=for-the-badge | ||
[forks-url]: https://github.com/LucasB25/AikouTicket/network/members | ||
[stars-shield]: https://img.shields.io/github/stars/LucasB25/AikouTicket.svg?style=for-the-badge | ||
[stars-url]: https://github.com/LucasB25/AikouTicket/stargazers | ||
[issues-shield]: https://img.shields.io/github/issues/LucasB25/AikouTicket.svg?style=for-the-badge | ||
[issues-url]: https://github.com/LucasB25/AikouTicket/issues | ||
[license-shield]: https://img.shields.io/github/license/LucasB25/AikouTicket.svg?style=for-the-badge | ||
[license-url]: https://github.com/LucasB25/AikouTicket/blob/mains/LICENSE | ||
[support-server]: https://discord.gg/AhUJa2kdAr | ||
[support-shield]: https://img.shields.io/discord/942117923001098260.svg?style=for-the-badge&logo=discord&colorB=7289DA |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,59 @@ | ||
{ | ||
"name": "AikouTicket", | ||
"version": "0.5.0", | ||
"description": "A simple AikouTicket bot for discord", | ||
"type": "module", | ||
"main": "dist/index.js", | ||
"scripts": { | ||
"start": "npm run build && node dist/index.js", | ||
"clean:windows": "rmdir /s /q dist", | ||
"clean:linux": "rm -rf dist", | ||
"build": "tsc --project tsconfig.json", | ||
"lint": "eslint . --cache --ext .js,.jsx,.ts,.tsx", | ||
"lint:fix": "eslint . --fix --cache --ext .js,.jsx,.ts,.tsx", | ||
"format": "prettier --check .", | ||
"format:fix": "prettier --write ." | ||
}, | ||
"repository": { | ||
"type": "git", | ||
"url": "git+https://github.com/LucasB25/AikouTicket.git" | ||
}, | ||
"bugs": { | ||
"url": "https://github.com/LucasB25/AikouTicket/issues" | ||
}, | ||
"homepage": "https://github.com/LucasB25/AikouTicket#readme", | ||
"devDependencies": { | ||
"@types/node": "^20.12.12", | ||
"@types/signale": "^1.4.7", | ||
"@typescript-eslint/eslint-plugin": "^7.9.0", | ||
"@typescript-eslint/parser": "^7.9.0", | ||
"eslint": "^8.57.0", | ||
"eslint-plugin-import": "^2.29.1", | ||
"eslint-plugin-unicorn": "^53.0.0", | ||
"prettier": "^3.2.5", | ||
"ts-node": "^10.9.2" | ||
}, | ||
"keywords": [ | ||
"discord", | ||
"bot", | ||
"support", | ||
"tickets", | ||
"typescript" | ||
], | ||
"author": "LucasB25", | ||
"license": "GPL-3.0", | ||
"signale": { | ||
"displayScope": true, | ||
"displayBadge": true, | ||
"displayDate": true, | ||
"displayFilename": true, | ||
"displayLabel": true, | ||
"displayTimestamp": true, | ||
"underlineLabel": true | ||
}, | ||
"dependencies": { | ||
"discord.js": "^14.15.2", | ||
"dotenv": "^16.4.5", | ||
"signale": "^1.4.0" | ||
} | ||
} |
Oops, something went wrong.