- JavaScriptからTypeScriptに改変
- Discordに送信するメッセージの種類を増加
- Misskeyに投稿できるようにコードを追加
- 設定ファイルをJSONからYAMLに変更
- その他依存パッケージ変更
$ cd <任意のディレクトリ>
$ git clone https://github.com/stuayu/EPGS-to-Discord.git
$ cd EPGS-to-Discord
$ npm install
$ npm run build
$ cp config.yaml.sample config.yaml
$ vi config.yaml
"epgstation_url"
: EPGStation を実行しているホストのアドレス
"discord_webhookURL"
: デスクトップ版Discordより取得できるWebhook URLを記述
↓を編集
$ vi config.yaml
EPGStation
のポートを変更している場合 epgstation_host
の 8888
を適宜変更
EPGStation
をサブディレクトリで運用している場合 epgstation_host
の / 以降に hoge/
をなどを追加してください
EPGStationを hoge 以下で運用している場合
"epgstation_url":"http://127.0.0.1:8888/hoge/"
変更対象は EPGS-to-Discord ではなく EPGStation の config.json なので注意
$ vi <EPGStationのディレクトリ>/config/config.json
ここに
"isEnabledDropCheck": true,
"reserveNewAddtionCommand": "/usr/bin/node <EPGS-to-Discordのディレクトリ>/index.js reserve",
"recordingStartCommand": "/usr/bin/node <EPGS-to-Discordのディレクトリ>/index.js start",
"recordingFinishCommand":"/usr/bin/node <EPGS-to-Discordのディレクトリ>/index.js end",
Windowsの場合(C:\TV に nodejs をインストールした場合)
"isEnabledDropCheck": true,
"reserveNewAddtionCommand": "C:\TV\nodejs\node.exe <EPGS-to-Discordのディレクトリ>/index.js reserve",
"recordingStartCommand": "C:\TV\nodejs\node.exe <EPGS-to-Discordのディレクトリ>/index.js start",
"recordingFinishCommand":"C:\TV\nodejs\node.exe <EPGS-to-Discordのディレクトリ>/index.js end",
を追記。
あとは念のため pm2 restart EPGStation
等してリロードさせてください。
EPGStationの config.yml
を変更
例)
reserveNewAddtionCommand: 'C:\Windows\System32\cmd.exe /C node C:\DTV\EPGS-to-Discord\dist\index.js reserve'
recordingStartCommand: 'C:\Windows\System32\cmd.exe /C node C:\DTV\EPGS-to-Discord\dist\index.js start'
recordingFinishCommand: 'C:\Windows\System32\cmd.exe /C node C:\DTV\EPGS-to-Discord\dist\index.js end'
recordingPreStartCommand: 'C:\Windows\System32\cmd.exe /C node C:\DTV\EPGS-to-Discord\dist\index.js prestart'
recordingPrepRecFailedCommand: 'C:\Windows\System32\cmd.exe /C node C:\DTV\EPGS-to-Discord\dist\index.js prepfailed'
recordingFailedCommand: 'C:\Windows\System32\cmd.exe /C node C:\DTV\EPGS-to-Discord\dist\index.js recfailed'