-
Notifications
You must be signed in to change notification settings - Fork 3
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
60 changed files
with
8,471 additions
and
2,942 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 |
---|---|---|
@@ -1,8 +1,16 @@ | ||
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 = "&" | ||
DETECT_FROM_ALL_MESSAGES = false | ||
LOG_DIR = "./logs" | ||
LANGUAGE = "en-US" | ||
STROYCORD_LOGO = "https://destroykeaum.alwaysdata.net/assets/other/stroybot_logo.png" | ||
#DOCKER | ||
TIMEZONE = "Europe/Paris" | ||
|
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 @@ | ||
node_modules | ||
dist | ||
.prettierrc.js | ||
.eslintrc.js |
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,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'], | ||
}, | ||
}; |
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,11 @@ | ||
# To get started with Dependabot version updates, you'll need to specify which | ||
# package ecosystems to update and where the package manifests are located. | ||
# Please see the documentation for all configuration options: | ||
# https://docs.github.com/github/administering-a-repository/configuration-options-for-dependency-updates | ||
|
||
version: 2 | ||
updates: | ||
- package-ecosystem: "npm" # See documentation for possible values | ||
directory: "/" # Location of package manifests | ||
schedule: | ||
interval: "weekly" |
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,31 @@ | ||
name: Docker build | ||
on: | ||
workflow_call: | ||
workflow_dispatch: | ||
inputs: | ||
tag: | ||
description: 'Tag to use for the image' | ||
required: true | ||
|
||
jobs: | ||
docker: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@master | ||
with: | ||
ref: release | ||
fetch-depth: 0 | ||
- name: Get Latest Tag | ||
id: latest_tag | ||
uses: WyriHaximus/github-action-get-previous-tag@v1 | ||
- name: Echo latest tag | ||
run: echo '${{ steps.latest_tag.outputs.tag }}' | ||
- name: Kaniko build | ||
uses: aevea/action-kaniko@master | ||
with: | ||
image: destcom/stroycord | ||
username: ${{ secrets.DOCKERHUB_USERNAME }} | ||
password: ${{ secrets.DOCKERHUB_PASSWORD }} | ||
tag: ${{ github.event.inputs.tag || steps.latest_tag.outputs.tag }} | ||
tag_with_latest: true | ||
build_file: ./StroyCord.Dockerfile |
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,31 @@ | ||
name: Create new tag based on last commit message | ||
|
||
on: | ||
workflow_call: | ||
workflow_dispatch: | ||
|
||
jobs: | ||
deploy: | ||
runs-on: ubuntu-latest | ||
permissions: | ||
contents: write | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v2 | ||
with: | ||
ref: release | ||
fetch-depth: 0 | ||
- name: Get last commit message | ||
id: commit_message | ||
run: | | ||
MESSAGE=$(git log -1 --pretty=format:'%s') | ||
CLEANED_MESSAGE=$(echo "$MESSAGE" | sed -e 's/[^a-zA-Z0-9.-]/-/g') | ||
echo "COMMIT_MSG=${CLEANED_MESSAGE}" >> $GITHUB_ENV | ||
- name: Create or update major version | ||
uses: joutvhu/create-tag@v1 | ||
with: | ||
tag_name: ${{ env.COMMIT_MSG }} | ||
message: ${{ env.COMMIT_MSG }} | ||
on_tag_exists: update | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |
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,20 @@ | ||
name: Release pipeline | ||
|
||
on: | ||
push: | ||
branches: | ||
- release | ||
workflow_dispatch: | ||
|
||
jobs: | ||
create_tag: | ||
uses: ./.github/workflows/create_tag.yml | ||
secrets: inherit | ||
build: | ||
needs: create_tag | ||
uses: ./.github/workflows/build.yml | ||
secrets: inherit | ||
release: | ||
needs: [build] | ||
uses: ./.github/workflows/release.yml | ||
secrets: inherit |
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,29 @@ | ||
name: Create a release | ||
|
||
on: | ||
workflow_call: | ||
workflow_dispatch: | ||
|
||
jobs: | ||
launch_release: | ||
runs-on: ubuntu-latest | ||
permissions: | ||
contents: write | ||
discussions: write | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v3 | ||
with: | ||
ref: master | ||
fetch-depth: 0 | ||
- name: Get Latest Tag | ||
id: latest_tag | ||
uses: WyriHaximus/github-action-get-previous-tag@v1 | ||
- name: Echo latest tag | ||
run: echo '${{ steps.latest_tag.outputs.tag }}' | ||
- name: Release | ||
uses: softprops/action-gh-release@v1 | ||
with: | ||
generate_release_notes: true | ||
tag_name: ${{ steps.latest_tag.outputs.tag }} | ||
name: ${{ steps.latest_tag.outputs.tag }} |
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 |
---|---|---|
@@ -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* | ||
``` |
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 @@ | ||
#!/usr/bin/env sh | ||
. "$(dirname -- "$0")/_/husky.sh" | ||
|
||
if [[ "$OSTYPE" == "msys" ]]; then | ||
npx.cmd --no -- commitlint --edit ${1} | ||
else | ||
npx --no -- commitlint --edit ${1} | ||
fi | ||
|
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,10 @@ | ||
#!/usr/bin/env sh | ||
. "$(dirname -- "$0")/_/husky.sh" | ||
|
||
if [[ "$OSTYPE" == "msys" ]]; then | ||
npm.cmd run lint -- --fix | ||
else | ||
npm run lint -- --fix | ||
fi | ||
|
||
|
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 @@ | ||
{ | ||
"semi": true, | ||
"trailingComma": "es5", | ||
"singleQuote": true, | ||
"printWidth": 120, | ||
"tabWidth": 2, | ||
"endOfLine": "auto" | ||
} |
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.