feat: Able to blank
This commit is contained in:
parent
1fd2bc814f
commit
a57d3d6d69
86 changed files with 1257 additions and 2424 deletions
86
.pnp.loader.mjs
generated
86
.pnp.loader.mjs
generated
|
@ -1,3 +1,6 @@
|
|||
/* eslint-disable */
|
||||
// @ts-nocheck
|
||||
|
||||
import fs from 'fs';
|
||||
import { URL as URL$1, fileURLToPath, pathToFileURL } from 'url';
|
||||
import path from 'path';
|
||||
|
@ -109,10 +112,9 @@ async function copyImpl(prelayout, postlayout, destinationFs, destination, sourc
|
|||
updated = await copySymlink(prelayout, postlayout, destinationFs, destination, destinationStat, sourceFs, source, sourceStat, opts);
|
||||
}
|
||||
break;
|
||||
default:
|
||||
{
|
||||
throw new Error(`Unsupported file type (${sourceStat.mode})`);
|
||||
}
|
||||
default: {
|
||||
throw new Error(`Unsupported file type (${sourceStat.mode})`);
|
||||
}
|
||||
}
|
||||
if (opts.linkStrategy?.type !== `HardlinkFromIndex` || !sourceStat.isFile()) {
|
||||
if (updated || destinationStat?.mtime?.getTime() !== mtime.getTime() || destinationStat?.atime?.getTime() !== atime.getTime()) {
|
||||
|
@ -175,7 +177,10 @@ async function copyFolder(prelayout, postlayout, destinationFs, destination, des
|
|||
}
|
||||
async function copyFileViaIndex(prelayout, postlayout, destinationFs, destination, destinationStat, sourceFs, source, sourceStat, opts, linkStrategy) {
|
||||
const sourceHash = await sourceFs.checksumFilePromise(source, { algorithm: `sha1` });
|
||||
const indexPath = destinationFs.pathUtils.join(linkStrategy.indexPath, sourceHash.slice(0, 2), `${sourceHash}.dat`);
|
||||
const defaultMode = 420;
|
||||
const sourceMode = sourceStat.mode & 511;
|
||||
const indexFileName = `${sourceHash}${sourceMode !== defaultMode ? sourceMode.toString(8) : ``}`;
|
||||
const indexPath = destinationFs.pathUtils.join(linkStrategy.indexPath, sourceHash.slice(0, 2), `${indexFileName}.dat`);
|
||||
let AtomicBehavior;
|
||||
((AtomicBehavior2) => {
|
||||
AtomicBehavior2[AtomicBehavior2["Lock"] = 0] = "Lock";
|
||||
|
@ -231,8 +236,12 @@ async function copyFileViaIndex(prelayout, postlayout, destinationFs, destinatio
|
|||
}
|
||||
});
|
||||
postlayout.push(async () => {
|
||||
if (!indexStat)
|
||||
if (!indexStat) {
|
||||
await destinationFs.lutimesPromise(indexPath, defaultTime, defaultTime);
|
||||
if (sourceMode !== defaultMode) {
|
||||
await destinationFs.chmodPromise(indexPath, sourceMode);
|
||||
}
|
||||
}
|
||||
if (tempPath && !tempPathCleaned) {
|
||||
await destinationFs.unlinkPromise(tempPath);
|
||||
}
|
||||
|
@ -824,6 +833,12 @@ class ProxiedFS extends FakeFS {
|
|||
rmdirSync(p, opts) {
|
||||
return this.baseFs.rmdirSync(this.mapToBase(p), opts);
|
||||
}
|
||||
async rmPromise(p, opts) {
|
||||
return this.baseFs.rmPromise(this.mapToBase(p), opts);
|
||||
}
|
||||
rmSync(p, opts) {
|
||||
return this.baseFs.rmSync(this.mapToBase(p), opts);
|
||||
}
|
||||
async linkPromise(existingP, newP) {
|
||||
return this.baseFs.linkPromise(this.mapToBase(existingP), this.mapToBase(newP));
|
||||
}
|
||||
|
@ -1205,6 +1220,18 @@ class NodeFS extends BasePortableFakeFS {
|
|||
rmdirSync(p, opts) {
|
||||
return this.realFs.rmdirSync(npath.fromPortablePath(p), opts);
|
||||
}
|
||||
async rmPromise(p, opts) {
|
||||
return await new Promise((resolve, reject) => {
|
||||
if (opts) {
|
||||
this.realFs.rm(npath.fromPortablePath(p), opts, this.makeCallback(resolve, reject));
|
||||
} else {
|
||||
this.realFs.rm(npath.fromPortablePath(p), this.makeCallback(resolve, reject));
|
||||
}
|
||||
});
|
||||
}
|
||||
rmSync(p, opts) {
|
||||
return this.realFs.rmSync(npath.fromPortablePath(p), opts);
|
||||
}
|
||||
async linkPromise(existingP, newP) {
|
||||
return await new Promise((resolve, reject) => {
|
||||
this.realFs.link(npath.fromPortablePath(existingP), npath.fromPortablePath(newP), this.makeCallback(resolve, reject));
|
||||
|
@ -1392,9 +1419,13 @@ class VirtualFS extends ProxiedFS {
|
|||
}
|
||||
}
|
||||
|
||||
const URL = Number(process.versions.node.split('.', 1)[0]) < 20 ? URL$1 : globalThis.URL;
|
||||
|
||||
const [major, minor] = process.versions.node.split(`.`).map((value) => parseInt(value, 10));
|
||||
const WATCH_MODE_MESSAGE_USES_ARRAYS = major > 19 || major === 19 && minor >= 2 || major === 18 && minor >= 13;
|
||||
const HAS_LAZY_LOADED_TRANSLATORS = major === 20 && minor < 6 || major === 19 && minor >= 3;
|
||||
const SUPPORTS_IMPORT_ATTRIBUTES = major >= 21 || major === 20 && minor >= 10 || major === 18 && minor >= 20;
|
||||
const SUPPORTS_IMPORT_ATTRIBUTES_ONLY = major >= 22;
|
||||
|
||||
function readPackageScope(checkPath) {
|
||||
const rootSeparatorIndex = checkPath.indexOf(npath.sep);
|
||||
|
@ -1432,7 +1463,7 @@ async function tryReadFile$1(path2) {
|
|||
}
|
||||
function tryParseURL(str, base) {
|
||||
try {
|
||||
return new URL$1(str, base);
|
||||
return new URL(str, base);
|
||||
} catch {
|
||||
return null;
|
||||
}
|
||||
|
@ -1485,10 +1516,21 @@ async function load$1(urlString, context, nextLoad) {
|
|||
const format = getFileFormat(filePath);
|
||||
if (!format)
|
||||
return nextLoad(urlString, context, nextLoad);
|
||||
if (format === `json` && context.importAssertions?.type !== `json`) {
|
||||
const err = new TypeError(`[ERR_IMPORT_ASSERTION_TYPE_MISSING]: Module "${urlString}" needs an import assertion of type "json"`);
|
||||
err.code = `ERR_IMPORT_ASSERTION_TYPE_MISSING`;
|
||||
throw err;
|
||||
if (format === `json`) {
|
||||
if (SUPPORTS_IMPORT_ATTRIBUTES_ONLY) {
|
||||
if (context.importAttributes?.type !== `json`) {
|
||||
const err = new TypeError(`[ERR_IMPORT_ATTRIBUTE_MISSING]: Module "${urlString}" needs an import attribute of "type: json"`);
|
||||
err.code = `ERR_IMPORT_ATTRIBUTE_MISSING`;
|
||||
throw err;
|
||||
}
|
||||
} else {
|
||||
const type = `importAttributes` in context ? context.importAttributes?.type : context.importAssertions?.type;
|
||||
if (type !== `json`) {
|
||||
const err = new TypeError(`[ERR_IMPORT_ASSERTION_TYPE_MISSING]: Module "${urlString}" needs an import ${SUPPORTS_IMPORT_ATTRIBUTES ? `attribute` : `assertion`} of type "json"`);
|
||||
err.code = `ERR_IMPORT_ASSERTION_TYPE_MISSING`;
|
||||
throw err;
|
||||
}
|
||||
}
|
||||
}
|
||||
if (process.env.WATCH_REPORT_DEPENDENCIES && process.send) {
|
||||
const pathToSend = pathToFileURL(
|
||||
|
@ -1676,28 +1718,6 @@ function getPackageScopeConfig(resolved, readFileSyncFn) {
|
|||
return packageConfig;
|
||||
}
|
||||
|
||||
/**
|
||||
@license
|
||||
Copyright Node.js contributors. All rights reserved.
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
of this software and associated documentation files (the "Software"), to
|
||||
deal in the Software without restriction, including without limitation the
|
||||
rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
|
||||
sell copies of the Software, and to permit persons to whom the Software is
|
||||
furnished to do so, subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in
|
||||
all copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
|
||||
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
|
||||
IN THE SOFTWARE.
|
||||
*/
|
||||
function throwImportNotDefined(specifier, packageJSONUrl, base) {
|
||||
throw new ERR_PACKAGE_IMPORT_NOT_DEFINED(
|
||||
specifier,
|
||||
|
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
BIN
.yarn/cache/glob-npm-7.1.6-1ce3a5189a-7d6ec98bc7.zip
vendored
BIN
.yarn/cache/glob-npm-7.1.6-1ce3a5189a-7d6ec98bc7.zip
vendored
Binary file not shown.
BIN
.yarn/cache/glob-npm-7.2.3-2d866d17a5-59452a9202.zip
vendored
BIN
.yarn/cache/glob-npm-7.2.3-2d866d17a5-59452a9202.zip
vendored
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
BIN
.yarn/cache/ip-npm-2.0.0-204facb3cc-1270b11e53.zip
vendored
BIN
.yarn/cache/ip-npm-2.0.0-204facb3cc-1270b11e53.zip
vendored
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
BIN
.yarn/cache/ms-npm-2.1.3-81ff3cfac1-aa92de6080.zip
vendored
BIN
.yarn/cache/ms-npm-2.1.3-81ff3cfac1-aa92de6080.zip
vendored
Binary file not shown.
Binary file not shown.
BIN
.yarn/cache/nopt-npm-6.0.0-5ea8050815-3c1128e07c.zip
vendored
BIN
.yarn/cache/nopt-npm-6.0.0-5ea8050815-3c1128e07c.zip
vendored
Binary file not shown.
Binary file not shown.
BIN
.yarn/cache/once-npm-1.4.0-ccf03ef07a-cd0a885013.zip
vendored
BIN
.yarn/cache/once-npm-1.4.0-ccf03ef07a-cd0a885013.zip
vendored
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
BIN
.yarn/cache/tar-npm-6.2.0-3eb25205a7-2042bbb148.zip
vendored
BIN
.yarn/cache/tar-npm-6.2.0-3eb25205a7-2042bbb148.zip
vendored
Binary file not shown.
BIN
.yarn/cache/tsup-npm-8.0.1-f690188444-f5866035ac.zip
vendored
BIN
.yarn/cache/tsup-npm-8.0.1-f690188444-f5866035ac.zip
vendored
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
BIN
.yarn/cache/yaml-npm-2.3.2-b844830a8b-dba78b314c.zip
vendored
BIN
.yarn/cache/yaml-npm-2.3.2-b844830a8b-dba78b314c.zip
vendored
Binary file not shown.
893
.yarn/releases/yarn-4.0.2.cjs
vendored
893
.yarn/releases/yarn-4.0.2.cjs
vendored
File diff suppressed because one or more lines are too long
|
@ -2,4 +2,4 @@ compressionLevel: mixed
|
|||
|
||||
enableGlobalCache: false
|
||||
|
||||
yarnPath: .yarn/releases/yarn-4.0.2.cjs
|
||||
yarnPath: .yarn/releases/yarn-4.2.2.cjs
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
{
|
||||
"name": "muffin-ai-arujak",
|
||||
"version": "2.0.0-82-oreo",
|
||||
"version": "2.0.0-oreo.83",
|
||||
"main": "dist/index.js",
|
||||
"private": true,
|
||||
"dependencies": {
|
||||
|
@ -14,14 +14,14 @@
|
|||
"cross-env": "^7.0.3",
|
||||
"prettier": "^3.1.0",
|
||||
"ts-node": "^10.9.1",
|
||||
"tsup": "^8.0.1",
|
||||
"typescript": "^5.3.2"
|
||||
"tsup": "^8.0.2",
|
||||
"typescript": "^5.4.5"
|
||||
},
|
||||
"scripts": {
|
||||
"build": "tsup",
|
||||
"dev": "cross-env NODE_ENV=development ts-node src",
|
||||
"start": "cross-env NODE_ENV=production node dist"
|
||||
},
|
||||
"packageManager": "yarn@4.0.2",
|
||||
"packageManager": "yarn@4.2.2",
|
||||
"prettier": "@migan/prettier-config"
|
||||
}
|
||||
|
|
|
@ -13,7 +13,7 @@ export default class extends Command {
|
|||
'```\n멒힌아 배워 (등록할 단어) (대답)\n```\n `_`를 대답에 쓰면 공백으로 바뀌ㅇ어요.',
|
||||
)
|
||||
}
|
||||
const command = args[0]
|
||||
const command = args[0].replaceAll('_', ' ')
|
||||
const result = args[1].replaceAll('_', ' ')
|
||||
const ignore = [
|
||||
'학습데이터량',
|
||||
|
|
|
@ -16,14 +16,14 @@ export default class ChatBot {
|
|||
.split(/ +/g)
|
||||
.join(' ')
|
||||
const learnData = await this.db.learn.findOne(args)
|
||||
const a = Math.round(Math.random() * (2 - 1) + 1)
|
||||
const randomNumber = Math.round(Math.random() * (2 - 1) + 1)
|
||||
|
||||
if (NODE_ENV === 'development') {
|
||||
console.log(a)
|
||||
console.log(randomNumber)
|
||||
console.log(args)
|
||||
}
|
||||
|
||||
if (a === 1) {
|
||||
if (randomNumber === 1) {
|
||||
if (learnData[0]) {
|
||||
if (args.startsWith(learnData[0].command)) {
|
||||
return `${learnData[0].result}\n\`${
|
||||
|
|
Loading…
Reference in a new issue