Skip to content

Commit

Permalink
Merge pull request #13 from DestroyCom/v1.0.0
Browse files Browse the repository at this point in the history
refactor(typescript): Massive rework to pass from js to ts
  • Loading branch information
DestroyCom authored Aug 26, 2023
2 parents 3ebdfc1 + d6d22f2 commit d0378fe
Show file tree
Hide file tree
Showing 55 changed files with 8,782 additions and 2,941 deletions.
23 changes: 15 additions & 8 deletions .env.dist
Original file line number Diff line number Diff line change
@@ -1,8 +1,15 @@
BOT_TOKEN = Your_Bot_Token
LOG_DIR = Your_Log_Dir
TRIGGER_PREFIX = '&'
TIMEZONE = 'Europe/Paris'
#CHANNEL_ID = Your_Channel_Id
#VOICE_CHANNEL_ID = Your_Voice_Channel_Id
#USER_ID = Your_User_Id
#XIAOMI_SONG = false
#REQUIRED
DISCORD_TOKEN =
DISCORD_CLIENT_ID =
DATABASE_CONNECTION_STRING =
DATABASE_USER =
DATABASE_PASSWORD =
#OPTIONAL
DATABASE_NAME = "stroycord"
PREFIX = "&"
LOG_DIR = "./logs"
LANGUAGE = "en-US"
STROYCORD_LOGO = "https://destroykeaum.alwaysdata.net/assets/other/stroybot_logo.png"
#DOCKER
TIMEZONE = "Europe/Paris"

4 changes: 4 additions & 0 deletions .eslintignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
node_modules
dist
.prettierrc.js
.eslintrc.js
36 changes: 36 additions & 0 deletions .eslintrc.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
module.exports = {
root: true,
parser: '@typescript-eslint/parser',
parserOptions: {
ecmaVersion: 'latest',
sourceType: 'module',
},
settings: {
react: {
version: 'detect',
},
'import/resolver': {
node: {
paths: ['src'],
extensions: ['.ts'],
},
},
},
env: {
es2021: true,
node: true,
},
extends: [
'eslint:recommended',
'plugin:@typescript-eslint/recommended',
'plugin:prettier/recommended', // Make sure this is always the last element in the array.
],
plugins: ['simple-import-sort', 'prettier'],
rules: {
'prettier/prettier': ['error', {}, { usePrettierrc: true }],
'@typescript-eslint/explicit-function-return-type': 'off',
'simple-import-sort/imports': 'error',
'simple-import-sort/exports': 'error',
'@typescript-eslint/no-unused-vars': ['error'],
},
};
15 changes: 15 additions & 0 deletions .github/workflows/create-release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
name: Release pipeline

on:
push:
tags:
- "v*.*.*"

jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Release
uses: softprops/action-gh-release@v1
16 changes: 16 additions & 0 deletions .github/workflows/push-images.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
name: Docker build
on: release
jobs:
docker:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@master
- name: Kaniko build
uses: aevea/action-kaniko@master
with:
image: destcom/stroycord
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_PASSWORD }}
tag: ${{ github.ref }}
tag_with_latest: true
build_file: StroyCord.Dockerfile
31 changes: 3 additions & 28 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,31 +1,6 @@
node_modules
.env
coverage
logs*
mongo*
dist
.idea
.vscode
npm-debug.log
.tmp
.DS_Store
yarn-error.log
temp
public
.log
docs
.nyc_output
cassettes
keys
embeds
ffmpeg.exe
ffplay.exe
ffprobe.exe
deletedCode
codeExample
src
.env.test
.env.prin
.env.copy
codeExample
OLD
wait_*
log*
```
8 changes: 8 additions & 0 deletions .prettierrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
{
"semi": true,
"trailingComma": "es5",
"singleQuote": true,
"printWidth": 120,
"tabWidth": 2,
"endOfLine": "auto"
}
15 changes: 0 additions & 15 deletions Dockerfile

This file was deleted.

Loading

0 comments on commit d0378fe

Please sign in to comment.