Merge branch 'main' into dev

This commit is contained in:
SillyLossy
2023-05-21 00:10:26 +03:00
6 changed files with 37 additions and 10 deletions

View File

@@ -1,12 +1,17 @@
--- ---
name: Bug report name: Bug report
about: "Create a report to help us improve. PAY ATTENTION: Support requests for extenal programs (reverse proxies, 3rd party servers, other peoples' forks) will be refused!" about: "Create a report to help us improve. PAY ATTENTION: Support requests for external programs (reverse proxies, 3rd party servers, other peoples' forks) will be refused!"
title: "[BUG]" title: "[BUG]"
labels: '' labels: ''
assignees: '' assignees: ''
--- ---
> **Warning**. Complete **all** the fields below. Otherwise your bug report will be **ignored**!
**Have you searched for similar [bugs](https://github.com/Cohee1207/SillyTavern/issues?q=)?**
Yes/No
**Describe the bug** **Describe the bug**
A clear and concise description of what the bug is. A clear and concise description of what the bug is.

View File

@@ -7,6 +7,9 @@ assignees: ''
--- ---
**Have you searched for similar [requests](https://github.com/Cohee1207/SillyTavern/issues?q=)?**
Yes/No
**Is your feature request related to a problem? Please describe.** **Is your feature request related to a problem? Please describe.**
A clear and concise description of what the problem is. Ex. I'm always frustrated when [...] A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]

View File

@@ -16,6 +16,7 @@ Method 1 - GIT
We always recommend users install using 'git'. Here's why: We always recommend users install using 'git'. Here's why:
When you have installed via `git clone`, all you have to do to update is type `git pull` in a command line in the ST folder. When you have installed via `git clone`, all you have to do to update is type `git pull` in a command line in the ST folder.
You can also try running the 'UpdateAndStart.bat' file, which will almost do the same thing. (Windows only)
Alternatively, if the command prompt gives you problems (and you have GitHub Desktop installed), you can use the 'Repository' menu and select 'Pull'. Alternatively, if the command prompt gives you problems (and you have GitHub Desktop installed), you can use the 'Repository' menu and select 'Pull'.
The updates are applied automatically and safely. The updates are applied automatically and safely.

16
UpdateAndStart.bat Normal file
View File

@@ -0,0 +1,16 @@
@echo off
pushd %~dp0
git --version > nul 2>&1
if %errorlevel% neq 0 (
echo Git is not installed on this system. Skipping update.
) else (
call git pull --rebase --autostash
if %errorlevel% neq 0 (
REM incase there is still something wrong
echo There were errors while updating. Please download the latest version manually.
)
)
call npm install
node server.js
pause
popd

View File

@@ -506,16 +506,18 @@ function checkWorldInfo(chat) {
if (Array.isArray(entry.key) && entry.key.length) { if (Array.isArray(entry.key) && entry.key.length) {
primary: for (let key of entry.key) { primary: for (let key of entry.key) {
if (key && textToScan.includes(key.trim().toLowerCase())) { const substituted = substituteParams(key);
if (substituted && textToScan.includes(substituted.trim().toLowerCase())) {
if ( if (
entry.selective && entry.selective &&
Array.isArray(entry.keysecondary) && Array.isArray(entry.keysecondary) &&
entry.keysecondary.length entry.keysecondary.length
) { ) {
secondary: for (let keysecondary of entry.keysecondary) { secondary: for (let keysecondary of entry.keysecondary) {
const secondarySubstituted = substituteParams(keysecondary);
if ( if (
keysecondary && secondarySubstituted &&
textToScan.includes(keysecondary.trim().toLowerCase()) textToScan.includes(secondarySubstituted.trim().toLowerCase())
) { ) {
activatedNow.add(entry.uid); activatedNow.add(entry.uid);
break secondary; break secondary;

View File

@@ -148,10 +148,10 @@ Easy to follow guide with pretty pictures:
Installing via zip download Installing via zip download
1. install [NodeJS](https://nodejs.org/en) (latest LTS version is recommended) 1. Install [NodeJS](https://nodejs.org/en) (latest LTS version is recommended)
2. download the zip from this GitHub repo 2. Download the zip from this GitHub repo. (Get the `Source code (zip)` from [Releases](https://github.com/Cohee1207/SillyTavern/releases/latest))
3. unzip it into a folder of your choice 3. Unzip it into a folder of your choice
4. run start.bat via double-clicking or in a command line. 4. Run `Start.bat` via double-clicking or in a command line.
5. Once the server has prepared everything for you, it will open a tab in your browser. 5. Once the server has prepared everything for you, it will open a tab in your browser.
### Linux ### Linux
@@ -231,7 +231,7 @@ Use http:// NOT https://
### Opening your ST to all IPs ### Opening your ST to all IPs
We do not reccomend doing this, but you can open `config.conf` and change `whitelist` to `false`. We do not recommend doing this, but you can open `config.conf` and change `whitelist` to `false`.
You must remove (or rename) `whitelist.txt` in the SillyTavern base install folder, if it exists. You must remove (or rename) `whitelist.txt` in the SillyTavern base install folder, if it exists.