qsu 1.7.2 → 1.8.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.ts +0 -2
- package/dist/index.js +1 -1
- package/dist/server/crypto/decrypt.js +1 -0
- package/dist/server/crypto/encrypt.js +1 -0
- package/dist/server/crypto/index.d.ts +9 -0
- package/dist/server/crypto/index.js +1 -0
- package/dist/server/crypto/md5Hash.js +1 -0
- package/dist/server/crypto/sha1Hash.js +1 -0
- package/dist/server/crypto/sha256Hash.js +1 -0
- package/dist/server/file/createDirectory.js +1 -0
- package/dist/server/file/createFileWithDummy.js +1 -0
- package/dist/server/file/deleteAllFileFromDirectory.js +1 -0
- package/dist/server/file/getFileHash.js +1 -0
- package/dist/{file → server/file}/getFileInfo.d.ts +1 -1
- package/dist/server/file/getFileInfo.js +1 -0
- package/dist/server/file/getFilePathLevel.js +1 -0
- package/dist/{file → server/file}/getFileSize.d.ts +1 -1
- package/dist/server/file/getParentFilePath.js +1 -0
- package/dist/server/file/index.d.ts +22 -0
- package/dist/server/file/index.js +1 -0
- package/dist/server/file/isValidFileName.js +1 -0
- package/dist/server/file/joinFilePath.js +1 -0
- package/dist/server/index.d.ts +2 -0
- package/dist/server/index.js +1 -0
- package/package.json +1 -1
- package/dist/encrypt/decrypt.js +0 -1
- package/dist/encrypt/encrypt.js +0 -1
- package/dist/encrypt/index.d.ts +0 -9
- package/dist/encrypt/index.js +0 -1
- package/dist/encrypt/md5Hash.js +0 -1
- package/dist/encrypt/sha1Hash.js +0 -1
- package/dist/encrypt/sha256Hash.js +0 -1
- package/dist/file/createDirectory.js +0 -1
- package/dist/file/createFileWithDummy.js +0 -1
- package/dist/file/deleteAllFileFromDirectory.js +0 -1
- package/dist/file/getFileHash.js +0 -1
- package/dist/file/getFileInfo.js +0 -1
- package/dist/file/getFilePathLevel.js +0 -1
- package/dist/file/getParentFilePath.js +0 -1
- package/dist/file/index.d.ts +0 -22
- package/dist/file/index.js +0 -1
- package/dist/file/isValidFileName.js +0 -1
- package/dist/file/joinFilePath.js +0 -1
- /package/dist/{encrypt → server/crypto}/decodeBase64.d.ts +0 -0
- /package/dist/{encrypt → server/crypto}/decodeBase64.js +0 -0
- /package/dist/{encrypt → server/crypto}/decrypt.d.ts +0 -0
- /package/dist/{encrypt → server/crypto}/encodeBase64.d.ts +0 -0
- /package/dist/{encrypt → server/crypto}/encodeBase64.js +0 -0
- /package/dist/{encrypt → server/crypto}/encrypt.d.ts +0 -0
- /package/dist/{encrypt → server/crypto}/md5Hash.d.ts +0 -0
- /package/dist/{encrypt → server/crypto}/objectId.d.ts +0 -0
- /package/dist/{encrypt → server/crypto}/objectId.js +0 -0
- /package/dist/{encrypt → server/crypto}/sha1Hash.d.ts +0 -0
- /package/dist/{encrypt → server/crypto}/sha256Hash.d.ts +0 -0
- /package/dist/{encrypt → server/crypto}/strToNumberHash.d.ts +0 -0
- /package/dist/{encrypt → server/crypto}/strToNumberHash.js +0 -0
- /package/dist/{file → server/file}/createDirectory.d.ts +0 -0
- /package/dist/{file → server/file}/createFile.d.ts +0 -0
- /package/dist/{file → server/file}/createFile.js +0 -0
- /package/dist/{file → server/file}/createFileWithDummy.d.ts +0 -0
- /package/dist/{file → server/file}/deleteAllFileFromDirectory.d.ts +0 -0
- /package/dist/{file → server/file}/deleteFile.d.ts +0 -0
- /package/dist/{file → server/file}/deleteFile.js +0 -0
- /package/dist/{file → server/file}/getFileExtension.d.ts +0 -0
- /package/dist/{file → server/file}/getFileExtension.js +0 -0
- /package/dist/{file → server/file}/getFileHash.d.ts +0 -0
- /package/dist/{file → server/file}/getFileName.d.ts +0 -0
- /package/dist/{file → server/file}/getFileName.js +0 -0
- /package/dist/{file → server/file}/getFilePathLevel.d.ts +0 -0
- /package/dist/{file → server/file}/getFileSize.js +0 -0
- /package/dist/{file → server/file}/getParentFilePath.d.ts +0 -0
- /package/dist/{file → server/file}/headFile.d.ts +0 -0
- /package/dist/{file → server/file}/headFile.js +0 -0
- /package/dist/{file → server/file}/isFileExists.d.ts +0 -0
- /package/dist/{file → server/file}/isFileExists.js +0 -0
- /package/dist/{file → server/file}/isFileHidden.d.ts +0 -0
- /package/dist/{file → server/file}/isFileHidden.js +0 -0
- /package/dist/{file → server/file}/isValidFileName.d.ts +0 -0
- /package/dist/{file → server/file}/joinFilePath.d.ts +0 -0
- /package/dist/{file → server/file}/moveFile.d.ts +0 -0
- /package/dist/{file → server/file}/moveFile.js +0 -0
- /package/dist/{file → server/file}/normalizeFile.d.ts +0 -0
- /package/dist/{file → server/file}/normalizeFile.js +0 -0
- /package/dist/{file → server/file}/tailFile.d.ts +0 -0
- /package/dist/{file → server/file}/tailFile.js +0 -0
- /package/dist/{file → server/file}/toPosixFilePath.d.ts +0 -0
- /package/dist/{file → server/file}/toPosixFilePath.js +0 -0
- /package/dist/{file → server/file}/toValidFilePath.d.ts +0 -0
- /package/dist/{file → server/file}/toValidFilePath.js +0 -0
package/dist/index.d.ts
CHANGED
package/dist/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export*from"./array/index.js";export*from"./
|
|
1
|
+
export*from"./array/index.js";export*from"./date/index.js";export*from"./format/index.js";export*from"./math/index.js";export*from"./misc/index.js";export*from"./object/index.js";export*from"./string/index.js";export*from"./verify/index.js";export*from"./web/index.js";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{createDecipheriv as t}from"node:crypto";export function decrypt(r,e,f="aes-256-cbc",o=!1){if(!r||r.length<1)return"";const n=o?"base64":"hex",c=r.split(":"),i=t(f,e,Buffer.from(c.shift(),n));let u=i.update(Buffer.from(c.join(":"),n));return u=Buffer.concat([u,i.final()]),u.toString()}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{createCipheriv as t,randomBytes as n}from"node:crypto";export function encrypt(e,r,o="aes-256-cbc",c=16,f=!1){if(!e||e.length<1)return"";const i=n(c),a=t(o,r,i);let p=a.update(e);p=Buffer.concat([p,a.final()]);const u=f?"base64":"hex";return`${i.toString(u)}:${p.toString(u)}`}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
export { decodeBase64 } from './decodeBase64';
|
|
2
|
+
export { decrypt } from './decrypt';
|
|
3
|
+
export { encodeBase64 } from './encodeBase64';
|
|
4
|
+
export { encrypt } from './encrypt';
|
|
5
|
+
export { md5Hash } from './md5Hash';
|
|
6
|
+
export { objectId } from './objectId';
|
|
7
|
+
export { sha1Hash } from './sha1Hash';
|
|
8
|
+
export { sha256Hash } from './sha256Hash';
|
|
9
|
+
export { strToNumberHash } from './strToNumberHash';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export{decodeBase64}from"./decodeBase64";export{decrypt}from"./decrypt";export{encodeBase64}from"./encodeBase64";export{encrypt}from"./encrypt";export{md5Hash}from"./md5Hash";export{objectId}from"./objectId";export{sha1Hash}from"./sha1Hash";export{sha256Hash}from"./sha256Hash";export{strToNumberHash}from"./strToNumberHash";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{createHash as t}from"node:crypto";export function md5Hash(e){return t("md5").update(e).digest("hex")}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{createHash as t}from"node:crypto";export function sha1Hash(e){return t("sha1").update(e).digest("hex")}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{createHash as t}from"node:crypto";export function sha256Hash(e){return t("sha256").update(e).digest("hex")}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{mkdir as r}from"node:fs/promises";import{isFileExists as e}from"./isFileExists";export async function createDirectory(i,o=!0){try{await e(i)||await r(i,{recursive:o})}catch(r){if(r instanceof Error)throw new Error(r.message)}}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{open as r}from"node:fs/promises";import{createFile as e}from"./createFile";export async function createFileWithDummy(t,i){if(!i||i<0)throw new Error("Size is required");try{if(0===i)return await e(t),!0;const a=await r(t,"w");return await a.write(Buffer.alloc(1),0,1,i-1),await a.close(),!0}catch(r){return!1}}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{readdir as t}from"node:fs/promises";import{join as e}from"path";import{deleteFile as o}from"./deleteFile";export async function deleteAllFileFromDirectory(r){let i=[];try{i=await t(r)}catch{}const l=i.length;for(let t=0;t<l;t+=1)await o(e(r,i[t]))}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{createHash as o}from"node:crypto";import{createReadStream as r}from"node:fs";export async function getFileHash(e,n="md5"){return new Promise(((t,d)=>{if(!e)return void d(new Error("Invalid path"));const i=o(n),a=r(e);a.on("error",(o=>{d(o)})),a.on("data",(o=>{i.update(o)})),a.on("end",(()=>{t(i.digest("hex"))}))}))}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { FileInfo } from '
|
|
1
|
+
import { FileInfo } from '../../_types/global';
|
|
2
2
|
export declare function getFileInfo(filePath: string): Promise<FileInfo>;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{stat as e}from"node:fs/promises";import{dirname as i,resolve as t}from"path";import{getFileExtension as r}from"./getFileExtension";import{getFileSize as o}from"./getFileSize";import{getFileName as s}from"./getFileName";export async function getFileInfo(m){const n=e=>Math.floor(new Date(e).getTime()/1e3);try{const a=await e(m);return{success:!0,isDirectory:a.isDirectory(),ext:r(m),size:a.size,sizeHumanized:o(a.size),name:s(m),dirname:i(m),path:t(m),created:n(a.ctime),modified:n(a.mtime)}}catch(e){if(e instanceof Error)throw new Error(e.message)}return{success:!1,isDirectory:!1,ext:null,size:0,sizeHumanized:"0 Bytes",name:"unknown",dirname:i(m),path:m,created:-1,modified:-1}}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{posix as t}from"path";import{toPosixFilePath as e}from"./toPosixFilePath";export function getFilePathLevel(o){return o?"/"===o?1:e(o.replace(/\\+$/,"")).split(t.sep).length:-1}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import type { PositiveNumber } from '
|
|
1
|
+
import type { PositiveNumber } from '../../_types/global';
|
|
2
2
|
export declare function getFileSize<N extends number>(bytes: PositiveNumber<N>, decimals?: number): string;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{toValidFilePath as t}from"./toValidFilePath";export function getParentFilePath(e,o){const i=e.split(o?"\\":"/");let n;return i.pop(),n=1===i.length?o?"C:\\":"/":i.join(o?"\\":"/"),t(n,o)}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
export { createDirectory } from './createDirectory';
|
|
2
|
+
export { createFile } from './createFile';
|
|
3
|
+
export { createFileWithDummy } from './createFileWithDummy';
|
|
4
|
+
export { deleteAllFileFromDirectory } from './deleteAllFileFromDirectory';
|
|
5
|
+
export { deleteFile } from './deleteFile';
|
|
6
|
+
export { getFileExtension } from './getFileExtension';
|
|
7
|
+
export { getFileHash } from './getFileHash';
|
|
8
|
+
export { getFileInfo } from './getFileInfo';
|
|
9
|
+
export { getFileName } from './getFileName';
|
|
10
|
+
export { getFilePathLevel } from './getFilePathLevel';
|
|
11
|
+
export { getFileSize } from './getFileSize';
|
|
12
|
+
export { getParentFilePath } from './getParentFilePath';
|
|
13
|
+
export { headFile } from './headFile';
|
|
14
|
+
export { isFileExists } from './isFileExists';
|
|
15
|
+
export { isFileHidden } from './isFileHidden';
|
|
16
|
+
export { isValidFileName } from './isValidFileName';
|
|
17
|
+
export { joinFilePath } from './joinFilePath';
|
|
18
|
+
export { moveFile } from './moveFile';
|
|
19
|
+
export { normalizeFile } from './normalizeFile';
|
|
20
|
+
export { tailFile } from './tailFile';
|
|
21
|
+
export { toPosixFilePath } from './toPosixFilePath';
|
|
22
|
+
export { toValidFilePath } from './toValidFilePath';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export{createDirectory}from"./createDirectory";export{createFile}from"./createFile";export{createFileWithDummy}from"./createFileWithDummy";export{deleteAllFileFromDirectory}from"./deleteAllFileFromDirectory";export{deleteFile}from"./deleteFile";export{getFileExtension}from"./getFileExtension";export{getFileHash}from"./getFileHash";export{getFileInfo}from"./getFileInfo";export{getFileName}from"./getFileName";export{getFilePathLevel}from"./getFilePathLevel";export{getFileSize}from"./getFileSize";export{getParentFilePath}from"./getParentFilePath";export{headFile}from"./headFile";export{isFileExists}from"./isFileExists";export{isFileHidden}from"./isFileHidden";export{isValidFileName}from"./isValidFileName";export{joinFilePath}from"./joinFilePath";export{moveFile}from"./moveFile";export{normalizeFile}from"./normalizeFile";export{tailFile}from"./tailFile";export{toPosixFilePath}from"./toPosixFilePath";export{toValidFilePath}from"./toValidFilePath";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{getFileName as e}from"./getFileName";export function isValidFileName(t,i){let l;const n=e(t);return l=i?/(^\s+$)|(^\.+$)|([:/]+)/:/(^\s+$)|(^\.+$)|([<>:"/\\|?*]+)/,!l.test(n)&&n.length<=255}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{posix as o,win32 as i}from"path";import{toValidFilePath as t}from"./toValidFilePath";export function joinFilePath(r,...n){return r?t(i.join(...n),!0):t(o.join(...n),!1)}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export*from"./file/index.js";export*from"./crypto/index.js";
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "qsu",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.8.0",
|
|
4
4
|
"description": "qsu is a lightweight and simple module with a variety of built-in utility functions that you can utilize in your Node.js projects.",
|
|
5
5
|
"author": "CDGet <jooy2.contact@gmail.com>",
|
|
6
6
|
"license": "MIT",
|
package/dist/encrypt/decrypt.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{createDecipheriv as t}from"crypto";export function decrypt(r,e,f="aes-256-cbc",o=!1){if(!r||r.length<1)return"";const n=o?"base64":"hex",c=r.split(":"),i=t(f,e,Buffer.from(c.shift(),n));let u=i.update(Buffer.from(c.join(":"),n));return u=Buffer.concat([u,i.final()]),u.toString()}
|
package/dist/encrypt/encrypt.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{createCipheriv as t,randomBytes as n}from"crypto";export function encrypt(r,e,o="aes-256-cbc",c=16,f=!1){if(!r||r.length<1)return"";const i=n(c),a=t(o,e,i);let p=a.update(r);p=Buffer.concat([p,a.final()]);const u=f?"base64":"hex";return`${i.toString(u)}:${p.toString(u)}`}
|
package/dist/encrypt/index.d.ts
DELETED
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
export { decodeBase64 } from './decodeBase64.js';
|
|
2
|
-
export { decrypt } from './decrypt.js';
|
|
3
|
-
export { encodeBase64 } from './encodeBase64.js';
|
|
4
|
-
export { encrypt } from './encrypt.js';
|
|
5
|
-
export { md5Hash } from './md5Hash.js';
|
|
6
|
-
export { objectId } from './objectId.js';
|
|
7
|
-
export { sha1Hash } from './sha1Hash.js';
|
|
8
|
-
export { sha256Hash } from './sha256Hash.js';
|
|
9
|
-
export { strToNumberHash } from './strToNumberHash.js';
|
package/dist/encrypt/index.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export{decodeBase64}from"./decodeBase64.js";export{decrypt}from"./decrypt.js";export{encodeBase64}from"./encodeBase64.js";export{encrypt}from"./encrypt.js";export{md5Hash}from"./md5Hash.js";export{objectId}from"./objectId.js";export{sha1Hash}from"./sha1Hash.js";export{sha256Hash}from"./sha256Hash.js";export{strToNumberHash}from"./strToNumberHash.js";
|
package/dist/encrypt/md5Hash.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{createHash as t}from"crypto";export function md5Hash(r){return t("md5").update(r).digest("hex")}
|
package/dist/encrypt/sha1Hash.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{createHash as t}from"crypto";export function sha1Hash(r){return t("sha1").update(r).digest("hex")}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{createHash as t}from"crypto";export function sha256Hash(r){return t("sha256").update(r).digest("hex")}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{mkdir as r}from"node:fs/promises";import{isFileExists as e}from"./isFileExists.js";export async function createDirectory(i,o=!0){try{await e(i)||await r(i,{recursive:o})}catch(r){if(r instanceof Error)throw new Error(r.message)}}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{open as r}from"node:fs/promises";import{createFile as e}from"./createFile.js";export async function createFileWithDummy(t,i){if(!i||i<0)throw new Error("Size is required");try{if(0===i)return await e(t),!0;const a=await r(t,"w");return await a.write(Buffer.alloc(1),0,1,i-1),await a.close(),!0}catch(r){return!1}}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{readdir as t}from"node:fs/promises";import{join as e}from"path";import{deleteFile as o}from"./deleteFile.js";export async function deleteAllFileFromDirectory(r){let i=[];try{i=await t(r)}catch{}const l=i.length;for(let t=0;t<l;t+=1)await o(e(r,i[t]))}
|
package/dist/file/getFileHash.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{createHash as r}from"crypto";import{createReadStream as o}from"node:fs";export async function getFileHash(e,n="md5"){return new Promise(((t,i)=>{if(!e)return void i(new Error("Invalid path"));const d=r(n),a=o(e);a.on("error",(r=>{i(r)})),a.on("data",(r=>{d.update(r)})),a.on("end",(()=>{t(d.digest("hex"))}))}))}
|
package/dist/file/getFileInfo.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{stat as e}from"node:fs/promises";import{dirname as i,resolve as t}from"path";import{getFileExtension as r}from"./getFileExtension.js";import{getFileSize as o}from"./getFileSize.js";import{getFileName as s}from"./getFileName.js";export async function getFileInfo(m){const n=e=>Math.floor(new Date(e).getTime()/1e3);try{const a=await e(m);return{success:!0,isDirectory:a.isDirectory(),ext:r(m),size:a.size,sizeHumanized:o(a.size),name:s(m),dirname:i(m),path:t(m),created:n(a.ctime),modified:n(a.mtime)}}catch(e){if(e instanceof Error)throw new Error(e.message)}return{success:!1,isDirectory:!1,ext:null,size:0,sizeHumanized:"0 Bytes",name:"unknown",dirname:i(m),path:m,created:-1,modified:-1}}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{posix as t}from"path";import{toPosixFilePath as e}from"./toPosixFilePath.js";export function getFilePathLevel(o){return o?"/"===o?1:e(o.replace(/\\+$/,"")).split(t.sep).length:-1}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{toValidFilePath as t}from"./toValidFilePath.js";export function getParentFilePath(e,o){const i=e.split(o?"\\":"/");let n;return i.pop(),n=1===i.length?o?"C:\\":"/":i.join(o?"\\":"/"),t(n,o)}
|
package/dist/file/index.d.ts
DELETED
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
export { createDirectory } from './createDirectory.js';
|
|
2
|
-
export { createFile } from './createFile.js';
|
|
3
|
-
export { createFileWithDummy } from './createFileWithDummy.js';
|
|
4
|
-
export { deleteAllFileFromDirectory } from './deleteAllFileFromDirectory.js';
|
|
5
|
-
export { deleteFile } from './deleteFile.js';
|
|
6
|
-
export { getFileExtension } from './getFileExtension.js';
|
|
7
|
-
export { getFileHash } from './getFileHash.js';
|
|
8
|
-
export { getFileInfo } from './getFileInfo.js';
|
|
9
|
-
export { getFileName } from './getFileName.js';
|
|
10
|
-
export { getFilePathLevel } from './getFilePathLevel.js';
|
|
11
|
-
export { getFileSize } from './getFileSize.js';
|
|
12
|
-
export { getParentFilePath } from './getParentFilePath.js';
|
|
13
|
-
export { headFile } from './headFile.js';
|
|
14
|
-
export { isFileExists } from './isFileExists.js';
|
|
15
|
-
export { isFileHidden } from './isFileHidden.js';
|
|
16
|
-
export { isValidFileName } from './isValidFileName.js';
|
|
17
|
-
export { joinFilePath } from './joinFilePath.js';
|
|
18
|
-
export { moveFile } from './moveFile.js';
|
|
19
|
-
export { normalizeFile } from './normalizeFile.js';
|
|
20
|
-
export { tailFile } from './tailFile.js';
|
|
21
|
-
export { toPosixFilePath } from './toPosixFilePath.js';
|
|
22
|
-
export { toValidFilePath } from './toValidFilePath.js';
|
package/dist/file/index.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export{createDirectory}from"./createDirectory.js";export{createFile}from"./createFile.js";export{createFileWithDummy}from"./createFileWithDummy.js";export{deleteAllFileFromDirectory}from"./deleteAllFileFromDirectory.js";export{deleteFile}from"./deleteFile.js";export{getFileExtension}from"./getFileExtension.js";export{getFileHash}from"./getFileHash.js";export{getFileInfo}from"./getFileInfo.js";export{getFileName}from"./getFileName.js";export{getFilePathLevel}from"./getFilePathLevel.js";export{getFileSize}from"./getFileSize.js";export{getParentFilePath}from"./getParentFilePath.js";export{headFile}from"./headFile.js";export{isFileExists}from"./isFileExists.js";export{isFileHidden}from"./isFileHidden.js";export{isValidFileName}from"./isValidFileName.js";export{joinFilePath}from"./joinFilePath.js";export{moveFile}from"./moveFile.js";export{normalizeFile}from"./normalizeFile.js";export{tailFile}from"./tailFile.js";export{toPosixFilePath}from"./toPosixFilePath.js";export{toValidFilePath}from"./toValidFilePath.js";
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{getFileName as e}from"./getFileName.js";export function isValidFileName(t,i){let s;const l=e(t);return s=i?/(^\s+$)|(^\.+$)|([:/]+)/:/(^\s+$)|(^\.+$)|([<>:"/\\|?*]+)/,!s.test(l)&&l.length<=255}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{posix as o,win32 as i}from"path";import{toValidFilePath as t}from"./toValidFilePath.js";export function joinFilePath(r,...n){return r?t(i.join(...n),!0):t(o.join(...n),!1)}
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|