fisrt
This commit is contained in:
commit
96be70c976
123
README.md
Normal file
123
README.md
Normal file
@ -0,0 +1,123 @@
|
||||
# 🗄️ EasySQL
|
||||
|
||||
<div align="center">
|
||||
|
||||

|
||||

|
||||

|
||||

|
||||
|
||||
**现代化多数据库管理工具**
|
||||
|
||||
</div>
|
||||
|
||||
---
|
||||
|
||||
## ✨ 特性
|
||||
|
||||
- 🎨 **精美 UI** - 基于 React + Tailwind CSS,深空科技风格
|
||||
- ⚡ **高性能** - Electron + Vite,启动快速
|
||||
- 🔌 **多数据库** - 支持 MySQL、PostgreSQL、SQLite、MongoDB、Redis 等
|
||||
- 🔐 **SSH 隧道** - 安全连接远程数据库
|
||||
- 📝 **SQL 编辑器** - 语法高亮、快捷执行
|
||||
|
||||
## 🗃️ 支持的数据库
|
||||
|
||||
| 数据库 | 状态 |
|
||||
|--------|------|
|
||||
| 🐬 MySQL | ✅ |
|
||||
| 🐘 PostgreSQL | ✅ |
|
||||
| 💾 SQLite | ✅ |
|
||||
| 🍃 MongoDB | ✅ |
|
||||
| ⚡ Redis | ✅ |
|
||||
| 📊 SQL Server | 🔜 |
|
||||
| 🔶 Oracle | 🔜 |
|
||||
| 🦭 MariaDB | ✅ |
|
||||
| ❄️ Snowflake | 🔜 |
|
||||
|
||||
## 🚀 快速开始
|
||||
|
||||
### 环境要求
|
||||
|
||||
- Node.js 18+
|
||||
- npm 或 yarn
|
||||
|
||||
### 安装
|
||||
|
||||
```bash
|
||||
# 克隆项目
|
||||
git clone https://github.com/your-repo/easysql.git
|
||||
cd easysql
|
||||
|
||||
# 安装依赖
|
||||
npm install
|
||||
|
||||
# 开发模式运行
|
||||
npm run dev
|
||||
|
||||
# 构建应用
|
||||
npm run build
|
||||
```
|
||||
|
||||
## 📸 界面预览
|
||||
|
||||
```
|
||||
┌─────────────────────────────────────────────────────────────────┐
|
||||
│ 🗄️ EasySQL ─ □ ✕ │
|
||||
├────────────────┬────────────────────────────────────────────────┤
|
||||
│ │ 🏠 欢迎 │ 📝 MySQL │ 📝 查询2 │ + │
|
||||
│ + 新建连接 │ ┌──────────────────────────────────────────┐ │
|
||||
│ │ │ │ │
|
||||
│ ─ 连接 ─────── │ │ 🗄️ EasySQL │ │
|
||||
│ │ │ 现代化多数据库管理工具 │ │
|
||||
│ 🐬 MySQL本地 │ │ │ │
|
||||
│ 🐘 PostgreSQL │ │ [ 开始查询 ] │ │
|
||||
│ 🍃 MongoDB │ │ │ │
|
||||
│ │ │ 🐬 🐘 💾 🍃 ⚡ 📊 │ │
|
||||
│ ─ 数据库 ───── │ │ MySQL PG SQLite Mongo Redis ... │ │
|
||||
│ │ └──────────────────────────────────────────┘ │
|
||||
│ 🗃️ mydb │ │
|
||||
│ 🗃️ testdb │ │
|
||||
│ │ │
|
||||
├────────────────┴────────────────────────────────────────────────┤
|
||||
│ ● 就绪 EasySQL v1.0 │
|
||||
└─────────────────────────────────────────────────────────────────┘
|
||||
```
|
||||
|
||||
## 🛠️ 技术栈
|
||||
|
||||
- **框架**: Electron 28 + React 18
|
||||
- **语言**: TypeScript 5
|
||||
- **样式**: Tailwind CSS 3
|
||||
- **构建**: Vite 5
|
||||
- **数据库驱动**: mysql2, pg, better-sqlite3, mongodb, redis
|
||||
|
||||
## 📁 项目结构
|
||||
|
||||
```
|
||||
easysql/
|
||||
├── electron/ # Electron 主进程
|
||||
│ ├── main.ts # 主进程入口
|
||||
│ ├── preload.ts # 预加载脚本
|
||||
│ └── database.ts # 数据库连接管理
|
||||
├── src/ # React 前端
|
||||
│ ├── components/ # UI 组件
|
||||
│ ├── App.tsx # 主应用
|
||||
│ ├── types.ts # 类型定义
|
||||
│ └── index.css # 全局样式
|
||||
├── index.html
|
||||
├── package.json
|
||||
├── tailwind.config.js
|
||||
├── tsconfig.json
|
||||
└── vite.config.ts
|
||||
```
|
||||
|
||||
## 📄 License
|
||||
|
||||
MIT
|
||||
|
||||
---
|
||||
|
||||
<div align="center">
|
||||
Made with ❤️ using Electron + React
|
||||
</div>
|
||||
532
dist/main/main.js
vendored
Normal file
532
dist/main/main.js
vendored
Normal file
@ -0,0 +1,532 @@
|
||||
"use strict";
|
||||
const electron = require("electron");
|
||||
const path = require("path");
|
||||
let mainWindow = null;
|
||||
let dbConnections = /* @__PURE__ */ new Map();
|
||||
const isDev = !electron.app.isPackaged;
|
||||
const gotTheLock = electron.app.requestSingleInstanceLock();
|
||||
if (!gotTheLock) {
|
||||
electron.app.quit();
|
||||
} else {
|
||||
electron.app.on("second-instance", () => {
|
||||
if (mainWindow) {
|
||||
if (mainWindow.isMinimized()) mainWindow.restore();
|
||||
mainWindow.focus();
|
||||
}
|
||||
});
|
||||
}
|
||||
function createWindow() {
|
||||
mainWindow = new electron.BrowserWindow({
|
||||
width: 1400,
|
||||
height: 900,
|
||||
minWidth: 1100,
|
||||
minHeight: 700,
|
||||
frame: false,
|
||||
backgroundColor: "#1f1f1f",
|
||||
webPreferences: {
|
||||
preload: path.join(__dirname, "../preload/preload.js"),
|
||||
contextIsolation: true,
|
||||
nodeIntegration: false
|
||||
}
|
||||
});
|
||||
if (isDev) {
|
||||
mainWindow.loadURL("http://localhost:5173");
|
||||
mainWindow.webContents.openDevTools();
|
||||
} else {
|
||||
mainWindow.loadFile(path.join(__dirname, "../renderer/index.html"));
|
||||
}
|
||||
}
|
||||
electron.app.whenReady().then(createWindow);
|
||||
electron.app.on("window-all-closed", () => {
|
||||
if (process.platform !== "darwin") electron.app.quit();
|
||||
});
|
||||
electron.app.on("activate", () => {
|
||||
if (electron.BrowserWindow.getAllWindows().length === 0) createWindow();
|
||||
});
|
||||
electron.ipcMain.handle("window:minimize", () => mainWindow == null ? void 0 : mainWindow.minimize());
|
||||
electron.ipcMain.handle("window:maximize", () => {
|
||||
(mainWindow == null ? void 0 : mainWindow.isMaximized()) ? mainWindow.unmaximize() : mainWindow == null ? void 0 : mainWindow.maximize();
|
||||
});
|
||||
electron.ipcMain.handle("window:close", () => mainWindow == null ? void 0 : mainWindow.close());
|
||||
function resolveHost(host) {
|
||||
return host === "localhost" ? "127.0.0.1" : host;
|
||||
}
|
||||
electron.ipcMain.handle("db:test", async (_, config) => {
|
||||
const host = resolveHost(config.host);
|
||||
try {
|
||||
if (config.type === "mysql" || config.type === "mariadb") {
|
||||
const mysql = require("mysql2/promise");
|
||||
const conn = await mysql.createConnection({
|
||||
host,
|
||||
port: config.port,
|
||||
user: config.username,
|
||||
password: config.password,
|
||||
database: config.database || void 0,
|
||||
connectTimeout: 1e4
|
||||
});
|
||||
await conn.ping();
|
||||
await conn.end();
|
||||
return { success: true, message: "连接成功" };
|
||||
} else if (config.type === "postgres") {
|
||||
const { Client } = require("pg");
|
||||
const client = new Client({
|
||||
host,
|
||||
port: config.port,
|
||||
user: config.username,
|
||||
password: config.password,
|
||||
database: config.database || "postgres",
|
||||
connectionTimeoutMillis: 1e4
|
||||
});
|
||||
await client.connect();
|
||||
await client.end();
|
||||
return { success: true, message: "连接成功" };
|
||||
} else if (config.type === "mongodb") {
|
||||
const { MongoClient } = require("mongodb");
|
||||
const uri = config.username ? `mongodb://${config.username}:${config.password}@${host}:${config.port}/${config.database || "admin"}` : `mongodb://${host}:${config.port}/${config.database || "admin"}`;
|
||||
const client = new MongoClient(uri, { serverSelectionTimeoutMS: 1e4 });
|
||||
await client.connect();
|
||||
await client.close();
|
||||
return { success: true, message: "连接成功" };
|
||||
} else if (config.type === "redis") {
|
||||
const Redis = require("ioredis");
|
||||
const client = new Redis({
|
||||
host,
|
||||
port: config.port,
|
||||
password: config.password || void 0,
|
||||
connectTimeout: 1e4,
|
||||
lazyConnect: true
|
||||
});
|
||||
await client.connect();
|
||||
await client.ping();
|
||||
await client.quit();
|
||||
return { success: true, message: "连接成功" };
|
||||
} else if (config.type === "sqlserver") {
|
||||
const sql = require("mssql");
|
||||
const poolConfig = {
|
||||
server: host,
|
||||
port: config.port,
|
||||
user: config.username,
|
||||
password: config.password,
|
||||
database: config.database || "master",
|
||||
options: { encrypt: false, trustServerCertificate: true },
|
||||
connectionTimeout: 1e4
|
||||
};
|
||||
const pool = await sql.connect(poolConfig);
|
||||
await pool.close();
|
||||
return { success: true, message: "连接成功" };
|
||||
}
|
||||
return { success: false, message: `暂不支持 ${config.type}` };
|
||||
} catch (err) {
|
||||
return { success: false, message: err.message };
|
||||
}
|
||||
});
|
||||
electron.ipcMain.handle("db:connect", async (_, config) => {
|
||||
const host = resolveHost(config.host);
|
||||
try {
|
||||
if (config.type === "mysql" || config.type === "mariadb") {
|
||||
const mysql = require("mysql2/promise");
|
||||
const conn = await mysql.createConnection({
|
||||
host,
|
||||
port: config.port,
|
||||
user: config.username,
|
||||
password: config.password,
|
||||
database: config.database || void 0
|
||||
});
|
||||
dbConnections.set(config.id, { type: "mysql", conn });
|
||||
return { success: true, message: "连接成功" };
|
||||
} else if (config.type === "postgres") {
|
||||
const { Client } = require("pg");
|
||||
const client = new Client({
|
||||
host,
|
||||
port: config.port,
|
||||
user: config.username,
|
||||
password: config.password,
|
||||
database: config.database || "postgres"
|
||||
});
|
||||
await client.connect();
|
||||
dbConnections.set(config.id, { type: "postgres", conn: client });
|
||||
return { success: true, message: "连接成功" };
|
||||
} else if (config.type === "mongodb") {
|
||||
const { MongoClient } = require("mongodb");
|
||||
const uri = config.username ? `mongodb://${config.username}:${config.password}@${host}:${config.port}/${config.database || "admin"}` : `mongodb://${host}:${config.port}/${config.database || "admin"}`;
|
||||
const client = new MongoClient(uri);
|
||||
await client.connect();
|
||||
dbConnections.set(config.id, { type: "mongodb", conn: client });
|
||||
return { success: true, message: "连接成功" };
|
||||
} else if (config.type === "redis") {
|
||||
const Redis = require("ioredis");
|
||||
const client = new Redis({
|
||||
host,
|
||||
port: config.port,
|
||||
password: config.password || void 0,
|
||||
lazyConnect: true
|
||||
});
|
||||
await client.connect();
|
||||
dbConnections.set(config.id, { type: "redis", conn: client });
|
||||
return { success: true, message: "连接成功" };
|
||||
} else if (config.type === "sqlserver") {
|
||||
const sql = require("mssql");
|
||||
const poolConfig = {
|
||||
server: host,
|
||||
port: config.port,
|
||||
user: config.username,
|
||||
password: config.password,
|
||||
database: config.database || "master",
|
||||
options: { encrypt: false, trustServerCertificate: true }
|
||||
};
|
||||
const pool = await sql.connect(poolConfig);
|
||||
dbConnections.set(config.id, { type: "sqlserver", conn: pool });
|
||||
return { success: true, message: "连接成功" };
|
||||
}
|
||||
return { success: false, message: `暂不支持 ${config.type}` };
|
||||
} catch (err) {
|
||||
return { success: false, message: err.message };
|
||||
}
|
||||
});
|
||||
electron.ipcMain.handle("db:disconnect", async (_, id) => {
|
||||
const db = dbConnections.get(id);
|
||||
if (db) {
|
||||
try {
|
||||
await db.conn.end();
|
||||
} catch {
|
||||
}
|
||||
dbConnections.delete(id);
|
||||
}
|
||||
});
|
||||
electron.ipcMain.handle("db:query", async (_, id, sql) => {
|
||||
var _a;
|
||||
const db = dbConnections.get(id);
|
||||
if (!db) return { columns: [], rows: [], error: "未连接" };
|
||||
try {
|
||||
if (db.type === "mysql") {
|
||||
const [rows, fields] = await db.conn.query(sql);
|
||||
const columns = (fields == null ? void 0 : fields.map((f) => f.name)) || [];
|
||||
return { columns, rows: Array.isArray(rows) ? rows : [] };
|
||||
} else if (db.type === "postgres") {
|
||||
const result = await db.conn.query(sql);
|
||||
const columns = ((_a = result.fields) == null ? void 0 : _a.map((f) => f.name)) || [];
|
||||
return { columns, rows: result.rows };
|
||||
}
|
||||
return { columns: [], rows: [], error: "不支持的类型" };
|
||||
} catch (err) {
|
||||
return { columns: [], rows: [], error: err.message };
|
||||
}
|
||||
});
|
||||
electron.ipcMain.handle("db:getDatabases", async (_, id) => {
|
||||
const db = dbConnections.get(id);
|
||||
if (!db) return [];
|
||||
try {
|
||||
if (db.type === "mysql") {
|
||||
const [rows] = await db.conn.query("SHOW DATABASES");
|
||||
return rows.map((r) => r.Database);
|
||||
} else if (db.type === "postgres") {
|
||||
const result = await db.conn.query("SELECT datname FROM pg_database WHERE datistemplate = false");
|
||||
return result.rows.map((r) => r.datname);
|
||||
}
|
||||
} catch {
|
||||
}
|
||||
return [];
|
||||
});
|
||||
electron.ipcMain.handle("db:getTables", async (_, id, database) => {
|
||||
const db = dbConnections.get(id);
|
||||
if (!db) return [];
|
||||
try {
|
||||
if (db.type === "mysql") {
|
||||
await db.conn.query(`USE \`${database}\``);
|
||||
const [rows] = await db.conn.query(`
|
||||
SELECT TABLE_NAME as name, TABLE_ROWS as \`rows\`
|
||||
FROM information_schema.TABLES
|
||||
WHERE TABLE_SCHEMA = ?
|
||||
`, [database]);
|
||||
return rows.map((r) => ({ name: r.name, rows: r.rows || 0 }));
|
||||
} else if (db.type === "postgres") {
|
||||
const result = await db.conn.query(`
|
||||
SELECT tablename as name,
|
||||
(SELECT reltuples::bigint FROM pg_class WHERE relname = tablename) as rows
|
||||
FROM pg_tables WHERE schemaname = 'public'
|
||||
`);
|
||||
return result.rows.map((r) => ({ name: r.name, rows: parseInt(r.rows) || 0 }));
|
||||
}
|
||||
} catch (err) {
|
||||
console.error("getTables error:", err);
|
||||
}
|
||||
return [];
|
||||
});
|
||||
electron.ipcMain.handle("db:getColumns", async (_, id, database, table) => {
|
||||
const db = dbConnections.get(id);
|
||||
if (!db) return [];
|
||||
try {
|
||||
if (db.type === "mysql") {
|
||||
const [rows] = await db.conn.query(`
|
||||
SELECT COLUMN_NAME as name, DATA_TYPE as type, IS_NULLABLE as nullable,
|
||||
COLUMN_KEY as \`key\`, COLUMN_COMMENT as comment
|
||||
FROM information_schema.COLUMNS
|
||||
WHERE TABLE_SCHEMA = ? AND TABLE_NAME = ?
|
||||
ORDER BY ORDINAL_POSITION
|
||||
`, [database, table]);
|
||||
return rows.map((r) => ({
|
||||
name: r.name,
|
||||
type: r.type,
|
||||
nullable: r.nullable === "YES",
|
||||
key: r.key || void 0,
|
||||
comment: r.comment || void 0
|
||||
}));
|
||||
} else if (db.type === "postgres") {
|
||||
const result = await db.conn.query(`
|
||||
SELECT c.column_name as name, c.data_type as type, c.is_nullable as nullable,
|
||||
pgd.description as comment
|
||||
FROM information_schema.columns c
|
||||
LEFT JOIN pg_catalog.pg_statio_all_tables st ON c.table_schema = st.schemaname AND c.table_name = st.relname
|
||||
LEFT JOIN pg_catalog.pg_description pgd ON pgd.objoid = st.relid AND pgd.objsubid = c.ordinal_position
|
||||
WHERE c.table_schema = 'public' AND c.table_name = $1
|
||||
ORDER BY c.ordinal_position
|
||||
`, [table]);
|
||||
return result.rows.map((r) => ({
|
||||
name: r.name,
|
||||
type: r.type,
|
||||
nullable: r.nullable === "YES",
|
||||
comment: r.comment || void 0
|
||||
}));
|
||||
}
|
||||
} catch (err) {
|
||||
console.error("getColumns error:", err);
|
||||
}
|
||||
return [];
|
||||
});
|
||||
electron.ipcMain.handle("db:getTableData", async (_, id, database, table, page = 1, pageSize = 100) => {
|
||||
var _a, _b;
|
||||
const db = dbConnections.get(id);
|
||||
if (!db) return { data: [], total: 0 };
|
||||
try {
|
||||
const offset = (page - 1) * pageSize;
|
||||
if (db.type === "mysql") {
|
||||
const [countResult] = await db.conn.query(`SELECT COUNT(*) as total FROM \`${database}\`.\`${table}\``);
|
||||
const total = ((_a = countResult[0]) == null ? void 0 : _a.total) || 0;
|
||||
const [rows] = await db.conn.query(`SELECT * FROM \`${database}\`.\`${table}\` LIMIT ? OFFSET ?`, [pageSize, offset]);
|
||||
return { data: rows, total };
|
||||
} else if (db.type === "postgres") {
|
||||
const countResult = await db.conn.query(`SELECT COUNT(*) as total FROM "${table}"`);
|
||||
const total = parseInt((_b = countResult.rows[0]) == null ? void 0 : _b.total) || 0;
|
||||
const result = await db.conn.query(`SELECT * FROM "${table}" LIMIT $1 OFFSET $2`, [pageSize, offset]);
|
||||
return { data: result.rows, total };
|
||||
}
|
||||
} catch (err) {
|
||||
console.error("getTableData error:", err);
|
||||
}
|
||||
return { data: [], total: 0 };
|
||||
});
|
||||
const fs = require("fs");
|
||||
const configPath = path.join(electron.app.getPath("userData"), "connections.json");
|
||||
electron.ipcMain.handle("config:save", async (_, connections) => {
|
||||
fs.writeFileSync(configPath, JSON.stringify(connections, null, 2));
|
||||
});
|
||||
electron.ipcMain.handle("config:load", async () => {
|
||||
try {
|
||||
if (fs.existsSync(configPath)) {
|
||||
return JSON.parse(fs.readFileSync(configPath, "utf-8"));
|
||||
}
|
||||
} catch {
|
||||
}
|
||||
return [];
|
||||
});
|
||||
electron.ipcMain.handle("file:open", async () => {
|
||||
const result = await electron.dialog.showOpenDialog(mainWindow, {
|
||||
title: "打开 SQL 文件",
|
||||
filters: [
|
||||
{ name: "SQL 文件", extensions: ["sql"] },
|
||||
{ name: "所有文件", extensions: ["*"] }
|
||||
],
|
||||
properties: ["openFile"]
|
||||
});
|
||||
if (result.canceled || result.filePaths.length === 0) {
|
||||
return null;
|
||||
}
|
||||
const filePath = result.filePaths[0];
|
||||
try {
|
||||
const content = fs.readFileSync(filePath, "utf-8");
|
||||
return { path: filePath, content, name: path.basename(filePath) };
|
||||
} catch (err) {
|
||||
return { error: err.message };
|
||||
}
|
||||
});
|
||||
electron.ipcMain.handle("file:save", async (_, filePath, content) => {
|
||||
let targetPath = filePath;
|
||||
if (!targetPath) {
|
||||
const result = await electron.dialog.showSaveDialog(mainWindow, {
|
||||
title: "保存 SQL 文件",
|
||||
defaultPath: "query.sql",
|
||||
filters: [
|
||||
{ name: "SQL 文件", extensions: ["sql"] },
|
||||
{ name: "所有文件", extensions: ["*"] }
|
||||
]
|
||||
});
|
||||
if (result.canceled || !result.filePath) {
|
||||
return null;
|
||||
}
|
||||
targetPath = result.filePath;
|
||||
}
|
||||
try {
|
||||
fs.writeFileSync(targetPath, content, "utf-8");
|
||||
return { path: targetPath, name: path.basename(targetPath) };
|
||||
} catch (err) {
|
||||
return { error: err.message };
|
||||
}
|
||||
});
|
||||
electron.ipcMain.handle("db:backup", async (_, id, database) => {
|
||||
const db = dbConnections.get(id);
|
||||
if (!db) return { error: "未连接数据库" };
|
||||
const result = await electron.dialog.showSaveDialog(mainWindow, {
|
||||
title: "备份数据库",
|
||||
defaultPath: `${database}_backup_${(/* @__PURE__ */ new Date()).toISOString().slice(0, 10)}.sql`,
|
||||
filters: [
|
||||
{ name: "SQL 文件", extensions: ["sql"] },
|
||||
{ name: "所有文件", extensions: ["*"] }
|
||||
]
|
||||
});
|
||||
if (result.canceled || !result.filePath) {
|
||||
return { cancelled: true };
|
||||
}
|
||||
try {
|
||||
let sqlContent = "";
|
||||
sqlContent += `-- Database Backup: ${database}
|
||||
`;
|
||||
sqlContent += `-- Generated: ${(/* @__PURE__ */ new Date()).toLocaleString()}
|
||||
`;
|
||||
sqlContent += `-- Tool: EasySQL
|
||||
|
||||
`;
|
||||
if (db.type === "mysql" || db.type === "mariadb") {
|
||||
await db.conn.query(`USE \`${database}\``);
|
||||
const [tables] = await db.conn.query(`SHOW TABLES`);
|
||||
const tableKey = `Tables_in_${database}`;
|
||||
sqlContent += `SET FOREIGN_KEY_CHECKS = 0;
|
||||
|
||||
`;
|
||||
for (const tableRow of tables) {
|
||||
const tableName = tableRow[tableKey];
|
||||
const [createResult] = await db.conn.query(`SHOW CREATE TABLE \`${tableName}\``);
|
||||
const createStatement = createResult[0]["Create Table"];
|
||||
sqlContent += `-- Table: ${tableName}
|
||||
`;
|
||||
sqlContent += `DROP TABLE IF EXISTS \`${tableName}\`;
|
||||
`;
|
||||
sqlContent += `${createStatement};
|
||||
|
||||
`;
|
||||
const [rows] = await db.conn.query(`SELECT * FROM \`${tableName}\``);
|
||||
if (rows.length > 0) {
|
||||
const columns = Object.keys(rows[0]);
|
||||
for (const row of rows) {
|
||||
const values = columns.map((col) => {
|
||||
const val = row[col];
|
||||
if (val === null) return "NULL";
|
||||
if (typeof val === "number") return val;
|
||||
if (val instanceof Date) return `'${val.toISOString().slice(0, 19).replace("T", " ")}'`;
|
||||
return `'${String(val).replace(/'/g, "''").replace(/\\/g, "\\\\")}'`;
|
||||
}).join(", ");
|
||||
sqlContent += `INSERT INTO \`${tableName}\` (\`${columns.join("`, `")}\`) VALUES (${values});
|
||||
`;
|
||||
}
|
||||
sqlContent += "\n";
|
||||
}
|
||||
}
|
||||
sqlContent += `SET FOREIGN_KEY_CHECKS = 1;
|
||||
`;
|
||||
} else if (db.type === "postgres") {
|
||||
const tablesResult = await db.conn.query(`
|
||||
SELECT tablename FROM pg_tables WHERE schemaname = 'public'
|
||||
`);
|
||||
for (const tableRow of tablesResult.rows) {
|
||||
const tableName = tableRow.tablename;
|
||||
const dataResult = await db.conn.query(`SELECT * FROM "${tableName}"`);
|
||||
if (dataResult.rows.length > 0) {
|
||||
const columns = Object.keys(dataResult.rows[0]);
|
||||
sqlContent += `-- Table: ${tableName}
|
||||
`;
|
||||
for (const row of dataResult.rows) {
|
||||
const values = columns.map((col) => {
|
||||
const val = row[col];
|
||||
if (val === null) return "NULL";
|
||||
if (typeof val === "number") return val;
|
||||
if (val instanceof Date) return `'${val.toISOString().slice(0, 19).replace("T", " ")}'`;
|
||||
return `'${String(val).replace(/'/g, "''")}'`;
|
||||
}).join(", ");
|
||||
sqlContent += `INSERT INTO "${tableName}" ("${columns.join('", "')}") VALUES (${values});
|
||||
`;
|
||||
}
|
||||
sqlContent += "\n";
|
||||
}
|
||||
}
|
||||
}
|
||||
fs.writeFileSync(result.filePath, sqlContent, "utf-8");
|
||||
return { success: true, path: result.filePath };
|
||||
} catch (err) {
|
||||
return { error: err.message };
|
||||
}
|
||||
});
|
||||
electron.ipcMain.handle("db:exportTable", async (_, id, database, tableName, format) => {
|
||||
const db = dbConnections.get(id);
|
||||
if (!db) return { error: "未连接数据库" };
|
||||
const ext = format === "excel" ? "xlsx" : format;
|
||||
const result = await electron.dialog.showSaveDialog(mainWindow, {
|
||||
title: `导出表 ${tableName}`,
|
||||
defaultPath: `${tableName}_${(/* @__PURE__ */ new Date()).toISOString().slice(0, 10)}.${ext}`,
|
||||
filters: [
|
||||
{ name: format === "excel" ? "Excel 文件" : format === "sql" ? "SQL 文件" : "CSV 文件", extensions: [ext] },
|
||||
{ name: "所有文件", extensions: ["*"] }
|
||||
]
|
||||
});
|
||||
if (result.canceled || !result.filePath) {
|
||||
return { cancelled: true };
|
||||
}
|
||||
try {
|
||||
let rows = [];
|
||||
let columns = [];
|
||||
if (db.type === "mysql" || db.type === "mariadb") {
|
||||
await db.conn.query(`USE \`${database}\``);
|
||||
const [data] = await db.conn.query(`SELECT * FROM \`${tableName}\``);
|
||||
rows = data;
|
||||
if (rows.length > 0) columns = Object.keys(rows[0]);
|
||||
} else if (db.type === "postgres") {
|
||||
const data = await db.conn.query(`SELECT * FROM "${tableName}"`);
|
||||
rows = data.rows;
|
||||
if (rows.length > 0) columns = Object.keys(rows[0]);
|
||||
}
|
||||
if (format === "sql") {
|
||||
let content = `-- Table: ${tableName}
|
||||
`;
|
||||
content += `-- Exported: ${(/* @__PURE__ */ new Date()).toLocaleString()}
|
||||
|
||||
`;
|
||||
for (const row of rows) {
|
||||
const values = columns.map((col) => {
|
||||
const val = row[col];
|
||||
if (val === null) return "NULL";
|
||||
if (typeof val === "number") return val;
|
||||
return `'${String(val).replace(/'/g, "''")}'`;
|
||||
}).join(", ");
|
||||
content += `INSERT INTO \`${tableName}\` (\`${columns.join("`, `")}\`) VALUES (${values});
|
||||
`;
|
||||
}
|
||||
fs.writeFileSync(result.filePath, content, "utf-8");
|
||||
} else if (format === "csv") {
|
||||
let content = columns.join(",") + "\n";
|
||||
for (const row of rows) {
|
||||
const values = columns.map((col) => {
|
||||
const val = row[col];
|
||||
if (val === null) return "";
|
||||
const str = String(val);
|
||||
if (str.includes(",") || str.includes('"') || str.includes("\n")) {
|
||||
return `"${str.replace(/"/g, '""')}"`;
|
||||
}
|
||||
return str;
|
||||
});
|
||||
content += values.join(",") + "\n";
|
||||
}
|
||||
fs.writeFileSync(result.filePath, content, "utf-8");
|
||||
}
|
||||
return { success: true, path: result.filePath };
|
||||
} catch (err) {
|
||||
return { error: err.message };
|
||||
}
|
||||
});
|
||||
26
dist/preload/preload.js
vendored
Normal file
26
dist/preload/preload.js
vendored
Normal file
@ -0,0 +1,26 @@
|
||||
"use strict";
|
||||
const electron = require("electron");
|
||||
electron.contextBridge.exposeInMainWorld("electronAPI", {
|
||||
// 窗口控制
|
||||
minimize: () => electron.ipcRenderer.invoke("window:minimize"),
|
||||
maximize: () => electron.ipcRenderer.invoke("window:maximize"),
|
||||
close: () => electron.ipcRenderer.invoke("window:close"),
|
||||
// 数据库操作
|
||||
testConnection: (config) => electron.ipcRenderer.invoke("db:test", config),
|
||||
connect: (config) => electron.ipcRenderer.invoke("db:connect", config),
|
||||
disconnect: (id) => electron.ipcRenderer.invoke("db:disconnect", id),
|
||||
query: (id, sql) => electron.ipcRenderer.invoke("db:query", id, sql),
|
||||
getDatabases: (id) => electron.ipcRenderer.invoke("db:getDatabases", id),
|
||||
getTables: (id, database) => electron.ipcRenderer.invoke("db:getTables", id, database),
|
||||
getColumns: (id, database, table) => electron.ipcRenderer.invoke("db:getColumns", id, database, table),
|
||||
getTableData: (id, database, table, page, pageSize) => electron.ipcRenderer.invoke("db:getTableData", id, database, table, page, pageSize),
|
||||
// 配置存储
|
||||
saveConnections: (connections) => electron.ipcRenderer.invoke("config:save", connections),
|
||||
loadConnections: () => electron.ipcRenderer.invoke("config:load"),
|
||||
// 文件操作
|
||||
openFile: () => electron.ipcRenderer.invoke("file:open"),
|
||||
saveFile: (filePath, content) => electron.ipcRenderer.invoke("file:save", filePath, content),
|
||||
// 数据库备份与导出
|
||||
backupDatabase: (id, database) => electron.ipcRenderer.invoke("db:backup", id, database),
|
||||
exportTable: (id, database, tableName, format) => electron.ipcRenderer.invoke("db:exportTable", id, database, tableName, format)
|
||||
});
|
||||
609
electron/main.ts
Normal file
609
electron/main.ts
Normal file
@ -0,0 +1,609 @@
|
||||
import { app, BrowserWindow, ipcMain, dialog } from 'electron'
|
||||
import path from 'path'
|
||||
|
||||
let mainWindow: BrowserWindow | null = null
|
||||
let dbConnections: Map<string, any> = new Map()
|
||||
|
||||
const isDev = !app.isPackaged
|
||||
|
||||
// 单例锁 - 确保只运行一个实例
|
||||
const gotTheLock = app.requestSingleInstanceLock()
|
||||
|
||||
if (!gotTheLock) {
|
||||
// 如果获取锁失败,说明已有实例在运行,退出当前进程
|
||||
app.quit()
|
||||
} else {
|
||||
// 当第二个实例尝试启动时,聚焦到现有窗口
|
||||
app.on('second-instance', () => {
|
||||
if (mainWindow) {
|
||||
if (mainWindow.isMinimized()) mainWindow.restore()
|
||||
mainWindow.focus()
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
function createWindow() {
|
||||
mainWindow = new BrowserWindow({
|
||||
width: 1400,
|
||||
height: 900,
|
||||
minWidth: 1100,
|
||||
minHeight: 700,
|
||||
frame: false,
|
||||
backgroundColor: '#1f1f1f',
|
||||
webPreferences: {
|
||||
preload: path.join(__dirname, '../preload/preload.js'),
|
||||
contextIsolation: true,
|
||||
nodeIntegration: false,
|
||||
},
|
||||
})
|
||||
|
||||
if (isDev) {
|
||||
mainWindow.loadURL('http://localhost:5173')
|
||||
mainWindow.webContents.openDevTools()
|
||||
} else {
|
||||
mainWindow.loadFile(path.join(__dirname, '../renderer/index.html'))
|
||||
}
|
||||
}
|
||||
|
||||
app.whenReady().then(createWindow)
|
||||
|
||||
app.on('window-all-closed', () => {
|
||||
if (process.platform !== 'darwin') app.quit()
|
||||
})
|
||||
|
||||
app.on('activate', () => {
|
||||
if (BrowserWindow.getAllWindows().length === 0) createWindow()
|
||||
})
|
||||
|
||||
// 窗口控制
|
||||
ipcMain.handle('window:minimize', () => mainWindow?.minimize())
|
||||
ipcMain.handle('window:maximize', () => {
|
||||
mainWindow?.isMaximized() ? mainWindow.unmaximize() : mainWindow?.maximize()
|
||||
})
|
||||
ipcMain.handle('window:close', () => mainWindow?.close())
|
||||
|
||||
// 解析主机名 - 将 localhost 转换为 127.0.0.1 避免 IPv6 问题
|
||||
function resolveHost(host: string): string {
|
||||
return host === 'localhost' ? '127.0.0.1' : host
|
||||
}
|
||||
|
||||
// 测试连接
|
||||
ipcMain.handle('db:test', async (_, config) => {
|
||||
const host = resolveHost(config.host)
|
||||
|
||||
try {
|
||||
if (config.type === 'mysql' || config.type === 'mariadb') {
|
||||
const mysql = require('mysql2/promise')
|
||||
const conn = await mysql.createConnection({
|
||||
host,
|
||||
port: config.port,
|
||||
user: config.username,
|
||||
password: config.password,
|
||||
database: config.database || undefined,
|
||||
connectTimeout: 10000,
|
||||
})
|
||||
await conn.ping()
|
||||
await conn.end()
|
||||
return { success: true, message: '连接成功' }
|
||||
} else if (config.type === 'postgres') {
|
||||
const { Client } = require('pg')
|
||||
const client = new Client({
|
||||
host,
|
||||
port: config.port,
|
||||
user: config.username,
|
||||
password: config.password,
|
||||
database: config.database || 'postgres',
|
||||
connectionTimeoutMillis: 10000,
|
||||
})
|
||||
await client.connect()
|
||||
await client.end()
|
||||
return { success: true, message: '连接成功' }
|
||||
} else if (config.type === 'mongodb') {
|
||||
const { MongoClient } = require('mongodb')
|
||||
const uri = config.username
|
||||
? `mongodb://${config.username}:${config.password}@${host}:${config.port}/${config.database || 'admin'}`
|
||||
: `mongodb://${host}:${config.port}/${config.database || 'admin'}`
|
||||
const client = new MongoClient(uri, { serverSelectionTimeoutMS: 10000 })
|
||||
await client.connect()
|
||||
await client.close()
|
||||
return { success: true, message: '连接成功' }
|
||||
} else if (config.type === 'redis') {
|
||||
const Redis = require('ioredis')
|
||||
const client = new Redis({
|
||||
host,
|
||||
port: config.port,
|
||||
password: config.password || undefined,
|
||||
connectTimeout: 10000,
|
||||
lazyConnect: true,
|
||||
})
|
||||
await client.connect()
|
||||
await client.ping()
|
||||
await client.quit()
|
||||
return { success: true, message: '连接成功' }
|
||||
} else if (config.type === 'sqlserver') {
|
||||
const sql = require('mssql')
|
||||
const poolConfig = {
|
||||
server: host,
|
||||
port: config.port,
|
||||
user: config.username,
|
||||
password: config.password,
|
||||
database: config.database || 'master',
|
||||
options: { encrypt: false, trustServerCertificate: true },
|
||||
connectionTimeout: 10000,
|
||||
}
|
||||
const pool = await sql.connect(poolConfig)
|
||||
await pool.close()
|
||||
return { success: true, message: '连接成功' }
|
||||
}
|
||||
return { success: false, message: `暂不支持 ${config.type}` }
|
||||
} catch (err: any) {
|
||||
return { success: false, message: err.message }
|
||||
}
|
||||
})
|
||||
|
||||
// 连接
|
||||
ipcMain.handle('db:connect', async (_, config) => {
|
||||
const host = resolveHost(config.host)
|
||||
|
||||
try {
|
||||
if (config.type === 'mysql' || config.type === 'mariadb') {
|
||||
const mysql = require('mysql2/promise')
|
||||
const conn = await mysql.createConnection({
|
||||
host,
|
||||
port: config.port,
|
||||
user: config.username,
|
||||
password: config.password,
|
||||
database: config.database || undefined,
|
||||
})
|
||||
dbConnections.set(config.id, { type: 'mysql', conn })
|
||||
return { success: true, message: '连接成功' }
|
||||
} else if (config.type === 'postgres') {
|
||||
const { Client } = require('pg')
|
||||
const client = new Client({
|
||||
host,
|
||||
port: config.port,
|
||||
user: config.username,
|
||||
password: config.password,
|
||||
database: config.database || 'postgres',
|
||||
})
|
||||
await client.connect()
|
||||
dbConnections.set(config.id, { type: 'postgres', conn: client })
|
||||
return { success: true, message: '连接成功' }
|
||||
} else if (config.type === 'mongodb') {
|
||||
const { MongoClient } = require('mongodb')
|
||||
const uri = config.username
|
||||
? `mongodb://${config.username}:${config.password}@${host}:${config.port}/${config.database || 'admin'}`
|
||||
: `mongodb://${host}:${config.port}/${config.database || 'admin'}`
|
||||
const client = new MongoClient(uri)
|
||||
await client.connect()
|
||||
dbConnections.set(config.id, { type: 'mongodb', conn: client })
|
||||
return { success: true, message: '连接成功' }
|
||||
} else if (config.type === 'redis') {
|
||||
const Redis = require('ioredis')
|
||||
const client = new Redis({
|
||||
host,
|
||||
port: config.port,
|
||||
password: config.password || undefined,
|
||||
lazyConnect: true,
|
||||
})
|
||||
await client.connect()
|
||||
dbConnections.set(config.id, { type: 'redis', conn: client })
|
||||
return { success: true, message: '连接成功' }
|
||||
} else if (config.type === 'sqlserver') {
|
||||
const sql = require('mssql')
|
||||
const poolConfig = {
|
||||
server: host,
|
||||
port: config.port,
|
||||
user: config.username,
|
||||
password: config.password,
|
||||
database: config.database || 'master',
|
||||
options: { encrypt: false, trustServerCertificate: true },
|
||||
}
|
||||
const pool = await sql.connect(poolConfig)
|
||||
dbConnections.set(config.id, { type: 'sqlserver', conn: pool })
|
||||
return { success: true, message: '连接成功' }
|
||||
}
|
||||
return { success: false, message: `暂不支持 ${config.type}` }
|
||||
} catch (err: any) {
|
||||
return { success: false, message: err.message }
|
||||
}
|
||||
})
|
||||
|
||||
// 断开
|
||||
ipcMain.handle('db:disconnect', async (_, id) => {
|
||||
const db = dbConnections.get(id)
|
||||
if (db) {
|
||||
try { await db.conn.end() } catch {}
|
||||
dbConnections.delete(id)
|
||||
}
|
||||
})
|
||||
|
||||
// 查询
|
||||
ipcMain.handle('db:query', async (_, id, sql) => {
|
||||
const db = dbConnections.get(id)
|
||||
if (!db) return { columns: [], rows: [], error: '未连接' }
|
||||
|
||||
try {
|
||||
if (db.type === 'mysql') {
|
||||
const [rows, fields] = await db.conn.query(sql)
|
||||
const columns = fields?.map((f: any) => f.name) || []
|
||||
return { columns, rows: Array.isArray(rows) ? rows : [] }
|
||||
} else if (db.type === 'postgres') {
|
||||
const result = await db.conn.query(sql)
|
||||
const columns = result.fields?.map((f: any) => f.name) || []
|
||||
return { columns, rows: result.rows }
|
||||
}
|
||||
return { columns: [], rows: [], error: '不支持的类型' }
|
||||
} catch (err: any) {
|
||||
return { columns: [], rows: [], error: err.message }
|
||||
}
|
||||
})
|
||||
|
||||
// 获取数据库列表
|
||||
ipcMain.handle('db:getDatabases', async (_, id) => {
|
||||
const db = dbConnections.get(id)
|
||||
if (!db) return []
|
||||
|
||||
try {
|
||||
if (db.type === 'mysql') {
|
||||
const [rows] = await db.conn.query('SHOW DATABASES')
|
||||
return rows.map((r: any) => r.Database)
|
||||
} else if (db.type === 'postgres') {
|
||||
const result = await db.conn.query("SELECT datname FROM pg_database WHERE datistemplate = false")
|
||||
return result.rows.map((r: any) => r.datname)
|
||||
}
|
||||
} catch {}
|
||||
return []
|
||||
})
|
||||
|
||||
// 获取表列表(带行数)
|
||||
ipcMain.handle('db:getTables', async (_, id, database) => {
|
||||
const db = dbConnections.get(id)
|
||||
if (!db) return []
|
||||
|
||||
try {
|
||||
if (db.type === 'mysql') {
|
||||
// 先切换数据库
|
||||
await db.conn.query(`USE \`${database}\``)
|
||||
const [rows] = await db.conn.query(`
|
||||
SELECT TABLE_NAME as name, TABLE_ROWS as \`rows\`
|
||||
FROM information_schema.TABLES
|
||||
WHERE TABLE_SCHEMA = ?
|
||||
`, [database])
|
||||
return rows.map((r: any) => ({ name: r.name, rows: r.rows || 0 }))
|
||||
} else if (db.type === 'postgres') {
|
||||
const result = await db.conn.query(`
|
||||
SELECT tablename as name,
|
||||
(SELECT reltuples::bigint FROM pg_class WHERE relname = tablename) as rows
|
||||
FROM pg_tables WHERE schemaname = 'public'
|
||||
`)
|
||||
return result.rows.map((r: any) => ({ name: r.name, rows: parseInt(r.rows) || 0 }))
|
||||
}
|
||||
} catch (err) {
|
||||
console.error('getTables error:', err)
|
||||
}
|
||||
return []
|
||||
})
|
||||
|
||||
// 获取表字段信息(包含备注)
|
||||
ipcMain.handle('db:getColumns', async (_, id, database, table) => {
|
||||
const db = dbConnections.get(id)
|
||||
if (!db) return []
|
||||
|
||||
try {
|
||||
if (db.type === 'mysql') {
|
||||
const [rows] = await db.conn.query(`
|
||||
SELECT COLUMN_NAME as name, DATA_TYPE as type, IS_NULLABLE as nullable,
|
||||
COLUMN_KEY as \`key\`, COLUMN_COMMENT as comment
|
||||
FROM information_schema.COLUMNS
|
||||
WHERE TABLE_SCHEMA = ? AND TABLE_NAME = ?
|
||||
ORDER BY ORDINAL_POSITION
|
||||
`, [database, table])
|
||||
return rows.map((r: any) => ({
|
||||
name: r.name,
|
||||
type: r.type,
|
||||
nullable: r.nullable === 'YES',
|
||||
key: r.key || undefined,
|
||||
comment: r.comment || undefined
|
||||
}))
|
||||
} else if (db.type === 'postgres') {
|
||||
const result = await db.conn.query(`
|
||||
SELECT c.column_name as name, c.data_type as type, c.is_nullable as nullable,
|
||||
pgd.description as comment
|
||||
FROM information_schema.columns c
|
||||
LEFT JOIN pg_catalog.pg_statio_all_tables st ON c.table_schema = st.schemaname AND c.table_name = st.relname
|
||||
LEFT JOIN pg_catalog.pg_description pgd ON pgd.objoid = st.relid AND pgd.objsubid = c.ordinal_position
|
||||
WHERE c.table_schema = 'public' AND c.table_name = $1
|
||||
ORDER BY c.ordinal_position
|
||||
`, [table])
|
||||
return result.rows.map((r: any) => ({
|
||||
name: r.name,
|
||||
type: r.type,
|
||||
nullable: r.nullable === 'YES',
|
||||
comment: r.comment || undefined
|
||||
}))
|
||||
}
|
||||
} catch (err) {
|
||||
console.error('getColumns error:', err)
|
||||
}
|
||||
return []
|
||||
})
|
||||
|
||||
// 获取表数据(分页)
|
||||
ipcMain.handle('db:getTableData', async (_, id, database, table, page = 1, pageSize = 100) => {
|
||||
const db = dbConnections.get(id)
|
||||
if (!db) return { data: [], total: 0 }
|
||||
|
||||
try {
|
||||
const offset = (page - 1) * pageSize
|
||||
|
||||
if (db.type === 'mysql') {
|
||||
// 获取总数
|
||||
const [countResult] = await db.conn.query(`SELECT COUNT(*) as total FROM \`${database}\`.\`${table}\``)
|
||||
const total = countResult[0]?.total || 0
|
||||
|
||||
// 获取数据
|
||||
const [rows] = await db.conn.query(`SELECT * FROM \`${database}\`.\`${table}\` LIMIT ? OFFSET ?`, [pageSize, offset])
|
||||
return { data: rows, total }
|
||||
} else if (db.type === 'postgres') {
|
||||
// 获取总数
|
||||
const countResult = await db.conn.query(`SELECT COUNT(*) as total FROM "${table}"`)
|
||||
const total = parseInt(countResult.rows[0]?.total) || 0
|
||||
|
||||
// 获取数据
|
||||
const result = await db.conn.query(`SELECT * FROM "${table}" LIMIT $1 OFFSET $2`, [pageSize, offset])
|
||||
return { data: result.rows, total }
|
||||
}
|
||||
} catch (err) {
|
||||
console.error('getTableData error:', err)
|
||||
}
|
||||
return { data: [], total: 0 }
|
||||
})
|
||||
|
||||
// 配置存储
|
||||
const fs = require('fs')
|
||||
const configPath = path.join(app.getPath('userData'), 'connections.json')
|
||||
|
||||
ipcMain.handle('config:save', async (_, connections) => {
|
||||
fs.writeFileSync(configPath, JSON.stringify(connections, null, 2))
|
||||
})
|
||||
|
||||
ipcMain.handle('config:load', async () => {
|
||||
try {
|
||||
if (fs.existsSync(configPath)) {
|
||||
return JSON.parse(fs.readFileSync(configPath, 'utf-8'))
|
||||
}
|
||||
} catch {}
|
||||
return []
|
||||
})
|
||||
|
||||
// 文件操作
|
||||
ipcMain.handle('file:open', async () => {
|
||||
const result = await dialog.showOpenDialog(mainWindow!, {
|
||||
title: '打开 SQL 文件',
|
||||
filters: [
|
||||
{ name: 'SQL 文件', extensions: ['sql'] },
|
||||
{ name: '所有文件', extensions: ['*'] }
|
||||
],
|
||||
properties: ['openFile']
|
||||
})
|
||||
|
||||
if (result.canceled || result.filePaths.length === 0) {
|
||||
return null
|
||||
}
|
||||
|
||||
const filePath = result.filePaths[0]
|
||||
try {
|
||||
const content = fs.readFileSync(filePath, 'utf-8')
|
||||
return { path: filePath, content, name: path.basename(filePath) }
|
||||
} catch (err: any) {
|
||||
return { error: err.message }
|
||||
}
|
||||
})
|
||||
|
||||
ipcMain.handle('file:save', async (_, filePath: string | null, content: string) => {
|
||||
let targetPath = filePath
|
||||
|
||||
if (!targetPath) {
|
||||
const result = await dialog.showSaveDialog(mainWindow!, {
|
||||
title: '保存 SQL 文件',
|
||||
defaultPath: 'query.sql',
|
||||
filters: [
|
||||
{ name: 'SQL 文件', extensions: ['sql'] },
|
||||
{ name: '所有文件', extensions: ['*'] }
|
||||
]
|
||||
})
|
||||
|
||||
if (result.canceled || !result.filePath) {
|
||||
return null
|
||||
}
|
||||
targetPath = result.filePath
|
||||
}
|
||||
|
||||
try {
|
||||
fs.writeFileSync(targetPath, content, 'utf-8')
|
||||
return { path: targetPath, name: path.basename(targetPath) }
|
||||
} catch (err: any) {
|
||||
return { error: err.message }
|
||||
}
|
||||
})
|
||||
|
||||
// 数据库备份
|
||||
ipcMain.handle('db:backup', async (_, id: string, database: string) => {
|
||||
const db = dbConnections.get(id)
|
||||
if (!db) return { error: '未连接数据库' }
|
||||
|
||||
// 选择保存位置
|
||||
const result = await dialog.showSaveDialog(mainWindow!, {
|
||||
title: '备份数据库',
|
||||
defaultPath: `${database}_backup_${new Date().toISOString().slice(0, 10)}.sql`,
|
||||
filters: [
|
||||
{ name: 'SQL 文件', extensions: ['sql'] },
|
||||
{ name: '所有文件', extensions: ['*'] }
|
||||
]
|
||||
})
|
||||
|
||||
if (result.canceled || !result.filePath) {
|
||||
return { cancelled: true }
|
||||
}
|
||||
|
||||
try {
|
||||
let sqlContent = ''
|
||||
sqlContent += `-- Database Backup: ${database}\n`
|
||||
sqlContent += `-- Generated: ${new Date().toLocaleString()}\n`
|
||||
sqlContent += `-- Tool: EasySQL\n\n`
|
||||
|
||||
if (db.type === 'mysql' || db.type === 'mariadb') {
|
||||
// 切换到目标数据库
|
||||
await db.conn.query(`USE \`${database}\``)
|
||||
|
||||
// 获取所有表
|
||||
const [tables] = await db.conn.query(`SHOW TABLES`)
|
||||
const tableKey = `Tables_in_${database}`
|
||||
|
||||
sqlContent += `SET FOREIGN_KEY_CHECKS = 0;\n\n`
|
||||
|
||||
for (const tableRow of tables as any[]) {
|
||||
const tableName = tableRow[tableKey]
|
||||
|
||||
// 获取建表语句
|
||||
const [createResult] = await db.conn.query(`SHOW CREATE TABLE \`${tableName}\``)
|
||||
const createStatement = (createResult as any[])[0]['Create Table']
|
||||
|
||||
sqlContent += `-- Table: ${tableName}\n`
|
||||
sqlContent += `DROP TABLE IF EXISTS \`${tableName}\`;\n`
|
||||
sqlContent += `${createStatement};\n\n`
|
||||
|
||||
// 获取表数据
|
||||
const [rows] = await db.conn.query(`SELECT * FROM \`${tableName}\``)
|
||||
|
||||
if ((rows as any[]).length > 0) {
|
||||
const columns = Object.keys((rows as any[])[0])
|
||||
|
||||
for (const row of rows as any[]) {
|
||||
const values = columns.map(col => {
|
||||
const val = row[col]
|
||||
if (val === null) return 'NULL'
|
||||
if (typeof val === 'number') return val
|
||||
if (val instanceof Date) return `'${val.toISOString().slice(0, 19).replace('T', ' ')}'`
|
||||
return `'${String(val).replace(/'/g, "''").replace(/\\/g, '\\\\')}'`
|
||||
}).join(', ')
|
||||
|
||||
sqlContent += `INSERT INTO \`${tableName}\` (\`${columns.join('`, `')}\`) VALUES (${values});\n`
|
||||
}
|
||||
sqlContent += '\n'
|
||||
}
|
||||
}
|
||||
|
||||
sqlContent += `SET FOREIGN_KEY_CHECKS = 1;\n`
|
||||
} else if (db.type === 'postgres') {
|
||||
// PostgreSQL 备份
|
||||
const tablesResult = await db.conn.query(`
|
||||
SELECT tablename FROM pg_tables WHERE schemaname = 'public'
|
||||
`)
|
||||
|
||||
for (const tableRow of tablesResult.rows) {
|
||||
const tableName = tableRow.tablename
|
||||
|
||||
// 获取表数据
|
||||
const dataResult = await db.conn.query(`SELECT * FROM "${tableName}"`)
|
||||
|
||||
if (dataResult.rows.length > 0) {
|
||||
const columns = Object.keys(dataResult.rows[0])
|
||||
|
||||
sqlContent += `-- Table: ${tableName}\n`
|
||||
|
||||
for (const row of dataResult.rows) {
|
||||
const values = columns.map(col => {
|
||||
const val = row[col]
|
||||
if (val === null) return 'NULL'
|
||||
if (typeof val === 'number') return val
|
||||
if (val instanceof Date) return `'${val.toISOString().slice(0, 19).replace('T', ' ')}'`
|
||||
return `'${String(val).replace(/'/g, "''")}'`
|
||||
}).join(', ')
|
||||
|
||||
sqlContent += `INSERT INTO "${tableName}" ("${columns.join('", "')}") VALUES (${values});\n`
|
||||
}
|
||||
sqlContent += '\n'
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
fs.writeFileSync(result.filePath, sqlContent, 'utf-8')
|
||||
return { success: true, path: result.filePath }
|
||||
} catch (err: any) {
|
||||
return { error: err.message }
|
||||
}
|
||||
})
|
||||
|
||||
// 导出表数据
|
||||
ipcMain.handle('db:exportTable', async (_, id: string, database: string, tableName: string, format: 'excel' | 'sql' | 'csv') => {
|
||||
const db = dbConnections.get(id)
|
||||
if (!db) return { error: '未连接数据库' }
|
||||
|
||||
const ext = format === 'excel' ? 'xlsx' : format
|
||||
const result = await dialog.showSaveDialog(mainWindow!, {
|
||||
title: `导出表 ${tableName}`,
|
||||
defaultPath: `${tableName}_${new Date().toISOString().slice(0, 10)}.${ext}`,
|
||||
filters: [
|
||||
{ name: format === 'excel' ? 'Excel 文件' : format === 'sql' ? 'SQL 文件' : 'CSV 文件', extensions: [ext] },
|
||||
{ name: '所有文件', extensions: ['*'] }
|
||||
]
|
||||
})
|
||||
|
||||
if (result.canceled || !result.filePath) {
|
||||
return { cancelled: true }
|
||||
}
|
||||
|
||||
try {
|
||||
let rows: any[] = []
|
||||
let columns: string[] = []
|
||||
|
||||
if (db.type === 'mysql' || db.type === 'mariadb') {
|
||||
await db.conn.query(`USE \`${database}\``)
|
||||
const [data] = await db.conn.query(`SELECT * FROM \`${tableName}\``)
|
||||
rows = data as any[]
|
||||
if (rows.length > 0) columns = Object.keys(rows[0])
|
||||
} else if (db.type === 'postgres') {
|
||||
const data = await db.conn.query(`SELECT * FROM "${tableName}"`)
|
||||
rows = data.rows
|
||||
if (rows.length > 0) columns = Object.keys(rows[0])
|
||||
}
|
||||
|
||||
if (format === 'sql') {
|
||||
let content = `-- Table: ${tableName}\n`
|
||||
content += `-- Exported: ${new Date().toLocaleString()}\n\n`
|
||||
|
||||
for (const row of rows) {
|
||||
const values = columns.map(col => {
|
||||
const val = row[col]
|
||||
if (val === null) return 'NULL'
|
||||
if (typeof val === 'number') return val
|
||||
return `'${String(val).replace(/'/g, "''")}'`
|
||||
}).join(', ')
|
||||
content += `INSERT INTO \`${tableName}\` (\`${columns.join('`, `')}\`) VALUES (${values});\n`
|
||||
}
|
||||
|
||||
fs.writeFileSync(result.filePath, content, 'utf-8')
|
||||
} else if (format === 'csv') {
|
||||
let content = columns.join(',') + '\n'
|
||||
for (const row of rows) {
|
||||
const values = columns.map(col => {
|
||||
const val = row[col]
|
||||
if (val === null) return ''
|
||||
const str = String(val)
|
||||
if (str.includes(',') || str.includes('"') || str.includes('\n')) {
|
||||
return `"${str.replace(/"/g, '""')}"`
|
||||
}
|
||||
return str
|
||||
})
|
||||
content += values.join(',') + '\n'
|
||||
}
|
||||
fs.writeFileSync(result.filePath, content, 'utf-8')
|
||||
}
|
||||
|
||||
return { success: true, path: result.filePath }
|
||||
} catch (err: any) {
|
||||
return { error: err.message }
|
||||
}
|
||||
})
|
||||
34
electron/preload.ts
Normal file
34
electron/preload.ts
Normal file
@ -0,0 +1,34 @@
|
||||
import { contextBridge, ipcRenderer } from 'electron'
|
||||
|
||||
// 暴露 API 给渲染进程
|
||||
contextBridge.exposeInMainWorld('electronAPI', {
|
||||
// 窗口控制
|
||||
minimize: () => ipcRenderer.invoke('window:minimize'),
|
||||
maximize: () => ipcRenderer.invoke('window:maximize'),
|
||||
close: () => ipcRenderer.invoke('window:close'),
|
||||
|
||||
// 数据库操作
|
||||
testConnection: (config: any) => ipcRenderer.invoke('db:test', config),
|
||||
connect: (config: any) => ipcRenderer.invoke('db:connect', config),
|
||||
disconnect: (id: string) => ipcRenderer.invoke('db:disconnect', id),
|
||||
query: (id: string, sql: string) => ipcRenderer.invoke('db:query', id, sql),
|
||||
getDatabases: (id: string) => ipcRenderer.invoke('db:getDatabases', id),
|
||||
getTables: (id: string, database: string) => ipcRenderer.invoke('db:getTables', id, database),
|
||||
getColumns: (id: string, database: string, table: string) => ipcRenderer.invoke('db:getColumns', id, database, table),
|
||||
getTableData: (id: string, database: string, table: string, page?: number, pageSize?: number) =>
|
||||
ipcRenderer.invoke('db:getTableData', id, database, table, page, pageSize),
|
||||
|
||||
// 配置存储
|
||||
saveConnections: (connections: any[]) => ipcRenderer.invoke('config:save', connections),
|
||||
loadConnections: () => ipcRenderer.invoke('config:load'),
|
||||
|
||||
// 文件操作
|
||||
openFile: () => ipcRenderer.invoke('file:open'),
|
||||
saveFile: (filePath: string | null, content: string) => ipcRenderer.invoke('file:save', filePath, content),
|
||||
|
||||
// 数据库备份与导出
|
||||
backupDatabase: (id: string, database: string) => ipcRenderer.invoke('db:backup', id, database),
|
||||
exportTable: (id: string, database: string, tableName: string, format: 'excel' | 'sql' | 'csv') =>
|
||||
ipcRenderer.invoke('db:exportTable', id, database, tableName, format),
|
||||
})
|
||||
|
||||
16
index.html
Normal file
16
index.html
Normal file
@ -0,0 +1,16 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="zh-CN">
|
||||
<head>
|
||||
<meta charset="UTF-8" />
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
||||
<title>EasySQL</title>
|
||||
<link rel="preconnect" href="https://fonts.googleapis.com">
|
||||
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
|
||||
<link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&family=JetBrains+Mono:wght@400;500&display=swap" rel="stylesheet">
|
||||
</head>
|
||||
<body class="bg-dark-950 text-white font-sans antialiased">
|
||||
<div id="root"></div>
|
||||
<script type="module" src="/src/main.tsx"></script>
|
||||
</body>
|
||||
</html>
|
||||
|
||||
16
node_modules/.bin/autoprefixer
generated
vendored
Normal file
16
node_modules/.bin/autoprefixer
generated
vendored
Normal file
@ -0,0 +1,16 @@
|
||||
#!/bin/sh
|
||||
basedir=$(dirname "$(echo "$0" | sed -e 's,\\,/,g')")
|
||||
|
||||
case `uname` in
|
||||
*CYGWIN*|*MINGW*|*MSYS*)
|
||||
if command -v cygpath > /dev/null 2>&1; then
|
||||
basedir=`cygpath -w "$basedir"`
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
|
||||
if [ -x "$basedir/node" ]; then
|
||||
exec "$basedir/node" "$basedir/../autoprefixer/bin/autoprefixer" "$@"
|
||||
else
|
||||
exec node "$basedir/../autoprefixer/bin/autoprefixer" "$@"
|
||||
fi
|
||||
17
node_modules/.bin/autoprefixer.cmd
generated
vendored
Normal file
17
node_modules/.bin/autoprefixer.cmd
generated
vendored
Normal file
@ -0,0 +1,17 @@
|
||||
@ECHO off
|
||||
GOTO start
|
||||
:find_dp0
|
||||
SET dp0=%~dp0
|
||||
EXIT /b
|
||||
:start
|
||||
SETLOCAL
|
||||
CALL :find_dp0
|
||||
|
||||
IF EXIST "%dp0%\node.exe" (
|
||||
SET "_prog=%dp0%\node.exe"
|
||||
) ELSE (
|
||||
SET "_prog=node"
|
||||
SET PATHEXT=%PATHEXT:;.JS;=;%
|
||||
)
|
||||
|
||||
endLocal & goto #_undefined_# 2>NUL || title %COMSPEC% & "%_prog%" "%dp0%\..\autoprefixer\bin\autoprefixer" %*
|
||||
28
node_modules/.bin/autoprefixer.ps1
generated
vendored
Normal file
28
node_modules/.bin/autoprefixer.ps1
generated
vendored
Normal file
@ -0,0 +1,28 @@
|
||||
#!/usr/bin/env pwsh
|
||||
$basedir=Split-Path $MyInvocation.MyCommand.Definition -Parent
|
||||
|
||||
$exe=""
|
||||
if ($PSVersionTable.PSVersion -lt "6.0" -or $IsWindows) {
|
||||
# Fix case when both the Windows and Linux builds of Node
|
||||
# are installed in the same directory
|
||||
$exe=".exe"
|
||||
}
|
||||
$ret=0
|
||||
if (Test-Path "$basedir/node$exe") {
|
||||
# Support pipeline input
|
||||
if ($MyInvocation.ExpectingInput) {
|
||||
$input | & "$basedir/node$exe" "$basedir/../autoprefixer/bin/autoprefixer" $args
|
||||
} else {
|
||||
& "$basedir/node$exe" "$basedir/../autoprefixer/bin/autoprefixer" $args
|
||||
}
|
||||
$ret=$LASTEXITCODE
|
||||
} else {
|
||||
# Support pipeline input
|
||||
if ($MyInvocation.ExpectingInput) {
|
||||
$input | & "node$exe" "$basedir/../autoprefixer/bin/autoprefixer" $args
|
||||
} else {
|
||||
& "node$exe" "$basedir/../autoprefixer/bin/autoprefixer" $args
|
||||
}
|
||||
$ret=$LASTEXITCODE
|
||||
}
|
||||
exit $ret
|
||||
16
node_modules/.bin/baseline-browser-mapping
generated
vendored
Normal file
16
node_modules/.bin/baseline-browser-mapping
generated
vendored
Normal file
@ -0,0 +1,16 @@
|
||||
#!/bin/sh
|
||||
basedir=$(dirname "$(echo "$0" | sed -e 's,\\,/,g')")
|
||||
|
||||
case `uname` in
|
||||
*CYGWIN*|*MINGW*|*MSYS*)
|
||||
if command -v cygpath > /dev/null 2>&1; then
|
||||
basedir=`cygpath -w "$basedir"`
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
|
||||
if [ -x "$basedir/node" ]; then
|
||||
exec "$basedir/node" "$basedir/../baseline-browser-mapping/dist/cli.js" "$@"
|
||||
else
|
||||
exec node "$basedir/../baseline-browser-mapping/dist/cli.js" "$@"
|
||||
fi
|
||||
17
node_modules/.bin/baseline-browser-mapping.cmd
generated
vendored
Normal file
17
node_modules/.bin/baseline-browser-mapping.cmd
generated
vendored
Normal file
@ -0,0 +1,17 @@
|
||||
@ECHO off
|
||||
GOTO start
|
||||
:find_dp0
|
||||
SET dp0=%~dp0
|
||||
EXIT /b
|
||||
:start
|
||||
SETLOCAL
|
||||
CALL :find_dp0
|
||||
|
||||
IF EXIST "%dp0%\node.exe" (
|
||||
SET "_prog=%dp0%\node.exe"
|
||||
) ELSE (
|
||||
SET "_prog=node"
|
||||
SET PATHEXT=%PATHEXT:;.JS;=;%
|
||||
)
|
||||
|
||||
endLocal & goto #_undefined_# 2>NUL || title %COMSPEC% & "%_prog%" "%dp0%\..\baseline-browser-mapping\dist\cli.js" %*
|
||||
28
node_modules/.bin/baseline-browser-mapping.ps1
generated
vendored
Normal file
28
node_modules/.bin/baseline-browser-mapping.ps1
generated
vendored
Normal file
@ -0,0 +1,28 @@
|
||||
#!/usr/bin/env pwsh
|
||||
$basedir=Split-Path $MyInvocation.MyCommand.Definition -Parent
|
||||
|
||||
$exe=""
|
||||
if ($PSVersionTable.PSVersion -lt "6.0" -or $IsWindows) {
|
||||
# Fix case when both the Windows and Linux builds of Node
|
||||
# are installed in the same directory
|
||||
$exe=".exe"
|
||||
}
|
||||
$ret=0
|
||||
if (Test-Path "$basedir/node$exe") {
|
||||
# Support pipeline input
|
||||
if ($MyInvocation.ExpectingInput) {
|
||||
$input | & "$basedir/node$exe" "$basedir/../baseline-browser-mapping/dist/cli.js" $args
|
||||
} else {
|
||||
& "$basedir/node$exe" "$basedir/../baseline-browser-mapping/dist/cli.js" $args
|
||||
}
|
||||
$ret=$LASTEXITCODE
|
||||
} else {
|
||||
# Support pipeline input
|
||||
if ($MyInvocation.ExpectingInput) {
|
||||
$input | & "node$exe" "$basedir/../baseline-browser-mapping/dist/cli.js" $args
|
||||
} else {
|
||||
& "node$exe" "$basedir/../baseline-browser-mapping/dist/cli.js" $args
|
||||
}
|
||||
$ret=$LASTEXITCODE
|
||||
}
|
||||
exit $ret
|
||||
16
node_modules/.bin/browserslist
generated
vendored
Normal file
16
node_modules/.bin/browserslist
generated
vendored
Normal file
@ -0,0 +1,16 @@
|
||||
#!/bin/sh
|
||||
basedir=$(dirname "$(echo "$0" | sed -e 's,\\,/,g')")
|
||||
|
||||
case `uname` in
|
||||
*CYGWIN*|*MINGW*|*MSYS*)
|
||||
if command -v cygpath > /dev/null 2>&1; then
|
||||
basedir=`cygpath -w "$basedir"`
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
|
||||
if [ -x "$basedir/node" ]; then
|
||||
exec "$basedir/node" "$basedir/../browserslist/cli.js" "$@"
|
||||
else
|
||||
exec node "$basedir/../browserslist/cli.js" "$@"
|
||||
fi
|
||||
17
node_modules/.bin/browserslist.cmd
generated
vendored
Normal file
17
node_modules/.bin/browserslist.cmd
generated
vendored
Normal file
@ -0,0 +1,17 @@
|
||||
@ECHO off
|
||||
GOTO start
|
||||
:find_dp0
|
||||
SET dp0=%~dp0
|
||||
EXIT /b
|
||||
:start
|
||||
SETLOCAL
|
||||
CALL :find_dp0
|
||||
|
||||
IF EXIST "%dp0%\node.exe" (
|
||||
SET "_prog=%dp0%\node.exe"
|
||||
) ELSE (
|
||||
SET "_prog=node"
|
||||
SET PATHEXT=%PATHEXT:;.JS;=;%
|
||||
)
|
||||
|
||||
endLocal & goto #_undefined_# 2>NUL || title %COMSPEC% & "%_prog%" "%dp0%\..\browserslist\cli.js" %*
|
||||
28
node_modules/.bin/browserslist.ps1
generated
vendored
Normal file
28
node_modules/.bin/browserslist.ps1
generated
vendored
Normal file
@ -0,0 +1,28 @@
|
||||
#!/usr/bin/env pwsh
|
||||
$basedir=Split-Path $MyInvocation.MyCommand.Definition -Parent
|
||||
|
||||
$exe=""
|
||||
if ($PSVersionTable.PSVersion -lt "6.0" -or $IsWindows) {
|
||||
# Fix case when both the Windows and Linux builds of Node
|
||||
# are installed in the same directory
|
||||
$exe=".exe"
|
||||
}
|
||||
$ret=0
|
||||
if (Test-Path "$basedir/node$exe") {
|
||||
# Support pipeline input
|
||||
if ($MyInvocation.ExpectingInput) {
|
||||
$input | & "$basedir/node$exe" "$basedir/../browserslist/cli.js" $args
|
||||
} else {
|
||||
& "$basedir/node$exe" "$basedir/../browserslist/cli.js" $args
|
||||
}
|
||||
$ret=$LASTEXITCODE
|
||||
} else {
|
||||
# Support pipeline input
|
||||
if ($MyInvocation.ExpectingInput) {
|
||||
$input | & "node$exe" "$basedir/../browserslist/cli.js" $args
|
||||
} else {
|
||||
& "node$exe" "$basedir/../browserslist/cli.js" $args
|
||||
}
|
||||
$ret=$LASTEXITCODE
|
||||
}
|
||||
exit $ret
|
||||
16
node_modules/.bin/crc32
generated
vendored
Normal file
16
node_modules/.bin/crc32
generated
vendored
Normal file
@ -0,0 +1,16 @@
|
||||
#!/bin/sh
|
||||
basedir=$(dirname "$(echo "$0" | sed -e 's,\\,/,g')")
|
||||
|
||||
case `uname` in
|
||||
*CYGWIN*|*MINGW*|*MSYS*)
|
||||
if command -v cygpath > /dev/null 2>&1; then
|
||||
basedir=`cygpath -w "$basedir"`
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
|
||||
if [ -x "$basedir/node" ]; then
|
||||
exec "$basedir/node" "$basedir/../crc-32/bin/crc32.njs" "$@"
|
||||
else
|
||||
exec node "$basedir/../crc-32/bin/crc32.njs" "$@"
|
||||
fi
|
||||
17
node_modules/.bin/crc32.cmd
generated
vendored
Normal file
17
node_modules/.bin/crc32.cmd
generated
vendored
Normal file
@ -0,0 +1,17 @@
|
||||
@ECHO off
|
||||
GOTO start
|
||||
:find_dp0
|
||||
SET dp0=%~dp0
|
||||
EXIT /b
|
||||
:start
|
||||
SETLOCAL
|
||||
CALL :find_dp0
|
||||
|
||||
IF EXIST "%dp0%\node.exe" (
|
||||
SET "_prog=%dp0%\node.exe"
|
||||
) ELSE (
|
||||
SET "_prog=node"
|
||||
SET PATHEXT=%PATHEXT:;.JS;=;%
|
||||
)
|
||||
|
||||
endLocal & goto #_undefined_# 2>NUL || title %COMSPEC% & "%_prog%" "%dp0%\..\crc-32\bin\crc32.njs" %*
|
||||
28
node_modules/.bin/crc32.ps1
generated
vendored
Normal file
28
node_modules/.bin/crc32.ps1
generated
vendored
Normal file
@ -0,0 +1,28 @@
|
||||
#!/usr/bin/env pwsh
|
||||
$basedir=Split-Path $MyInvocation.MyCommand.Definition -Parent
|
||||
|
||||
$exe=""
|
||||
if ($PSVersionTable.PSVersion -lt "6.0" -or $IsWindows) {
|
||||
# Fix case when both the Windows and Linux builds of Node
|
||||
# are installed in the same directory
|
||||
$exe=".exe"
|
||||
}
|
||||
$ret=0
|
||||
if (Test-Path "$basedir/node$exe") {
|
||||
# Support pipeline input
|
||||
if ($MyInvocation.ExpectingInput) {
|
||||
$input | & "$basedir/node$exe" "$basedir/../crc-32/bin/crc32.njs" $args
|
||||
} else {
|
||||
& "$basedir/node$exe" "$basedir/../crc-32/bin/crc32.njs" $args
|
||||
}
|
||||
$ret=$LASTEXITCODE
|
||||
} else {
|
||||
# Support pipeline input
|
||||
if ($MyInvocation.ExpectingInput) {
|
||||
$input | & "node$exe" "$basedir/../crc-32/bin/crc32.njs" $args
|
||||
} else {
|
||||
& "node$exe" "$basedir/../crc-32/bin/crc32.njs" $args
|
||||
}
|
||||
$ret=$LASTEXITCODE
|
||||
}
|
||||
exit $ret
|
||||
16
node_modules/.bin/cssesc
generated
vendored
Normal file
16
node_modules/.bin/cssesc
generated
vendored
Normal file
@ -0,0 +1,16 @@
|
||||
#!/bin/sh
|
||||
basedir=$(dirname "$(echo "$0" | sed -e 's,\\,/,g')")
|
||||
|
||||
case `uname` in
|
||||
*CYGWIN*|*MINGW*|*MSYS*)
|
||||
if command -v cygpath > /dev/null 2>&1; then
|
||||
basedir=`cygpath -w "$basedir"`
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
|
||||
if [ -x "$basedir/node" ]; then
|
||||
exec "$basedir/node" "$basedir/../cssesc/bin/cssesc" "$@"
|
||||
else
|
||||
exec node "$basedir/../cssesc/bin/cssesc" "$@"
|
||||
fi
|
||||
17
node_modules/.bin/cssesc.cmd
generated
vendored
Normal file
17
node_modules/.bin/cssesc.cmd
generated
vendored
Normal file
@ -0,0 +1,17 @@
|
||||
@ECHO off
|
||||
GOTO start
|
||||
:find_dp0
|
||||
SET dp0=%~dp0
|
||||
EXIT /b
|
||||
:start
|
||||
SETLOCAL
|
||||
CALL :find_dp0
|
||||
|
||||
IF EXIST "%dp0%\node.exe" (
|
||||
SET "_prog=%dp0%\node.exe"
|
||||
) ELSE (
|
||||
SET "_prog=node"
|
||||
SET PATHEXT=%PATHEXT:;.JS;=;%
|
||||
)
|
||||
|
||||
endLocal & goto #_undefined_# 2>NUL || title %COMSPEC% & "%_prog%" "%dp0%\..\cssesc\bin\cssesc" %*
|
||||
28
node_modules/.bin/cssesc.ps1
generated
vendored
Normal file
28
node_modules/.bin/cssesc.ps1
generated
vendored
Normal file
@ -0,0 +1,28 @@
|
||||
#!/usr/bin/env pwsh
|
||||
$basedir=Split-Path $MyInvocation.MyCommand.Definition -Parent
|
||||
|
||||
$exe=""
|
||||
if ($PSVersionTable.PSVersion -lt "6.0" -or $IsWindows) {
|
||||
# Fix case when both the Windows and Linux builds of Node
|
||||
# are installed in the same directory
|
||||
$exe=".exe"
|
||||
}
|
||||
$ret=0
|
||||
if (Test-Path "$basedir/node$exe") {
|
||||
# Support pipeline input
|
||||
if ($MyInvocation.ExpectingInput) {
|
||||
$input | & "$basedir/node$exe" "$basedir/../cssesc/bin/cssesc" $args
|
||||
} else {
|
||||
& "$basedir/node$exe" "$basedir/../cssesc/bin/cssesc" $args
|
||||
}
|
||||
$ret=$LASTEXITCODE
|
||||
} else {
|
||||
# Support pipeline input
|
||||
if ($MyInvocation.ExpectingInput) {
|
||||
$input | & "node$exe" "$basedir/../cssesc/bin/cssesc" $args
|
||||
} else {
|
||||
& "node$exe" "$basedir/../cssesc/bin/cssesc" $args
|
||||
}
|
||||
$ret=$LASTEXITCODE
|
||||
}
|
||||
exit $ret
|
||||
16
node_modules/.bin/electron
generated
vendored
Normal file
16
node_modules/.bin/electron
generated
vendored
Normal file
@ -0,0 +1,16 @@
|
||||
#!/bin/sh
|
||||
basedir=$(dirname "$(echo "$0" | sed -e 's,\\,/,g')")
|
||||
|
||||
case `uname` in
|
||||
*CYGWIN*|*MINGW*|*MSYS*)
|
||||
if command -v cygpath > /dev/null 2>&1; then
|
||||
basedir=`cygpath -w "$basedir"`
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
|
||||
if [ -x "$basedir/node" ]; then
|
||||
exec "$basedir/node" "$basedir/../electron/cli.js" "$@"
|
||||
else
|
||||
exec node "$basedir/../electron/cli.js" "$@"
|
||||
fi
|
||||
17
node_modules/.bin/electron.cmd
generated
vendored
Normal file
17
node_modules/.bin/electron.cmd
generated
vendored
Normal file
@ -0,0 +1,17 @@
|
||||
@ECHO off
|
||||
GOTO start
|
||||
:find_dp0
|
||||
SET dp0=%~dp0
|
||||
EXIT /b
|
||||
:start
|
||||
SETLOCAL
|
||||
CALL :find_dp0
|
||||
|
||||
IF EXIST "%dp0%\node.exe" (
|
||||
SET "_prog=%dp0%\node.exe"
|
||||
) ELSE (
|
||||
SET "_prog=node"
|
||||
SET PATHEXT=%PATHEXT:;.JS;=;%
|
||||
)
|
||||
|
||||
endLocal & goto #_undefined_# 2>NUL || title %COMSPEC% & "%_prog%" "%dp0%\..\electron\cli.js" %*
|
||||
28
node_modules/.bin/electron.ps1
generated
vendored
Normal file
28
node_modules/.bin/electron.ps1
generated
vendored
Normal file
@ -0,0 +1,28 @@
|
||||
#!/usr/bin/env pwsh
|
||||
$basedir=Split-Path $MyInvocation.MyCommand.Definition -Parent
|
||||
|
||||
$exe=""
|
||||
if ($PSVersionTable.PSVersion -lt "6.0" -or $IsWindows) {
|
||||
# Fix case when both the Windows and Linux builds of Node
|
||||
# are installed in the same directory
|
||||
$exe=".exe"
|
||||
}
|
||||
$ret=0
|
||||
if (Test-Path "$basedir/node$exe") {
|
||||
# Support pipeline input
|
||||
if ($MyInvocation.ExpectingInput) {
|
||||
$input | & "$basedir/node$exe" "$basedir/../electron/cli.js" $args
|
||||
} else {
|
||||
& "$basedir/node$exe" "$basedir/../electron/cli.js" $args
|
||||
}
|
||||
$ret=$LASTEXITCODE
|
||||
} else {
|
||||
# Support pipeline input
|
||||
if ($MyInvocation.ExpectingInput) {
|
||||
$input | & "node$exe" "$basedir/../electron/cli.js" $args
|
||||
} else {
|
||||
& "node$exe" "$basedir/../electron/cli.js" $args
|
||||
}
|
||||
$ret=$LASTEXITCODE
|
||||
}
|
||||
exit $ret
|
||||
16
node_modules/.bin/esbuild
generated
vendored
Normal file
16
node_modules/.bin/esbuild
generated
vendored
Normal file
@ -0,0 +1,16 @@
|
||||
#!/bin/sh
|
||||
basedir=$(dirname "$(echo "$0" | sed -e 's,\\,/,g')")
|
||||
|
||||
case `uname` in
|
||||
*CYGWIN*|*MINGW*|*MSYS*)
|
||||
if command -v cygpath > /dev/null 2>&1; then
|
||||
basedir=`cygpath -w "$basedir"`
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
|
||||
if [ -x "$basedir/node" ]; then
|
||||
exec "$basedir/node" "$basedir/../esbuild/bin/esbuild" "$@"
|
||||
else
|
||||
exec node "$basedir/../esbuild/bin/esbuild" "$@"
|
||||
fi
|
||||
17
node_modules/.bin/esbuild.cmd
generated
vendored
Normal file
17
node_modules/.bin/esbuild.cmd
generated
vendored
Normal file
@ -0,0 +1,17 @@
|
||||
@ECHO off
|
||||
GOTO start
|
||||
:find_dp0
|
||||
SET dp0=%~dp0
|
||||
EXIT /b
|
||||
:start
|
||||
SETLOCAL
|
||||
CALL :find_dp0
|
||||
|
||||
IF EXIST "%dp0%\node.exe" (
|
||||
SET "_prog=%dp0%\node.exe"
|
||||
) ELSE (
|
||||
SET "_prog=node"
|
||||
SET PATHEXT=%PATHEXT:;.JS;=;%
|
||||
)
|
||||
|
||||
endLocal & goto #_undefined_# 2>NUL || title %COMSPEC% & "%_prog%" "%dp0%\..\esbuild\bin\esbuild" %*
|
||||
28
node_modules/.bin/esbuild.ps1
generated
vendored
Normal file
28
node_modules/.bin/esbuild.ps1
generated
vendored
Normal file
@ -0,0 +1,28 @@
|
||||
#!/usr/bin/env pwsh
|
||||
$basedir=Split-Path $MyInvocation.MyCommand.Definition -Parent
|
||||
|
||||
$exe=""
|
||||
if ($PSVersionTable.PSVersion -lt "6.0" -or $IsWindows) {
|
||||
# Fix case when both the Windows and Linux builds of Node
|
||||
# are installed in the same directory
|
||||
$exe=".exe"
|
||||
}
|
||||
$ret=0
|
||||
if (Test-Path "$basedir/node$exe") {
|
||||
# Support pipeline input
|
||||
if ($MyInvocation.ExpectingInput) {
|
||||
$input | & "$basedir/node$exe" "$basedir/../esbuild/bin/esbuild" $args
|
||||
} else {
|
||||
& "$basedir/node$exe" "$basedir/../esbuild/bin/esbuild" $args
|
||||
}
|
||||
$ret=$LASTEXITCODE
|
||||
} else {
|
||||
# Support pipeline input
|
||||
if ($MyInvocation.ExpectingInput) {
|
||||
$input | & "node$exe" "$basedir/../esbuild/bin/esbuild" $args
|
||||
} else {
|
||||
& "node$exe" "$basedir/../esbuild/bin/esbuild" $args
|
||||
}
|
||||
$ret=$LASTEXITCODE
|
||||
}
|
||||
exit $ret
|
||||
16
node_modules/.bin/extract-zip
generated
vendored
Normal file
16
node_modules/.bin/extract-zip
generated
vendored
Normal file
@ -0,0 +1,16 @@
|
||||
#!/bin/sh
|
||||
basedir=$(dirname "$(echo "$0" | sed -e 's,\\,/,g')")
|
||||
|
||||
case `uname` in
|
||||
*CYGWIN*|*MINGW*|*MSYS*)
|
||||
if command -v cygpath > /dev/null 2>&1; then
|
||||
basedir=`cygpath -w "$basedir"`
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
|
||||
if [ -x "$basedir/node" ]; then
|
||||
exec "$basedir/node" "$basedir/../extract-zip/cli.js" "$@"
|
||||
else
|
||||
exec node "$basedir/../extract-zip/cli.js" "$@"
|
||||
fi
|
||||
17
node_modules/.bin/extract-zip.cmd
generated
vendored
Normal file
17
node_modules/.bin/extract-zip.cmd
generated
vendored
Normal file
@ -0,0 +1,17 @@
|
||||
@ECHO off
|
||||
GOTO start
|
||||
:find_dp0
|
||||
SET dp0=%~dp0
|
||||
EXIT /b
|
||||
:start
|
||||
SETLOCAL
|
||||
CALL :find_dp0
|
||||
|
||||
IF EXIST "%dp0%\node.exe" (
|
||||
SET "_prog=%dp0%\node.exe"
|
||||
) ELSE (
|
||||
SET "_prog=node"
|
||||
SET PATHEXT=%PATHEXT:;.JS;=;%
|
||||
)
|
||||
|
||||
endLocal & goto #_undefined_# 2>NUL || title %COMSPEC% & "%_prog%" "%dp0%\..\extract-zip\cli.js" %*
|
||||
28
node_modules/.bin/extract-zip.ps1
generated
vendored
Normal file
28
node_modules/.bin/extract-zip.ps1
generated
vendored
Normal file
@ -0,0 +1,28 @@
|
||||
#!/usr/bin/env pwsh
|
||||
$basedir=Split-Path $MyInvocation.MyCommand.Definition -Parent
|
||||
|
||||
$exe=""
|
||||
if ($PSVersionTable.PSVersion -lt "6.0" -or $IsWindows) {
|
||||
# Fix case when both the Windows and Linux builds of Node
|
||||
# are installed in the same directory
|
||||
$exe=".exe"
|
||||
}
|
||||
$ret=0
|
||||
if (Test-Path "$basedir/node$exe") {
|
||||
# Support pipeline input
|
||||
if ($MyInvocation.ExpectingInput) {
|
||||
$input | & "$basedir/node$exe" "$basedir/../extract-zip/cli.js" $args
|
||||
} else {
|
||||
& "$basedir/node$exe" "$basedir/../extract-zip/cli.js" $args
|
||||
}
|
||||
$ret=$LASTEXITCODE
|
||||
} else {
|
||||
# Support pipeline input
|
||||
if ($MyInvocation.ExpectingInput) {
|
||||
$input | & "node$exe" "$basedir/../extract-zip/cli.js" $args
|
||||
} else {
|
||||
& "node$exe" "$basedir/../extract-zip/cli.js" $args
|
||||
}
|
||||
$ret=$LASTEXITCODE
|
||||
}
|
||||
exit $ret
|
||||
16
node_modules/.bin/jiti
generated
vendored
Normal file
16
node_modules/.bin/jiti
generated
vendored
Normal file
@ -0,0 +1,16 @@
|
||||
#!/bin/sh
|
||||
basedir=$(dirname "$(echo "$0" | sed -e 's,\\,/,g')")
|
||||
|
||||
case `uname` in
|
||||
*CYGWIN*|*MINGW*|*MSYS*)
|
||||
if command -v cygpath > /dev/null 2>&1; then
|
||||
basedir=`cygpath -w "$basedir"`
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
|
||||
if [ -x "$basedir/node" ]; then
|
||||
exec "$basedir/node" "$basedir/../jiti/bin/jiti.js" "$@"
|
||||
else
|
||||
exec node "$basedir/../jiti/bin/jiti.js" "$@"
|
||||
fi
|
||||
17
node_modules/.bin/jiti.cmd
generated
vendored
Normal file
17
node_modules/.bin/jiti.cmd
generated
vendored
Normal file
@ -0,0 +1,17 @@
|
||||
@ECHO off
|
||||
GOTO start
|
||||
:find_dp0
|
||||
SET dp0=%~dp0
|
||||
EXIT /b
|
||||
:start
|
||||
SETLOCAL
|
||||
CALL :find_dp0
|
||||
|
||||
IF EXIST "%dp0%\node.exe" (
|
||||
SET "_prog=%dp0%\node.exe"
|
||||
) ELSE (
|
||||
SET "_prog=node"
|
||||
SET PATHEXT=%PATHEXT:;.JS;=;%
|
||||
)
|
||||
|
||||
endLocal & goto #_undefined_# 2>NUL || title %COMSPEC% & "%_prog%" "%dp0%\..\jiti\bin\jiti.js" %*
|
||||
28
node_modules/.bin/jiti.ps1
generated
vendored
Normal file
28
node_modules/.bin/jiti.ps1
generated
vendored
Normal file
@ -0,0 +1,28 @@
|
||||
#!/usr/bin/env pwsh
|
||||
$basedir=Split-Path $MyInvocation.MyCommand.Definition -Parent
|
||||
|
||||
$exe=""
|
||||
if ($PSVersionTable.PSVersion -lt "6.0" -or $IsWindows) {
|
||||
# Fix case when both the Windows and Linux builds of Node
|
||||
# are installed in the same directory
|
||||
$exe=".exe"
|
||||
}
|
||||
$ret=0
|
||||
if (Test-Path "$basedir/node$exe") {
|
||||
# Support pipeline input
|
||||
if ($MyInvocation.ExpectingInput) {
|
||||
$input | & "$basedir/node$exe" "$basedir/../jiti/bin/jiti.js" $args
|
||||
} else {
|
||||
& "$basedir/node$exe" "$basedir/../jiti/bin/jiti.js" $args
|
||||
}
|
||||
$ret=$LASTEXITCODE
|
||||
} else {
|
||||
# Support pipeline input
|
||||
if ($MyInvocation.ExpectingInput) {
|
||||
$input | & "node$exe" "$basedir/../jiti/bin/jiti.js" $args
|
||||
} else {
|
||||
& "node$exe" "$basedir/../jiti/bin/jiti.js" $args
|
||||
}
|
||||
$ret=$LASTEXITCODE
|
||||
}
|
||||
exit $ret
|
||||
16
node_modules/.bin/jsesc
generated
vendored
Normal file
16
node_modules/.bin/jsesc
generated
vendored
Normal file
@ -0,0 +1,16 @@
|
||||
#!/bin/sh
|
||||
basedir=$(dirname "$(echo "$0" | sed -e 's,\\,/,g')")
|
||||
|
||||
case `uname` in
|
||||
*CYGWIN*|*MINGW*|*MSYS*)
|
||||
if command -v cygpath > /dev/null 2>&1; then
|
||||
basedir=`cygpath -w "$basedir"`
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
|
||||
if [ -x "$basedir/node" ]; then
|
||||
exec "$basedir/node" "$basedir/../jsesc/bin/jsesc" "$@"
|
||||
else
|
||||
exec node "$basedir/../jsesc/bin/jsesc" "$@"
|
||||
fi
|
||||
17
node_modules/.bin/jsesc.cmd
generated
vendored
Normal file
17
node_modules/.bin/jsesc.cmd
generated
vendored
Normal file
@ -0,0 +1,17 @@
|
||||
@ECHO off
|
||||
GOTO start
|
||||
:find_dp0
|
||||
SET dp0=%~dp0
|
||||
EXIT /b
|
||||
:start
|
||||
SETLOCAL
|
||||
CALL :find_dp0
|
||||
|
||||
IF EXIST "%dp0%\node.exe" (
|
||||
SET "_prog=%dp0%\node.exe"
|
||||
) ELSE (
|
||||
SET "_prog=node"
|
||||
SET PATHEXT=%PATHEXT:;.JS;=;%
|
||||
)
|
||||
|
||||
endLocal & goto #_undefined_# 2>NUL || title %COMSPEC% & "%_prog%" "%dp0%\..\jsesc\bin\jsesc" %*
|
||||
28
node_modules/.bin/jsesc.ps1
generated
vendored
Normal file
28
node_modules/.bin/jsesc.ps1
generated
vendored
Normal file
@ -0,0 +1,28 @@
|
||||
#!/usr/bin/env pwsh
|
||||
$basedir=Split-Path $MyInvocation.MyCommand.Definition -Parent
|
||||
|
||||
$exe=""
|
||||
if ($PSVersionTable.PSVersion -lt "6.0" -or $IsWindows) {
|
||||
# Fix case when both the Windows and Linux builds of Node
|
||||
# are installed in the same directory
|
||||
$exe=".exe"
|
||||
}
|
||||
$ret=0
|
||||
if (Test-Path "$basedir/node$exe") {
|
||||
# Support pipeline input
|
||||
if ($MyInvocation.ExpectingInput) {
|
||||
$input | & "$basedir/node$exe" "$basedir/../jsesc/bin/jsesc" $args
|
||||
} else {
|
||||
& "$basedir/node$exe" "$basedir/../jsesc/bin/jsesc" $args
|
||||
}
|
||||
$ret=$LASTEXITCODE
|
||||
} else {
|
||||
# Support pipeline input
|
||||
if ($MyInvocation.ExpectingInput) {
|
||||
$input | & "node$exe" "$basedir/../jsesc/bin/jsesc" $args
|
||||
} else {
|
||||
& "node$exe" "$basedir/../jsesc/bin/jsesc" $args
|
||||
}
|
||||
$ret=$LASTEXITCODE
|
||||
}
|
||||
exit $ret
|
||||
16
node_modules/.bin/json5
generated
vendored
Normal file
16
node_modules/.bin/json5
generated
vendored
Normal file
@ -0,0 +1,16 @@
|
||||
#!/bin/sh
|
||||
basedir=$(dirname "$(echo "$0" | sed -e 's,\\,/,g')")
|
||||
|
||||
case `uname` in
|
||||
*CYGWIN*|*MINGW*|*MSYS*)
|
||||
if command -v cygpath > /dev/null 2>&1; then
|
||||
basedir=`cygpath -w "$basedir"`
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
|
||||
if [ -x "$basedir/node" ]; then
|
||||
exec "$basedir/node" "$basedir/../json5/lib/cli.js" "$@"
|
||||
else
|
||||
exec node "$basedir/../json5/lib/cli.js" "$@"
|
||||
fi
|
||||
17
node_modules/.bin/json5.cmd
generated
vendored
Normal file
17
node_modules/.bin/json5.cmd
generated
vendored
Normal file
@ -0,0 +1,17 @@
|
||||
@ECHO off
|
||||
GOTO start
|
||||
:find_dp0
|
||||
SET dp0=%~dp0
|
||||
EXIT /b
|
||||
:start
|
||||
SETLOCAL
|
||||
CALL :find_dp0
|
||||
|
||||
IF EXIST "%dp0%\node.exe" (
|
||||
SET "_prog=%dp0%\node.exe"
|
||||
) ELSE (
|
||||
SET "_prog=node"
|
||||
SET PATHEXT=%PATHEXT:;.JS;=;%
|
||||
)
|
||||
|
||||
endLocal & goto #_undefined_# 2>NUL || title %COMSPEC% & "%_prog%" "%dp0%\..\json5\lib\cli.js" %*
|
||||
28
node_modules/.bin/json5.ps1
generated
vendored
Normal file
28
node_modules/.bin/json5.ps1
generated
vendored
Normal file
@ -0,0 +1,28 @@
|
||||
#!/usr/bin/env pwsh
|
||||
$basedir=Split-Path $MyInvocation.MyCommand.Definition -Parent
|
||||
|
||||
$exe=""
|
||||
if ($PSVersionTable.PSVersion -lt "6.0" -or $IsWindows) {
|
||||
# Fix case when both the Windows and Linux builds of Node
|
||||
# are installed in the same directory
|
||||
$exe=".exe"
|
||||
}
|
||||
$ret=0
|
||||
if (Test-Path "$basedir/node$exe") {
|
||||
# Support pipeline input
|
||||
if ($MyInvocation.ExpectingInput) {
|
||||
$input | & "$basedir/node$exe" "$basedir/../json5/lib/cli.js" $args
|
||||
} else {
|
||||
& "$basedir/node$exe" "$basedir/../json5/lib/cli.js" $args
|
||||
}
|
||||
$ret=$LASTEXITCODE
|
||||
} else {
|
||||
# Support pipeline input
|
||||
if ($MyInvocation.ExpectingInput) {
|
||||
$input | & "node$exe" "$basedir/../json5/lib/cli.js" $args
|
||||
} else {
|
||||
& "node$exe" "$basedir/../json5/lib/cli.js" $args
|
||||
}
|
||||
$ret=$LASTEXITCODE
|
||||
}
|
||||
exit $ret
|
||||
16
node_modules/.bin/loose-envify
generated
vendored
Normal file
16
node_modules/.bin/loose-envify
generated
vendored
Normal file
@ -0,0 +1,16 @@
|
||||
#!/bin/sh
|
||||
basedir=$(dirname "$(echo "$0" | sed -e 's,\\,/,g')")
|
||||
|
||||
case `uname` in
|
||||
*CYGWIN*|*MINGW*|*MSYS*)
|
||||
if command -v cygpath > /dev/null 2>&1; then
|
||||
basedir=`cygpath -w "$basedir"`
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
|
||||
if [ -x "$basedir/node" ]; then
|
||||
exec "$basedir/node" "$basedir/../loose-envify/cli.js" "$@"
|
||||
else
|
||||
exec node "$basedir/../loose-envify/cli.js" "$@"
|
||||
fi
|
||||
17
node_modules/.bin/loose-envify.cmd
generated
vendored
Normal file
17
node_modules/.bin/loose-envify.cmd
generated
vendored
Normal file
@ -0,0 +1,17 @@
|
||||
@ECHO off
|
||||
GOTO start
|
||||
:find_dp0
|
||||
SET dp0=%~dp0
|
||||
EXIT /b
|
||||
:start
|
||||
SETLOCAL
|
||||
CALL :find_dp0
|
||||
|
||||
IF EXIST "%dp0%\node.exe" (
|
||||
SET "_prog=%dp0%\node.exe"
|
||||
) ELSE (
|
||||
SET "_prog=node"
|
||||
SET PATHEXT=%PATHEXT:;.JS;=;%
|
||||
)
|
||||
|
||||
endLocal & goto #_undefined_# 2>NUL || title %COMSPEC% & "%_prog%" "%dp0%\..\loose-envify\cli.js" %*
|
||||
28
node_modules/.bin/loose-envify.ps1
generated
vendored
Normal file
28
node_modules/.bin/loose-envify.ps1
generated
vendored
Normal file
@ -0,0 +1,28 @@
|
||||
#!/usr/bin/env pwsh
|
||||
$basedir=Split-Path $MyInvocation.MyCommand.Definition -Parent
|
||||
|
||||
$exe=""
|
||||
if ($PSVersionTable.PSVersion -lt "6.0" -or $IsWindows) {
|
||||
# Fix case when both the Windows and Linux builds of Node
|
||||
# are installed in the same directory
|
||||
$exe=".exe"
|
||||
}
|
||||
$ret=0
|
||||
if (Test-Path "$basedir/node$exe") {
|
||||
# Support pipeline input
|
||||
if ($MyInvocation.ExpectingInput) {
|
||||
$input | & "$basedir/node$exe" "$basedir/../loose-envify/cli.js" $args
|
||||
} else {
|
||||
& "$basedir/node$exe" "$basedir/../loose-envify/cli.js" $args
|
||||
}
|
||||
$ret=$LASTEXITCODE
|
||||
} else {
|
||||
# Support pipeline input
|
||||
if ($MyInvocation.ExpectingInput) {
|
||||
$input | & "node$exe" "$basedir/../loose-envify/cli.js" $args
|
||||
} else {
|
||||
& "node$exe" "$basedir/../loose-envify/cli.js" $args
|
||||
}
|
||||
$ret=$LASTEXITCODE
|
||||
}
|
||||
exit $ret
|
||||
16
node_modules/.bin/marked
generated
vendored
Normal file
16
node_modules/.bin/marked
generated
vendored
Normal file
@ -0,0 +1,16 @@
|
||||
#!/bin/sh
|
||||
basedir=$(dirname "$(echo "$0" | sed -e 's,\\,/,g')")
|
||||
|
||||
case `uname` in
|
||||
*CYGWIN*|*MINGW*|*MSYS*)
|
||||
if command -v cygpath > /dev/null 2>&1; then
|
||||
basedir=`cygpath -w "$basedir"`
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
|
||||
if [ -x "$basedir/node" ]; then
|
||||
exec "$basedir/node" "$basedir/../marked/bin/marked.js" "$@"
|
||||
else
|
||||
exec node "$basedir/../marked/bin/marked.js" "$@"
|
||||
fi
|
||||
17
node_modules/.bin/marked.cmd
generated
vendored
Normal file
17
node_modules/.bin/marked.cmd
generated
vendored
Normal file
@ -0,0 +1,17 @@
|
||||
@ECHO off
|
||||
GOTO start
|
||||
:find_dp0
|
||||
SET dp0=%~dp0
|
||||
EXIT /b
|
||||
:start
|
||||
SETLOCAL
|
||||
CALL :find_dp0
|
||||
|
||||
IF EXIST "%dp0%\node.exe" (
|
||||
SET "_prog=%dp0%\node.exe"
|
||||
) ELSE (
|
||||
SET "_prog=node"
|
||||
SET PATHEXT=%PATHEXT:;.JS;=;%
|
||||
)
|
||||
|
||||
endLocal & goto #_undefined_# 2>NUL || title %COMSPEC% & "%_prog%" "%dp0%\..\marked\bin\marked.js" %*
|
||||
28
node_modules/.bin/marked.ps1
generated
vendored
Normal file
28
node_modules/.bin/marked.ps1
generated
vendored
Normal file
@ -0,0 +1,28 @@
|
||||
#!/usr/bin/env pwsh
|
||||
$basedir=Split-Path $MyInvocation.MyCommand.Definition -Parent
|
||||
|
||||
$exe=""
|
||||
if ($PSVersionTable.PSVersion -lt "6.0" -or $IsWindows) {
|
||||
# Fix case when both the Windows and Linux builds of Node
|
||||
# are installed in the same directory
|
||||
$exe=".exe"
|
||||
}
|
||||
$ret=0
|
||||
if (Test-Path "$basedir/node$exe") {
|
||||
# Support pipeline input
|
||||
if ($MyInvocation.ExpectingInput) {
|
||||
$input | & "$basedir/node$exe" "$basedir/../marked/bin/marked.js" $args
|
||||
} else {
|
||||
& "$basedir/node$exe" "$basedir/../marked/bin/marked.js" $args
|
||||
}
|
||||
$ret=$LASTEXITCODE
|
||||
} else {
|
||||
# Support pipeline input
|
||||
if ($MyInvocation.ExpectingInput) {
|
||||
$input | & "node$exe" "$basedir/../marked/bin/marked.js" $args
|
||||
} else {
|
||||
& "node$exe" "$basedir/../marked/bin/marked.js" $args
|
||||
}
|
||||
$ret=$LASTEXITCODE
|
||||
}
|
||||
exit $ret
|
||||
16
node_modules/.bin/nanoid
generated
vendored
Normal file
16
node_modules/.bin/nanoid
generated
vendored
Normal file
@ -0,0 +1,16 @@
|
||||
#!/bin/sh
|
||||
basedir=$(dirname "$(echo "$0" | sed -e 's,\\,/,g')")
|
||||
|
||||
case `uname` in
|
||||
*CYGWIN*|*MINGW*|*MSYS*)
|
||||
if command -v cygpath > /dev/null 2>&1; then
|
||||
basedir=`cygpath -w "$basedir"`
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
|
||||
if [ -x "$basedir/node" ]; then
|
||||
exec "$basedir/node" "$basedir/../nanoid/bin/nanoid.cjs" "$@"
|
||||
else
|
||||
exec node "$basedir/../nanoid/bin/nanoid.cjs" "$@"
|
||||
fi
|
||||
17
node_modules/.bin/nanoid.cmd
generated
vendored
Normal file
17
node_modules/.bin/nanoid.cmd
generated
vendored
Normal file
@ -0,0 +1,17 @@
|
||||
@ECHO off
|
||||
GOTO start
|
||||
:find_dp0
|
||||
SET dp0=%~dp0
|
||||
EXIT /b
|
||||
:start
|
||||
SETLOCAL
|
||||
CALL :find_dp0
|
||||
|
||||
IF EXIST "%dp0%\node.exe" (
|
||||
SET "_prog=%dp0%\node.exe"
|
||||
) ELSE (
|
||||
SET "_prog=node"
|
||||
SET PATHEXT=%PATHEXT:;.JS;=;%
|
||||
)
|
||||
|
||||
endLocal & goto #_undefined_# 2>NUL || title %COMSPEC% & "%_prog%" "%dp0%\..\nanoid\bin\nanoid.cjs" %*
|
||||
28
node_modules/.bin/nanoid.ps1
generated
vendored
Normal file
28
node_modules/.bin/nanoid.ps1
generated
vendored
Normal file
@ -0,0 +1,28 @@
|
||||
#!/usr/bin/env pwsh
|
||||
$basedir=Split-Path $MyInvocation.MyCommand.Definition -Parent
|
||||
|
||||
$exe=""
|
||||
if ($PSVersionTable.PSVersion -lt "6.0" -or $IsWindows) {
|
||||
# Fix case when both the Windows and Linux builds of Node
|
||||
# are installed in the same directory
|
||||
$exe=".exe"
|
||||
}
|
||||
$ret=0
|
||||
if (Test-Path "$basedir/node$exe") {
|
||||
# Support pipeline input
|
||||
if ($MyInvocation.ExpectingInput) {
|
||||
$input | & "$basedir/node$exe" "$basedir/../nanoid/bin/nanoid.cjs" $args
|
||||
} else {
|
||||
& "$basedir/node$exe" "$basedir/../nanoid/bin/nanoid.cjs" $args
|
||||
}
|
||||
$ret=$LASTEXITCODE
|
||||
} else {
|
||||
# Support pipeline input
|
||||
if ($MyInvocation.ExpectingInput) {
|
||||
$input | & "node$exe" "$basedir/../nanoid/bin/nanoid.cjs" $args
|
||||
} else {
|
||||
& "node$exe" "$basedir/../nanoid/bin/nanoid.cjs" $args
|
||||
}
|
||||
$ret=$LASTEXITCODE
|
||||
}
|
||||
exit $ret
|
||||
16
node_modules/.bin/nearley-railroad
generated
vendored
Normal file
16
node_modules/.bin/nearley-railroad
generated
vendored
Normal file
@ -0,0 +1,16 @@
|
||||
#!/bin/sh
|
||||
basedir=$(dirname "$(echo "$0" | sed -e 's,\\,/,g')")
|
||||
|
||||
case `uname` in
|
||||
*CYGWIN*|*MINGW*|*MSYS*)
|
||||
if command -v cygpath > /dev/null 2>&1; then
|
||||
basedir=`cygpath -w "$basedir"`
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
|
||||
if [ -x "$basedir/node" ]; then
|
||||
exec "$basedir/node" "$basedir/../nearley/bin/nearley-railroad.js" "$@"
|
||||
else
|
||||
exec node "$basedir/../nearley/bin/nearley-railroad.js" "$@"
|
||||
fi
|
||||
17
node_modules/.bin/nearley-railroad.cmd
generated
vendored
Normal file
17
node_modules/.bin/nearley-railroad.cmd
generated
vendored
Normal file
@ -0,0 +1,17 @@
|
||||
@ECHO off
|
||||
GOTO start
|
||||
:find_dp0
|
||||
SET dp0=%~dp0
|
||||
EXIT /b
|
||||
:start
|
||||
SETLOCAL
|
||||
CALL :find_dp0
|
||||
|
||||
IF EXIST "%dp0%\node.exe" (
|
||||
SET "_prog=%dp0%\node.exe"
|
||||
) ELSE (
|
||||
SET "_prog=node"
|
||||
SET PATHEXT=%PATHEXT:;.JS;=;%
|
||||
)
|
||||
|
||||
endLocal & goto #_undefined_# 2>NUL || title %COMSPEC% & "%_prog%" "%dp0%\..\nearley\bin\nearley-railroad.js" %*
|
||||
28
node_modules/.bin/nearley-railroad.ps1
generated
vendored
Normal file
28
node_modules/.bin/nearley-railroad.ps1
generated
vendored
Normal file
@ -0,0 +1,28 @@
|
||||
#!/usr/bin/env pwsh
|
||||
$basedir=Split-Path $MyInvocation.MyCommand.Definition -Parent
|
||||
|
||||
$exe=""
|
||||
if ($PSVersionTable.PSVersion -lt "6.0" -or $IsWindows) {
|
||||
# Fix case when both the Windows and Linux builds of Node
|
||||
# are installed in the same directory
|
||||
$exe=".exe"
|
||||
}
|
||||
$ret=0
|
||||
if (Test-Path "$basedir/node$exe") {
|
||||
# Support pipeline input
|
||||
if ($MyInvocation.ExpectingInput) {
|
||||
$input | & "$basedir/node$exe" "$basedir/../nearley/bin/nearley-railroad.js" $args
|
||||
} else {
|
||||
& "$basedir/node$exe" "$basedir/../nearley/bin/nearley-railroad.js" $args
|
||||
}
|
||||
$ret=$LASTEXITCODE
|
||||
} else {
|
||||
# Support pipeline input
|
||||
if ($MyInvocation.ExpectingInput) {
|
||||
$input | & "node$exe" "$basedir/../nearley/bin/nearley-railroad.js" $args
|
||||
} else {
|
||||
& "node$exe" "$basedir/../nearley/bin/nearley-railroad.js" $args
|
||||
}
|
||||
$ret=$LASTEXITCODE
|
||||
}
|
||||
exit $ret
|
||||
16
node_modules/.bin/nearley-test
generated
vendored
Normal file
16
node_modules/.bin/nearley-test
generated
vendored
Normal file
@ -0,0 +1,16 @@
|
||||
#!/bin/sh
|
||||
basedir=$(dirname "$(echo "$0" | sed -e 's,\\,/,g')")
|
||||
|
||||
case `uname` in
|
||||
*CYGWIN*|*MINGW*|*MSYS*)
|
||||
if command -v cygpath > /dev/null 2>&1; then
|
||||
basedir=`cygpath -w "$basedir"`
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
|
||||
if [ -x "$basedir/node" ]; then
|
||||
exec "$basedir/node" "$basedir/../nearley/bin/nearley-test.js" "$@"
|
||||
else
|
||||
exec node "$basedir/../nearley/bin/nearley-test.js" "$@"
|
||||
fi
|
||||
17
node_modules/.bin/nearley-test.cmd
generated
vendored
Normal file
17
node_modules/.bin/nearley-test.cmd
generated
vendored
Normal file
@ -0,0 +1,17 @@
|
||||
@ECHO off
|
||||
GOTO start
|
||||
:find_dp0
|
||||
SET dp0=%~dp0
|
||||
EXIT /b
|
||||
:start
|
||||
SETLOCAL
|
||||
CALL :find_dp0
|
||||
|
||||
IF EXIST "%dp0%\node.exe" (
|
||||
SET "_prog=%dp0%\node.exe"
|
||||
) ELSE (
|
||||
SET "_prog=node"
|
||||
SET PATHEXT=%PATHEXT:;.JS;=;%
|
||||
)
|
||||
|
||||
endLocal & goto #_undefined_# 2>NUL || title %COMSPEC% & "%_prog%" "%dp0%\..\nearley\bin\nearley-test.js" %*
|
||||
28
node_modules/.bin/nearley-test.ps1
generated
vendored
Normal file
28
node_modules/.bin/nearley-test.ps1
generated
vendored
Normal file
@ -0,0 +1,28 @@
|
||||
#!/usr/bin/env pwsh
|
||||
$basedir=Split-Path $MyInvocation.MyCommand.Definition -Parent
|
||||
|
||||
$exe=""
|
||||
if ($PSVersionTable.PSVersion -lt "6.0" -or $IsWindows) {
|
||||
# Fix case when both the Windows and Linux builds of Node
|
||||
# are installed in the same directory
|
||||
$exe=".exe"
|
||||
}
|
||||
$ret=0
|
||||
if (Test-Path "$basedir/node$exe") {
|
||||
# Support pipeline input
|
||||
if ($MyInvocation.ExpectingInput) {
|
||||
$input | & "$basedir/node$exe" "$basedir/../nearley/bin/nearley-test.js" $args
|
||||
} else {
|
||||
& "$basedir/node$exe" "$basedir/../nearley/bin/nearley-test.js" $args
|
||||
}
|
||||
$ret=$LASTEXITCODE
|
||||
} else {
|
||||
# Support pipeline input
|
||||
if ($MyInvocation.ExpectingInput) {
|
||||
$input | & "node$exe" "$basedir/../nearley/bin/nearley-test.js" $args
|
||||
} else {
|
||||
& "node$exe" "$basedir/../nearley/bin/nearley-test.js" $args
|
||||
}
|
||||
$ret=$LASTEXITCODE
|
||||
}
|
||||
exit $ret
|
||||
16
node_modules/.bin/nearley-unparse
generated
vendored
Normal file
16
node_modules/.bin/nearley-unparse
generated
vendored
Normal file
@ -0,0 +1,16 @@
|
||||
#!/bin/sh
|
||||
basedir=$(dirname "$(echo "$0" | sed -e 's,\\,/,g')")
|
||||
|
||||
case `uname` in
|
||||
*CYGWIN*|*MINGW*|*MSYS*)
|
||||
if command -v cygpath > /dev/null 2>&1; then
|
||||
basedir=`cygpath -w "$basedir"`
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
|
||||
if [ -x "$basedir/node" ]; then
|
||||
exec "$basedir/node" "$basedir/../nearley/bin/nearley-unparse.js" "$@"
|
||||
else
|
||||
exec node "$basedir/../nearley/bin/nearley-unparse.js" "$@"
|
||||
fi
|
||||
17
node_modules/.bin/nearley-unparse.cmd
generated
vendored
Normal file
17
node_modules/.bin/nearley-unparse.cmd
generated
vendored
Normal file
@ -0,0 +1,17 @@
|
||||
@ECHO off
|
||||
GOTO start
|
||||
:find_dp0
|
||||
SET dp0=%~dp0
|
||||
EXIT /b
|
||||
:start
|
||||
SETLOCAL
|
||||
CALL :find_dp0
|
||||
|
||||
IF EXIST "%dp0%\node.exe" (
|
||||
SET "_prog=%dp0%\node.exe"
|
||||
) ELSE (
|
||||
SET "_prog=node"
|
||||
SET PATHEXT=%PATHEXT:;.JS;=;%
|
||||
)
|
||||
|
||||
endLocal & goto #_undefined_# 2>NUL || title %COMSPEC% & "%_prog%" "%dp0%\..\nearley\bin\nearley-unparse.js" %*
|
||||
28
node_modules/.bin/nearley-unparse.ps1
generated
vendored
Normal file
28
node_modules/.bin/nearley-unparse.ps1
generated
vendored
Normal file
@ -0,0 +1,28 @@
|
||||
#!/usr/bin/env pwsh
|
||||
$basedir=Split-Path $MyInvocation.MyCommand.Definition -Parent
|
||||
|
||||
$exe=""
|
||||
if ($PSVersionTable.PSVersion -lt "6.0" -or $IsWindows) {
|
||||
# Fix case when both the Windows and Linux builds of Node
|
||||
# are installed in the same directory
|
||||
$exe=".exe"
|
||||
}
|
||||
$ret=0
|
||||
if (Test-Path "$basedir/node$exe") {
|
||||
# Support pipeline input
|
||||
if ($MyInvocation.ExpectingInput) {
|
||||
$input | & "$basedir/node$exe" "$basedir/../nearley/bin/nearley-unparse.js" $args
|
||||
} else {
|
||||
& "$basedir/node$exe" "$basedir/../nearley/bin/nearley-unparse.js" $args
|
||||
}
|
||||
$ret=$LASTEXITCODE
|
||||
} else {
|
||||
# Support pipeline input
|
||||
if ($MyInvocation.ExpectingInput) {
|
||||
$input | & "node$exe" "$basedir/../nearley/bin/nearley-unparse.js" $args
|
||||
} else {
|
||||
& "node$exe" "$basedir/../nearley/bin/nearley-unparse.js" $args
|
||||
}
|
||||
$ret=$LASTEXITCODE
|
||||
}
|
||||
exit $ret
|
||||
16
node_modules/.bin/nearleyc
generated
vendored
Normal file
16
node_modules/.bin/nearleyc
generated
vendored
Normal file
@ -0,0 +1,16 @@
|
||||
#!/bin/sh
|
||||
basedir=$(dirname "$(echo "$0" | sed -e 's,\\,/,g')")
|
||||
|
||||
case `uname` in
|
||||
*CYGWIN*|*MINGW*|*MSYS*)
|
||||
if command -v cygpath > /dev/null 2>&1; then
|
||||
basedir=`cygpath -w "$basedir"`
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
|
||||
if [ -x "$basedir/node" ]; then
|
||||
exec "$basedir/node" "$basedir/../nearley/bin/nearleyc.js" "$@"
|
||||
else
|
||||
exec node "$basedir/../nearley/bin/nearleyc.js" "$@"
|
||||
fi
|
||||
17
node_modules/.bin/nearleyc.cmd
generated
vendored
Normal file
17
node_modules/.bin/nearleyc.cmd
generated
vendored
Normal file
@ -0,0 +1,17 @@
|
||||
@ECHO off
|
||||
GOTO start
|
||||
:find_dp0
|
||||
SET dp0=%~dp0
|
||||
EXIT /b
|
||||
:start
|
||||
SETLOCAL
|
||||
CALL :find_dp0
|
||||
|
||||
IF EXIST "%dp0%\node.exe" (
|
||||
SET "_prog=%dp0%\node.exe"
|
||||
) ELSE (
|
||||
SET "_prog=node"
|
||||
SET PATHEXT=%PATHEXT:;.JS;=;%
|
||||
)
|
||||
|
||||
endLocal & goto #_undefined_# 2>NUL || title %COMSPEC% & "%_prog%" "%dp0%\..\nearley\bin\nearleyc.js" %*
|
||||
28
node_modules/.bin/nearleyc.ps1
generated
vendored
Normal file
28
node_modules/.bin/nearleyc.ps1
generated
vendored
Normal file
@ -0,0 +1,28 @@
|
||||
#!/usr/bin/env pwsh
|
||||
$basedir=Split-Path $MyInvocation.MyCommand.Definition -Parent
|
||||
|
||||
$exe=""
|
||||
if ($PSVersionTable.PSVersion -lt "6.0" -or $IsWindows) {
|
||||
# Fix case when both the Windows and Linux builds of Node
|
||||
# are installed in the same directory
|
||||
$exe=".exe"
|
||||
}
|
||||
$ret=0
|
||||
if (Test-Path "$basedir/node$exe") {
|
||||
# Support pipeline input
|
||||
if ($MyInvocation.ExpectingInput) {
|
||||
$input | & "$basedir/node$exe" "$basedir/../nearley/bin/nearleyc.js" $args
|
||||
} else {
|
||||
& "$basedir/node$exe" "$basedir/../nearley/bin/nearleyc.js" $args
|
||||
}
|
||||
$ret=$LASTEXITCODE
|
||||
} else {
|
||||
# Support pipeline input
|
||||
if ($MyInvocation.ExpectingInput) {
|
||||
$input | & "node$exe" "$basedir/../nearley/bin/nearleyc.js" $args
|
||||
} else {
|
||||
& "node$exe" "$basedir/../nearley/bin/nearleyc.js" $args
|
||||
}
|
||||
$ret=$LASTEXITCODE
|
||||
}
|
||||
exit $ret
|
||||
16
node_modules/.bin/parser
generated
vendored
Normal file
16
node_modules/.bin/parser
generated
vendored
Normal file
@ -0,0 +1,16 @@
|
||||
#!/bin/sh
|
||||
basedir=$(dirname "$(echo "$0" | sed -e 's,\\,/,g')")
|
||||
|
||||
case `uname` in
|
||||
*CYGWIN*|*MINGW*|*MSYS*)
|
||||
if command -v cygpath > /dev/null 2>&1; then
|
||||
basedir=`cygpath -w "$basedir"`
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
|
||||
if [ -x "$basedir/node" ]; then
|
||||
exec "$basedir/node" "$basedir/../@babel/parser/bin/babel-parser.js" "$@"
|
||||
else
|
||||
exec node "$basedir/../@babel/parser/bin/babel-parser.js" "$@"
|
||||
fi
|
||||
17
node_modules/.bin/parser.cmd
generated
vendored
Normal file
17
node_modules/.bin/parser.cmd
generated
vendored
Normal file
@ -0,0 +1,17 @@
|
||||
@ECHO off
|
||||
GOTO start
|
||||
:find_dp0
|
||||
SET dp0=%~dp0
|
||||
EXIT /b
|
||||
:start
|
||||
SETLOCAL
|
||||
CALL :find_dp0
|
||||
|
||||
IF EXIST "%dp0%\node.exe" (
|
||||
SET "_prog=%dp0%\node.exe"
|
||||
) ELSE (
|
||||
SET "_prog=node"
|
||||
SET PATHEXT=%PATHEXT:;.JS;=;%
|
||||
)
|
||||
|
||||
endLocal & goto #_undefined_# 2>NUL || title %COMSPEC% & "%_prog%" "%dp0%\..\@babel\parser\bin\babel-parser.js" %*
|
||||
28
node_modules/.bin/parser.ps1
generated
vendored
Normal file
28
node_modules/.bin/parser.ps1
generated
vendored
Normal file
@ -0,0 +1,28 @@
|
||||
#!/usr/bin/env pwsh
|
||||
$basedir=Split-Path $MyInvocation.MyCommand.Definition -Parent
|
||||
|
||||
$exe=""
|
||||
if ($PSVersionTable.PSVersion -lt "6.0" -or $IsWindows) {
|
||||
# Fix case when both the Windows and Linux builds of Node
|
||||
# are installed in the same directory
|
||||
$exe=".exe"
|
||||
}
|
||||
$ret=0
|
||||
if (Test-Path "$basedir/node$exe") {
|
||||
# Support pipeline input
|
||||
if ($MyInvocation.ExpectingInput) {
|
||||
$input | & "$basedir/node$exe" "$basedir/../@babel/parser/bin/babel-parser.js" $args
|
||||
} else {
|
||||
& "$basedir/node$exe" "$basedir/../@babel/parser/bin/babel-parser.js" $args
|
||||
}
|
||||
$ret=$LASTEXITCODE
|
||||
} else {
|
||||
# Support pipeline input
|
||||
if ($MyInvocation.ExpectingInput) {
|
||||
$input | & "node$exe" "$basedir/../@babel/parser/bin/babel-parser.js" $args
|
||||
} else {
|
||||
& "node$exe" "$basedir/../@babel/parser/bin/babel-parser.js" $args
|
||||
}
|
||||
$ret=$LASTEXITCODE
|
||||
}
|
||||
exit $ret
|
||||
16
node_modules/.bin/resolve
generated
vendored
Normal file
16
node_modules/.bin/resolve
generated
vendored
Normal file
@ -0,0 +1,16 @@
|
||||
#!/bin/sh
|
||||
basedir=$(dirname "$(echo "$0" | sed -e 's,\\,/,g')")
|
||||
|
||||
case `uname` in
|
||||
*CYGWIN*|*MINGW*|*MSYS*)
|
||||
if command -v cygpath > /dev/null 2>&1; then
|
||||
basedir=`cygpath -w "$basedir"`
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
|
||||
if [ -x "$basedir/node" ]; then
|
||||
exec "$basedir/node" "$basedir/../resolve/bin/resolve" "$@"
|
||||
else
|
||||
exec node "$basedir/../resolve/bin/resolve" "$@"
|
||||
fi
|
||||
17
node_modules/.bin/resolve.cmd
generated
vendored
Normal file
17
node_modules/.bin/resolve.cmd
generated
vendored
Normal file
@ -0,0 +1,17 @@
|
||||
@ECHO off
|
||||
GOTO start
|
||||
:find_dp0
|
||||
SET dp0=%~dp0
|
||||
EXIT /b
|
||||
:start
|
||||
SETLOCAL
|
||||
CALL :find_dp0
|
||||
|
||||
IF EXIST "%dp0%\node.exe" (
|
||||
SET "_prog=%dp0%\node.exe"
|
||||
) ELSE (
|
||||
SET "_prog=node"
|
||||
SET PATHEXT=%PATHEXT:;.JS;=;%
|
||||
)
|
||||
|
||||
endLocal & goto #_undefined_# 2>NUL || title %COMSPEC% & "%_prog%" "%dp0%\..\resolve\bin\resolve" %*
|
||||
28
node_modules/.bin/resolve.ps1
generated
vendored
Normal file
28
node_modules/.bin/resolve.ps1
generated
vendored
Normal file
@ -0,0 +1,28 @@
|
||||
#!/usr/bin/env pwsh
|
||||
$basedir=Split-Path $MyInvocation.MyCommand.Definition -Parent
|
||||
|
||||
$exe=""
|
||||
if ($PSVersionTable.PSVersion -lt "6.0" -or $IsWindows) {
|
||||
# Fix case when both the Windows and Linux builds of Node
|
||||
# are installed in the same directory
|
||||
$exe=".exe"
|
||||
}
|
||||
$ret=0
|
||||
if (Test-Path "$basedir/node$exe") {
|
||||
# Support pipeline input
|
||||
if ($MyInvocation.ExpectingInput) {
|
||||
$input | & "$basedir/node$exe" "$basedir/../resolve/bin/resolve" $args
|
||||
} else {
|
||||
& "$basedir/node$exe" "$basedir/../resolve/bin/resolve" $args
|
||||
}
|
||||
$ret=$LASTEXITCODE
|
||||
} else {
|
||||
# Support pipeline input
|
||||
if ($MyInvocation.ExpectingInput) {
|
||||
$input | & "node$exe" "$basedir/../resolve/bin/resolve" $args
|
||||
} else {
|
||||
& "node$exe" "$basedir/../resolve/bin/resolve" $args
|
||||
}
|
||||
$ret=$LASTEXITCODE
|
||||
}
|
||||
exit $ret
|
||||
16
node_modules/.bin/rollup
generated
vendored
Normal file
16
node_modules/.bin/rollup
generated
vendored
Normal file
@ -0,0 +1,16 @@
|
||||
#!/bin/sh
|
||||
basedir=$(dirname "$(echo "$0" | sed -e 's,\\,/,g')")
|
||||
|
||||
case `uname` in
|
||||
*CYGWIN*|*MINGW*|*MSYS*)
|
||||
if command -v cygpath > /dev/null 2>&1; then
|
||||
basedir=`cygpath -w "$basedir"`
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
|
||||
if [ -x "$basedir/node" ]; then
|
||||
exec "$basedir/node" "$basedir/../rollup/dist/bin/rollup" "$@"
|
||||
else
|
||||
exec node "$basedir/../rollup/dist/bin/rollup" "$@"
|
||||
fi
|
||||
17
node_modules/.bin/rollup.cmd
generated
vendored
Normal file
17
node_modules/.bin/rollup.cmd
generated
vendored
Normal file
@ -0,0 +1,17 @@
|
||||
@ECHO off
|
||||
GOTO start
|
||||
:find_dp0
|
||||
SET dp0=%~dp0
|
||||
EXIT /b
|
||||
:start
|
||||
SETLOCAL
|
||||
CALL :find_dp0
|
||||
|
||||
IF EXIST "%dp0%\node.exe" (
|
||||
SET "_prog=%dp0%\node.exe"
|
||||
) ELSE (
|
||||
SET "_prog=node"
|
||||
SET PATHEXT=%PATHEXT:;.JS;=;%
|
||||
)
|
||||
|
||||
endLocal & goto #_undefined_# 2>NUL || title %COMSPEC% & "%_prog%" "%dp0%\..\rollup\dist\bin\rollup" %*
|
||||
28
node_modules/.bin/rollup.ps1
generated
vendored
Normal file
28
node_modules/.bin/rollup.ps1
generated
vendored
Normal file
@ -0,0 +1,28 @@
|
||||
#!/usr/bin/env pwsh
|
||||
$basedir=Split-Path $MyInvocation.MyCommand.Definition -Parent
|
||||
|
||||
$exe=""
|
||||
if ($PSVersionTable.PSVersion -lt "6.0" -or $IsWindows) {
|
||||
# Fix case when both the Windows and Linux builds of Node
|
||||
# are installed in the same directory
|
||||
$exe=".exe"
|
||||
}
|
||||
$ret=0
|
||||
if (Test-Path "$basedir/node$exe") {
|
||||
# Support pipeline input
|
||||
if ($MyInvocation.ExpectingInput) {
|
||||
$input | & "$basedir/node$exe" "$basedir/../rollup/dist/bin/rollup" $args
|
||||
} else {
|
||||
& "$basedir/node$exe" "$basedir/../rollup/dist/bin/rollup" $args
|
||||
}
|
||||
$ret=$LASTEXITCODE
|
||||
} else {
|
||||
# Support pipeline input
|
||||
if ($MyInvocation.ExpectingInput) {
|
||||
$input | & "node$exe" "$basedir/../rollup/dist/bin/rollup" $args
|
||||
} else {
|
||||
& "node$exe" "$basedir/../rollup/dist/bin/rollup" $args
|
||||
}
|
||||
$ret=$LASTEXITCODE
|
||||
}
|
||||
exit $ret
|
||||
16
node_modules/.bin/semver
generated
vendored
Normal file
16
node_modules/.bin/semver
generated
vendored
Normal file
@ -0,0 +1,16 @@
|
||||
#!/bin/sh
|
||||
basedir=$(dirname "$(echo "$0" | sed -e 's,\\,/,g')")
|
||||
|
||||
case `uname` in
|
||||
*CYGWIN*|*MINGW*|*MSYS*)
|
||||
if command -v cygpath > /dev/null 2>&1; then
|
||||
basedir=`cygpath -w "$basedir"`
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
|
||||
if [ -x "$basedir/node" ]; then
|
||||
exec "$basedir/node" "$basedir/../semver/bin/semver.js" "$@"
|
||||
else
|
||||
exec node "$basedir/../semver/bin/semver.js" "$@"
|
||||
fi
|
||||
17
node_modules/.bin/semver.cmd
generated
vendored
Normal file
17
node_modules/.bin/semver.cmd
generated
vendored
Normal file
@ -0,0 +1,17 @@
|
||||
@ECHO off
|
||||
GOTO start
|
||||
:find_dp0
|
||||
SET dp0=%~dp0
|
||||
EXIT /b
|
||||
:start
|
||||
SETLOCAL
|
||||
CALL :find_dp0
|
||||
|
||||
IF EXIST "%dp0%\node.exe" (
|
||||
SET "_prog=%dp0%\node.exe"
|
||||
) ELSE (
|
||||
SET "_prog=node"
|
||||
SET PATHEXT=%PATHEXT:;.JS;=;%
|
||||
)
|
||||
|
||||
endLocal & goto #_undefined_# 2>NUL || title %COMSPEC% & "%_prog%" "%dp0%\..\semver\bin\semver.js" %*
|
||||
28
node_modules/.bin/semver.ps1
generated
vendored
Normal file
28
node_modules/.bin/semver.ps1
generated
vendored
Normal file
@ -0,0 +1,28 @@
|
||||
#!/usr/bin/env pwsh
|
||||
$basedir=Split-Path $MyInvocation.MyCommand.Definition -Parent
|
||||
|
||||
$exe=""
|
||||
if ($PSVersionTable.PSVersion -lt "6.0" -or $IsWindows) {
|
||||
# Fix case when both the Windows and Linux builds of Node
|
||||
# are installed in the same directory
|
||||
$exe=".exe"
|
||||
}
|
||||
$ret=0
|
||||
if (Test-Path "$basedir/node$exe") {
|
||||
# Support pipeline input
|
||||
if ($MyInvocation.ExpectingInput) {
|
||||
$input | & "$basedir/node$exe" "$basedir/../semver/bin/semver.js" $args
|
||||
} else {
|
||||
& "$basedir/node$exe" "$basedir/../semver/bin/semver.js" $args
|
||||
}
|
||||
$ret=$LASTEXITCODE
|
||||
} else {
|
||||
# Support pipeline input
|
||||
if ($MyInvocation.ExpectingInput) {
|
||||
$input | & "node$exe" "$basedir/../semver/bin/semver.js" $args
|
||||
} else {
|
||||
& "node$exe" "$basedir/../semver/bin/semver.js" $args
|
||||
}
|
||||
$ret=$LASTEXITCODE
|
||||
}
|
||||
exit $ret
|
||||
16
node_modules/.bin/sql-formatter
generated
vendored
Normal file
16
node_modules/.bin/sql-formatter
generated
vendored
Normal file
@ -0,0 +1,16 @@
|
||||
#!/bin/sh
|
||||
basedir=$(dirname "$(echo "$0" | sed -e 's,\\,/,g')")
|
||||
|
||||
case `uname` in
|
||||
*CYGWIN*|*MINGW*|*MSYS*)
|
||||
if command -v cygpath > /dev/null 2>&1; then
|
||||
basedir=`cygpath -w "$basedir"`
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
|
||||
if [ -x "$basedir/node" ]; then
|
||||
exec "$basedir/node" "$basedir/../sql-formatter/bin/sql-formatter-cli.cjs" "$@"
|
||||
else
|
||||
exec node "$basedir/../sql-formatter/bin/sql-formatter-cli.cjs" "$@"
|
||||
fi
|
||||
17
node_modules/.bin/sql-formatter.cmd
generated
vendored
Normal file
17
node_modules/.bin/sql-formatter.cmd
generated
vendored
Normal file
@ -0,0 +1,17 @@
|
||||
@ECHO off
|
||||
GOTO start
|
||||
:find_dp0
|
||||
SET dp0=%~dp0
|
||||
EXIT /b
|
||||
:start
|
||||
SETLOCAL
|
||||
CALL :find_dp0
|
||||
|
||||
IF EXIST "%dp0%\node.exe" (
|
||||
SET "_prog=%dp0%\node.exe"
|
||||
) ELSE (
|
||||
SET "_prog=node"
|
||||
SET PATHEXT=%PATHEXT:;.JS;=;%
|
||||
)
|
||||
|
||||
endLocal & goto #_undefined_# 2>NUL || title %COMSPEC% & "%_prog%" "%dp0%\..\sql-formatter\bin\sql-formatter-cli.cjs" %*
|
||||
28
node_modules/.bin/sql-formatter.ps1
generated
vendored
Normal file
28
node_modules/.bin/sql-formatter.ps1
generated
vendored
Normal file
@ -0,0 +1,28 @@
|
||||
#!/usr/bin/env pwsh
|
||||
$basedir=Split-Path $MyInvocation.MyCommand.Definition -Parent
|
||||
|
||||
$exe=""
|
||||
if ($PSVersionTable.PSVersion -lt "6.0" -or $IsWindows) {
|
||||
# Fix case when both the Windows and Linux builds of Node
|
||||
# are installed in the same directory
|
||||
$exe=".exe"
|
||||
}
|
||||
$ret=0
|
||||
if (Test-Path "$basedir/node$exe") {
|
||||
# Support pipeline input
|
||||
if ($MyInvocation.ExpectingInput) {
|
||||
$input | & "$basedir/node$exe" "$basedir/../sql-formatter/bin/sql-formatter-cli.cjs" $args
|
||||
} else {
|
||||
& "$basedir/node$exe" "$basedir/../sql-formatter/bin/sql-formatter-cli.cjs" $args
|
||||
}
|
||||
$ret=$LASTEXITCODE
|
||||
} else {
|
||||
# Support pipeline input
|
||||
if ($MyInvocation.ExpectingInput) {
|
||||
$input | & "node$exe" "$basedir/../sql-formatter/bin/sql-formatter-cli.cjs" $args
|
||||
} else {
|
||||
& "node$exe" "$basedir/../sql-formatter/bin/sql-formatter-cli.cjs" $args
|
||||
}
|
||||
$ret=$LASTEXITCODE
|
||||
}
|
||||
exit $ret
|
||||
16
node_modules/.bin/sucrase
generated
vendored
Normal file
16
node_modules/.bin/sucrase
generated
vendored
Normal file
@ -0,0 +1,16 @@
|
||||
#!/bin/sh
|
||||
basedir=$(dirname "$(echo "$0" | sed -e 's,\\,/,g')")
|
||||
|
||||
case `uname` in
|
||||
*CYGWIN*|*MINGW*|*MSYS*)
|
||||
if command -v cygpath > /dev/null 2>&1; then
|
||||
basedir=`cygpath -w "$basedir"`
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
|
||||
if [ -x "$basedir/node" ]; then
|
||||
exec "$basedir/node" "$basedir/../sucrase/bin/sucrase" "$@"
|
||||
else
|
||||
exec node "$basedir/../sucrase/bin/sucrase" "$@"
|
||||
fi
|
||||
16
node_modules/.bin/sucrase-node
generated
vendored
Normal file
16
node_modules/.bin/sucrase-node
generated
vendored
Normal file
@ -0,0 +1,16 @@
|
||||
#!/bin/sh
|
||||
basedir=$(dirname "$(echo "$0" | sed -e 's,\\,/,g')")
|
||||
|
||||
case `uname` in
|
||||
*CYGWIN*|*MINGW*|*MSYS*)
|
||||
if command -v cygpath > /dev/null 2>&1; then
|
||||
basedir=`cygpath -w "$basedir"`
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
|
||||
if [ -x "$basedir/node" ]; then
|
||||
exec "$basedir/node" "$basedir/../sucrase/bin/sucrase-node" "$@"
|
||||
else
|
||||
exec node "$basedir/../sucrase/bin/sucrase-node" "$@"
|
||||
fi
|
||||
17
node_modules/.bin/sucrase-node.cmd
generated
vendored
Normal file
17
node_modules/.bin/sucrase-node.cmd
generated
vendored
Normal file
@ -0,0 +1,17 @@
|
||||
@ECHO off
|
||||
GOTO start
|
||||
:find_dp0
|
||||
SET dp0=%~dp0
|
||||
EXIT /b
|
||||
:start
|
||||
SETLOCAL
|
||||
CALL :find_dp0
|
||||
|
||||
IF EXIST "%dp0%\node.exe" (
|
||||
SET "_prog=%dp0%\node.exe"
|
||||
) ELSE (
|
||||
SET "_prog=node"
|
||||
SET PATHEXT=%PATHEXT:;.JS;=;%
|
||||
)
|
||||
|
||||
endLocal & goto #_undefined_# 2>NUL || title %COMSPEC% & "%_prog%" "%dp0%\..\sucrase\bin\sucrase-node" %*
|
||||
28
node_modules/.bin/sucrase-node.ps1
generated
vendored
Normal file
28
node_modules/.bin/sucrase-node.ps1
generated
vendored
Normal file
@ -0,0 +1,28 @@
|
||||
#!/usr/bin/env pwsh
|
||||
$basedir=Split-Path $MyInvocation.MyCommand.Definition -Parent
|
||||
|
||||
$exe=""
|
||||
if ($PSVersionTable.PSVersion -lt "6.0" -or $IsWindows) {
|
||||
# Fix case when both the Windows and Linux builds of Node
|
||||
# are installed in the same directory
|
||||
$exe=".exe"
|
||||
}
|
||||
$ret=0
|
||||
if (Test-Path "$basedir/node$exe") {
|
||||
# Support pipeline input
|
||||
if ($MyInvocation.ExpectingInput) {
|
||||
$input | & "$basedir/node$exe" "$basedir/../sucrase/bin/sucrase-node" $args
|
||||
} else {
|
||||
& "$basedir/node$exe" "$basedir/../sucrase/bin/sucrase-node" $args
|
||||
}
|
||||
$ret=$LASTEXITCODE
|
||||
} else {
|
||||
# Support pipeline input
|
||||
if ($MyInvocation.ExpectingInput) {
|
||||
$input | & "node$exe" "$basedir/../sucrase/bin/sucrase-node" $args
|
||||
} else {
|
||||
& "node$exe" "$basedir/../sucrase/bin/sucrase-node" $args
|
||||
}
|
||||
$ret=$LASTEXITCODE
|
||||
}
|
||||
exit $ret
|
||||
17
node_modules/.bin/sucrase.cmd
generated
vendored
Normal file
17
node_modules/.bin/sucrase.cmd
generated
vendored
Normal file
@ -0,0 +1,17 @@
|
||||
@ECHO off
|
||||
GOTO start
|
||||
:find_dp0
|
||||
SET dp0=%~dp0
|
||||
EXIT /b
|
||||
:start
|
||||
SETLOCAL
|
||||
CALL :find_dp0
|
||||
|
||||
IF EXIST "%dp0%\node.exe" (
|
||||
SET "_prog=%dp0%\node.exe"
|
||||
) ELSE (
|
||||
SET "_prog=node"
|
||||
SET PATHEXT=%PATHEXT:;.JS;=;%
|
||||
)
|
||||
|
||||
endLocal & goto #_undefined_# 2>NUL || title %COMSPEC% & "%_prog%" "%dp0%\..\sucrase\bin\sucrase" %*
|
||||
28
node_modules/.bin/sucrase.ps1
generated
vendored
Normal file
28
node_modules/.bin/sucrase.ps1
generated
vendored
Normal file
@ -0,0 +1,28 @@
|
||||
#!/usr/bin/env pwsh
|
||||
$basedir=Split-Path $MyInvocation.MyCommand.Definition -Parent
|
||||
|
||||
$exe=""
|
||||
if ($PSVersionTable.PSVersion -lt "6.0" -or $IsWindows) {
|
||||
# Fix case when both the Windows and Linux builds of Node
|
||||
# are installed in the same directory
|
||||
$exe=".exe"
|
||||
}
|
||||
$ret=0
|
||||
if (Test-Path "$basedir/node$exe") {
|
||||
# Support pipeline input
|
||||
if ($MyInvocation.ExpectingInput) {
|
||||
$input | & "$basedir/node$exe" "$basedir/../sucrase/bin/sucrase" $args
|
||||
} else {
|
||||
& "$basedir/node$exe" "$basedir/../sucrase/bin/sucrase" $args
|
||||
}
|
||||
$ret=$LASTEXITCODE
|
||||
} else {
|
||||
# Support pipeline input
|
||||
if ($MyInvocation.ExpectingInput) {
|
||||
$input | & "node$exe" "$basedir/../sucrase/bin/sucrase" $args
|
||||
} else {
|
||||
& "node$exe" "$basedir/../sucrase/bin/sucrase" $args
|
||||
}
|
||||
$ret=$LASTEXITCODE
|
||||
}
|
||||
exit $ret
|
||||
16
node_modules/.bin/tailwind
generated
vendored
Normal file
16
node_modules/.bin/tailwind
generated
vendored
Normal file
@ -0,0 +1,16 @@
|
||||
#!/bin/sh
|
||||
basedir=$(dirname "$(echo "$0" | sed -e 's,\\,/,g')")
|
||||
|
||||
case `uname` in
|
||||
*CYGWIN*|*MINGW*|*MSYS*)
|
||||
if command -v cygpath > /dev/null 2>&1; then
|
||||
basedir=`cygpath -w "$basedir"`
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
|
||||
if [ -x "$basedir/node" ]; then
|
||||
exec "$basedir/node" "$basedir/../tailwindcss/lib/cli.js" "$@"
|
||||
else
|
||||
exec node "$basedir/../tailwindcss/lib/cli.js" "$@"
|
||||
fi
|
||||
17
node_modules/.bin/tailwind.cmd
generated
vendored
Normal file
17
node_modules/.bin/tailwind.cmd
generated
vendored
Normal file
@ -0,0 +1,17 @@
|
||||
@ECHO off
|
||||
GOTO start
|
||||
:find_dp0
|
||||
SET dp0=%~dp0
|
||||
EXIT /b
|
||||
:start
|
||||
SETLOCAL
|
||||
CALL :find_dp0
|
||||
|
||||
IF EXIST "%dp0%\node.exe" (
|
||||
SET "_prog=%dp0%\node.exe"
|
||||
) ELSE (
|
||||
SET "_prog=node"
|
||||
SET PATHEXT=%PATHEXT:;.JS;=;%
|
||||
)
|
||||
|
||||
endLocal & goto #_undefined_# 2>NUL || title %COMSPEC% & "%_prog%" "%dp0%\..\tailwindcss\lib\cli.js" %*
|
||||
28
node_modules/.bin/tailwind.ps1
generated
vendored
Normal file
28
node_modules/.bin/tailwind.ps1
generated
vendored
Normal file
@ -0,0 +1,28 @@
|
||||
#!/usr/bin/env pwsh
|
||||
$basedir=Split-Path $MyInvocation.MyCommand.Definition -Parent
|
||||
|
||||
$exe=""
|
||||
if ($PSVersionTable.PSVersion -lt "6.0" -or $IsWindows) {
|
||||
# Fix case when both the Windows and Linux builds of Node
|
||||
# are installed in the same directory
|
||||
$exe=".exe"
|
||||
}
|
||||
$ret=0
|
||||
if (Test-Path "$basedir/node$exe") {
|
||||
# Support pipeline input
|
||||
if ($MyInvocation.ExpectingInput) {
|
||||
$input | & "$basedir/node$exe" "$basedir/../tailwindcss/lib/cli.js" $args
|
||||
} else {
|
||||
& "$basedir/node$exe" "$basedir/../tailwindcss/lib/cli.js" $args
|
||||
}
|
||||
$ret=$LASTEXITCODE
|
||||
} else {
|
||||
# Support pipeline input
|
||||
if ($MyInvocation.ExpectingInput) {
|
||||
$input | & "node$exe" "$basedir/../tailwindcss/lib/cli.js" $args
|
||||
} else {
|
||||
& "node$exe" "$basedir/../tailwindcss/lib/cli.js" $args
|
||||
}
|
||||
$ret=$LASTEXITCODE
|
||||
}
|
||||
exit $ret
|
||||
16
node_modules/.bin/tailwindcss
generated
vendored
Normal file
16
node_modules/.bin/tailwindcss
generated
vendored
Normal file
@ -0,0 +1,16 @@
|
||||
#!/bin/sh
|
||||
basedir=$(dirname "$(echo "$0" | sed -e 's,\\,/,g')")
|
||||
|
||||
case `uname` in
|
||||
*CYGWIN*|*MINGW*|*MSYS*)
|
||||
if command -v cygpath > /dev/null 2>&1; then
|
||||
basedir=`cygpath -w "$basedir"`
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
|
||||
if [ -x "$basedir/node" ]; then
|
||||
exec "$basedir/node" "$basedir/../tailwindcss/lib/cli.js" "$@"
|
||||
else
|
||||
exec node "$basedir/../tailwindcss/lib/cli.js" "$@"
|
||||
fi
|
||||
17
node_modules/.bin/tailwindcss.cmd
generated
vendored
Normal file
17
node_modules/.bin/tailwindcss.cmd
generated
vendored
Normal file
@ -0,0 +1,17 @@
|
||||
@ECHO off
|
||||
GOTO start
|
||||
:find_dp0
|
||||
SET dp0=%~dp0
|
||||
EXIT /b
|
||||
:start
|
||||
SETLOCAL
|
||||
CALL :find_dp0
|
||||
|
||||
IF EXIST "%dp0%\node.exe" (
|
||||
SET "_prog=%dp0%\node.exe"
|
||||
) ELSE (
|
||||
SET "_prog=node"
|
||||
SET PATHEXT=%PATHEXT:;.JS;=;%
|
||||
)
|
||||
|
||||
endLocal & goto #_undefined_# 2>NUL || title %COMSPEC% & "%_prog%" "%dp0%\..\tailwindcss\lib\cli.js" %*
|
||||
28
node_modules/.bin/tailwindcss.ps1
generated
vendored
Normal file
28
node_modules/.bin/tailwindcss.ps1
generated
vendored
Normal file
@ -0,0 +1,28 @@
|
||||
#!/usr/bin/env pwsh
|
||||
$basedir=Split-Path $MyInvocation.MyCommand.Definition -Parent
|
||||
|
||||
$exe=""
|
||||
if ($PSVersionTable.PSVersion -lt "6.0" -or $IsWindows) {
|
||||
# Fix case when both the Windows and Linux builds of Node
|
||||
# are installed in the same directory
|
||||
$exe=".exe"
|
||||
}
|
||||
$ret=0
|
||||
if (Test-Path "$basedir/node$exe") {
|
||||
# Support pipeline input
|
||||
if ($MyInvocation.ExpectingInput) {
|
||||
$input | & "$basedir/node$exe" "$basedir/../tailwindcss/lib/cli.js" $args
|
||||
} else {
|
||||
& "$basedir/node$exe" "$basedir/../tailwindcss/lib/cli.js" $args
|
||||
}
|
||||
$ret=$LASTEXITCODE
|
||||
} else {
|
||||
# Support pipeline input
|
||||
if ($MyInvocation.ExpectingInput) {
|
||||
$input | & "node$exe" "$basedir/../tailwindcss/lib/cli.js" $args
|
||||
} else {
|
||||
& "node$exe" "$basedir/../tailwindcss/lib/cli.js" $args
|
||||
}
|
||||
$ret=$LASTEXITCODE
|
||||
}
|
||||
exit $ret
|
||||
16
node_modules/.bin/tsc
generated
vendored
Normal file
16
node_modules/.bin/tsc
generated
vendored
Normal file
@ -0,0 +1,16 @@
|
||||
#!/bin/sh
|
||||
basedir=$(dirname "$(echo "$0" | sed -e 's,\\,/,g')")
|
||||
|
||||
case `uname` in
|
||||
*CYGWIN*|*MINGW*|*MSYS*)
|
||||
if command -v cygpath > /dev/null 2>&1; then
|
||||
basedir=`cygpath -w "$basedir"`
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
|
||||
if [ -x "$basedir/node" ]; then
|
||||
exec "$basedir/node" "$basedir/../typescript/bin/tsc" "$@"
|
||||
else
|
||||
exec node "$basedir/../typescript/bin/tsc" "$@"
|
||||
fi
|
||||
17
node_modules/.bin/tsc.cmd
generated
vendored
Normal file
17
node_modules/.bin/tsc.cmd
generated
vendored
Normal file
@ -0,0 +1,17 @@
|
||||
@ECHO off
|
||||
GOTO start
|
||||
:find_dp0
|
||||
SET dp0=%~dp0
|
||||
EXIT /b
|
||||
:start
|
||||
SETLOCAL
|
||||
CALL :find_dp0
|
||||
|
||||
IF EXIST "%dp0%\node.exe" (
|
||||
SET "_prog=%dp0%\node.exe"
|
||||
) ELSE (
|
||||
SET "_prog=node"
|
||||
SET PATHEXT=%PATHEXT:;.JS;=;%
|
||||
)
|
||||
|
||||
endLocal & goto #_undefined_# 2>NUL || title %COMSPEC% & "%_prog%" "%dp0%\..\typescript\bin\tsc" %*
|
||||
28
node_modules/.bin/tsc.ps1
generated
vendored
Normal file
28
node_modules/.bin/tsc.ps1
generated
vendored
Normal file
@ -0,0 +1,28 @@
|
||||
#!/usr/bin/env pwsh
|
||||
$basedir=Split-Path $MyInvocation.MyCommand.Definition -Parent
|
||||
|
||||
$exe=""
|
||||
if ($PSVersionTable.PSVersion -lt "6.0" -or $IsWindows) {
|
||||
# Fix case when both the Windows and Linux builds of Node
|
||||
# are installed in the same directory
|
||||
$exe=".exe"
|
||||
}
|
||||
$ret=0
|
||||
if (Test-Path "$basedir/node$exe") {
|
||||
# Support pipeline input
|
||||
if ($MyInvocation.ExpectingInput) {
|
||||
$input | & "$basedir/node$exe" "$basedir/../typescript/bin/tsc" $args
|
||||
} else {
|
||||
& "$basedir/node$exe" "$basedir/../typescript/bin/tsc" $args
|
||||
}
|
||||
$ret=$LASTEXITCODE
|
||||
} else {
|
||||
# Support pipeline input
|
||||
if ($MyInvocation.ExpectingInput) {
|
||||
$input | & "node$exe" "$basedir/../typescript/bin/tsc" $args
|
||||
} else {
|
||||
& "node$exe" "$basedir/../typescript/bin/tsc" $args
|
||||
}
|
||||
$ret=$LASTEXITCODE
|
||||
}
|
||||
exit $ret
|
||||
16
node_modules/.bin/tsserver
generated
vendored
Normal file
16
node_modules/.bin/tsserver
generated
vendored
Normal file
@ -0,0 +1,16 @@
|
||||
#!/bin/sh
|
||||
basedir=$(dirname "$(echo "$0" | sed -e 's,\\,/,g')")
|
||||
|
||||
case `uname` in
|
||||
*CYGWIN*|*MINGW*|*MSYS*)
|
||||
if command -v cygpath > /dev/null 2>&1; then
|
||||
basedir=`cygpath -w "$basedir"`
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
|
||||
if [ -x "$basedir/node" ]; then
|
||||
exec "$basedir/node" "$basedir/../typescript/bin/tsserver" "$@"
|
||||
else
|
||||
exec node "$basedir/../typescript/bin/tsserver" "$@"
|
||||
fi
|
||||
17
node_modules/.bin/tsserver.cmd
generated
vendored
Normal file
17
node_modules/.bin/tsserver.cmd
generated
vendored
Normal file
@ -0,0 +1,17 @@
|
||||
@ECHO off
|
||||
GOTO start
|
||||
:find_dp0
|
||||
SET dp0=%~dp0
|
||||
EXIT /b
|
||||
:start
|
||||
SETLOCAL
|
||||
CALL :find_dp0
|
||||
|
||||
IF EXIST "%dp0%\node.exe" (
|
||||
SET "_prog=%dp0%\node.exe"
|
||||
) ELSE (
|
||||
SET "_prog=node"
|
||||
SET PATHEXT=%PATHEXT:;.JS;=;%
|
||||
)
|
||||
|
||||
endLocal & goto #_undefined_# 2>NUL || title %COMSPEC% & "%_prog%" "%dp0%\..\typescript\bin\tsserver" %*
|
||||
28
node_modules/.bin/tsserver.ps1
generated
vendored
Normal file
28
node_modules/.bin/tsserver.ps1
generated
vendored
Normal file
@ -0,0 +1,28 @@
|
||||
#!/usr/bin/env pwsh
|
||||
$basedir=Split-Path $MyInvocation.MyCommand.Definition -Parent
|
||||
|
||||
$exe=""
|
||||
if ($PSVersionTable.PSVersion -lt "6.0" -or $IsWindows) {
|
||||
# Fix case when both the Windows and Linux builds of Node
|
||||
# are installed in the same directory
|
||||
$exe=".exe"
|
||||
}
|
||||
$ret=0
|
||||
if (Test-Path "$basedir/node$exe") {
|
||||
# Support pipeline input
|
||||
if ($MyInvocation.ExpectingInput) {
|
||||
$input | & "$basedir/node$exe" "$basedir/../typescript/bin/tsserver" $args
|
||||
} else {
|
||||
& "$basedir/node$exe" "$basedir/../typescript/bin/tsserver" $args
|
||||
}
|
||||
$ret=$LASTEXITCODE
|
||||
} else {
|
||||
# Support pipeline input
|
||||
if ($MyInvocation.ExpectingInput) {
|
||||
$input | & "node$exe" "$basedir/../typescript/bin/tsserver" $args
|
||||
} else {
|
||||
& "node$exe" "$basedir/../typescript/bin/tsserver" $args
|
||||
}
|
||||
$ret=$LASTEXITCODE
|
||||
}
|
||||
exit $ret
|
||||
16
node_modules/.bin/update-browserslist-db
generated
vendored
Normal file
16
node_modules/.bin/update-browserslist-db
generated
vendored
Normal file
@ -0,0 +1,16 @@
|
||||
#!/bin/sh
|
||||
basedir=$(dirname "$(echo "$0" | sed -e 's,\\,/,g')")
|
||||
|
||||
case `uname` in
|
||||
*CYGWIN*|*MINGW*|*MSYS*)
|
||||
if command -v cygpath > /dev/null 2>&1; then
|
||||
basedir=`cygpath -w "$basedir"`
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
|
||||
if [ -x "$basedir/node" ]; then
|
||||
exec "$basedir/node" "$basedir/../update-browserslist-db/cli.js" "$@"
|
||||
else
|
||||
exec node "$basedir/../update-browserslist-db/cli.js" "$@"
|
||||
fi
|
||||
17
node_modules/.bin/update-browserslist-db.cmd
generated
vendored
Normal file
17
node_modules/.bin/update-browserslist-db.cmd
generated
vendored
Normal file
@ -0,0 +1,17 @@
|
||||
@ECHO off
|
||||
GOTO start
|
||||
:find_dp0
|
||||
SET dp0=%~dp0
|
||||
EXIT /b
|
||||
:start
|
||||
SETLOCAL
|
||||
CALL :find_dp0
|
||||
|
||||
IF EXIST "%dp0%\node.exe" (
|
||||
SET "_prog=%dp0%\node.exe"
|
||||
) ELSE (
|
||||
SET "_prog=node"
|
||||
SET PATHEXT=%PATHEXT:;.JS;=;%
|
||||
)
|
||||
|
||||
endLocal & goto #_undefined_# 2>NUL || title %COMSPEC% & "%_prog%" "%dp0%\..\update-browserslist-db\cli.js" %*
|
||||
28
node_modules/.bin/update-browserslist-db.ps1
generated
vendored
Normal file
28
node_modules/.bin/update-browserslist-db.ps1
generated
vendored
Normal file
@ -0,0 +1,28 @@
|
||||
#!/usr/bin/env pwsh
|
||||
$basedir=Split-Path $MyInvocation.MyCommand.Definition -Parent
|
||||
|
||||
$exe=""
|
||||
if ($PSVersionTable.PSVersion -lt "6.0" -or $IsWindows) {
|
||||
# Fix case when both the Windows and Linux builds of Node
|
||||
# are installed in the same directory
|
||||
$exe=".exe"
|
||||
}
|
||||
$ret=0
|
||||
if (Test-Path "$basedir/node$exe") {
|
||||
# Support pipeline input
|
||||
if ($MyInvocation.ExpectingInput) {
|
||||
$input | & "$basedir/node$exe" "$basedir/../update-browserslist-db/cli.js" $args
|
||||
} else {
|
||||
& "$basedir/node$exe" "$basedir/../update-browserslist-db/cli.js" $args
|
||||
}
|
||||
$ret=$LASTEXITCODE
|
||||
} else {
|
||||
# Support pipeline input
|
||||
if ($MyInvocation.ExpectingInput) {
|
||||
$input | & "node$exe" "$basedir/../update-browserslist-db/cli.js" $args
|
||||
} else {
|
||||
& "node$exe" "$basedir/../update-browserslist-db/cli.js" $args
|
||||
}
|
||||
$ret=$LASTEXITCODE
|
||||
}
|
||||
exit $ret
|
||||
16
node_modules/.bin/vite
generated
vendored
Normal file
16
node_modules/.bin/vite
generated
vendored
Normal file
@ -0,0 +1,16 @@
|
||||
#!/bin/sh
|
||||
basedir=$(dirname "$(echo "$0" | sed -e 's,\\,/,g')")
|
||||
|
||||
case `uname` in
|
||||
*CYGWIN*|*MINGW*|*MSYS*)
|
||||
if command -v cygpath > /dev/null 2>&1; then
|
||||
basedir=`cygpath -w "$basedir"`
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
|
||||
if [ -x "$basedir/node" ]; then
|
||||
exec "$basedir/node" "$basedir/../vite/bin/vite.js" "$@"
|
||||
else
|
||||
exec node "$basedir/../vite/bin/vite.js" "$@"
|
||||
fi
|
||||
17
node_modules/.bin/vite.cmd
generated
vendored
Normal file
17
node_modules/.bin/vite.cmd
generated
vendored
Normal file
@ -0,0 +1,17 @@
|
||||
@ECHO off
|
||||
GOTO start
|
||||
:find_dp0
|
||||
SET dp0=%~dp0
|
||||
EXIT /b
|
||||
:start
|
||||
SETLOCAL
|
||||
CALL :find_dp0
|
||||
|
||||
IF EXIST "%dp0%\node.exe" (
|
||||
SET "_prog=%dp0%\node.exe"
|
||||
) ELSE (
|
||||
SET "_prog=node"
|
||||
SET PATHEXT=%PATHEXT:;.JS;=;%
|
||||
)
|
||||
|
||||
endLocal & goto #_undefined_# 2>NUL || title %COMSPEC% & "%_prog%" "%dp0%\..\vite\bin\vite.js" %*
|
||||
28
node_modules/.bin/vite.ps1
generated
vendored
Normal file
28
node_modules/.bin/vite.ps1
generated
vendored
Normal file
@ -0,0 +1,28 @@
|
||||
#!/usr/bin/env pwsh
|
||||
$basedir=Split-Path $MyInvocation.MyCommand.Definition -Parent
|
||||
|
||||
$exe=""
|
||||
if ($PSVersionTable.PSVersion -lt "6.0" -or $IsWindows) {
|
||||
# Fix case when both the Windows and Linux builds of Node
|
||||
# are installed in the same directory
|
||||
$exe=".exe"
|
||||
}
|
||||
$ret=0
|
||||
if (Test-Path "$basedir/node$exe") {
|
||||
# Support pipeline input
|
||||
if ($MyInvocation.ExpectingInput) {
|
||||
$input | & "$basedir/node$exe" "$basedir/../vite/bin/vite.js" $args
|
||||
} else {
|
||||
& "$basedir/node$exe" "$basedir/../vite/bin/vite.js" $args
|
||||
}
|
||||
$ret=$LASTEXITCODE
|
||||
} else {
|
||||
# Support pipeline input
|
||||
if ($MyInvocation.ExpectingInput) {
|
||||
$input | & "node$exe" "$basedir/../vite/bin/vite.js" $args
|
||||
} else {
|
||||
& "node$exe" "$basedir/../vite/bin/vite.js" $args
|
||||
}
|
||||
$ret=$LASTEXITCODE
|
||||
}
|
||||
exit $ret
|
||||
16
node_modules/.bin/xlsx
generated
vendored
Normal file
16
node_modules/.bin/xlsx
generated
vendored
Normal file
@ -0,0 +1,16 @@
|
||||
#!/bin/sh
|
||||
basedir=$(dirname "$(echo "$0" | sed -e 's,\\,/,g')")
|
||||
|
||||
case `uname` in
|
||||
*CYGWIN*|*MINGW*|*MSYS*)
|
||||
if command -v cygpath > /dev/null 2>&1; then
|
||||
basedir=`cygpath -w "$basedir"`
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
|
||||
if [ -x "$basedir/node" ]; then
|
||||
exec "$basedir/node" "$basedir/../xlsx/bin/xlsx.njs" "$@"
|
||||
else
|
||||
exec node "$basedir/../xlsx/bin/xlsx.njs" "$@"
|
||||
fi
|
||||
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue
Block a user