0
Fork 0
mirror of https://github.com/withastro/astro.git synced 2025-01-06 22:10:10 -05:00

[ci] format

This commit is contained in:
Ben Holmes 2024-03-07 18:39:47 +00:00 committed by astrobot-houston
parent 06fe94e29d
commit e086a9f8c8
4 changed files with 10 additions and 10 deletions

View file

@ -2,14 +2,14 @@ import type { AstroConfig } from 'astro';
import { sql } from 'drizzle-orm';
import type { Arguments } from 'yargs-parser';
import {
createRemoteDatabaseClient,
createLocalDatabaseClient,
createRemoteDatabaseClient,
} from '../../../../runtime/db-client.js';
import { DB_PATH } from '../../../consts.js';
import { SHELL_QUERY_MISSING_ERROR } from '../../../errors.js';
import { getManagedAppTokenOrExit } from '../../../tokens.js';
import type { DBConfigInput } from '../../../types.js';
import { getRemoteDatabaseUrl } from '../../../utils.js';
import { DB_PATH } from '../../../consts.js';
import { SHELL_QUERY_MISSING_ERROR } from '../../../errors.js';
export async function cmd({
flags,

View file

@ -4,6 +4,7 @@ import { fileURLToPath } from 'url';
import type { AstroIntegration } from 'astro';
import { mkdir, rm, writeFile } from 'fs/promises';
import { blue, yellow } from 'kleur/colors';
import parseArgs from 'yargs-parser';
import { CONFIG_FILE_NAMES, DB_PATH } from '../consts.js';
import { loadDbConfigFile } from '../load-file.js';
import { type ManagedAppToken, getManagedAppTokenOrExit } from '../tokens.js';
@ -14,7 +15,6 @@ import { fileURLIntegration } from './file-url.js';
import { typegen } from './typegen.js';
import { type LateTables, vitePluginDb } from './vite-plugin-db.js';
import { vitePluginInjectEnvTs } from './vite-plugin-inject-env-ts.js';
import parseArgs from 'yargs-parser';
function astroDBIntegration(): AstroIntegration {
let connectToStudio = false;

View file

@ -1,5 +1,9 @@
import { fileURLToPath } from 'node:url';
import { type SQL, sql } from 'drizzle-orm';
import { SQLiteAsyncDialect } from 'drizzle-orm/sqlite-core';
import { normalizePath } from 'vite';
import { createLocalDatabaseClient } from '../../runtime/db-client.js';
import type { SqliteDB } from '../../runtime/index.js';
import {
SEED_DEV_FILE_NAME,
getCreateIndexQueries,
@ -8,10 +12,6 @@ import {
import { DB_PATH, RUNTIME_CONFIG_IMPORT, RUNTIME_IMPORT, VIRTUAL_MODULE_ID } from '../consts.js';
import type { DBTables } from '../types.js';
import { type VitePlugin, getDbDirectoryUrl, getRemoteDatabaseUrl } from '../utils.js';
import { createLocalDatabaseClient } from '../../runtime/db-client.js';
import { type SQL, sql } from 'drizzle-orm';
import type { SqliteDB } from '../../runtime/index.js';
import { SQLiteAsyncDialect } from 'drizzle-orm/sqlite-core';
const WITH_SEED_VIRTUAL_MODULE_ID = 'astro:db:seed';

View file

@ -1,3 +1,4 @@
import { LibsqlError } from '@libsql/client';
import { type ColumnBuilderBaseConfig, type ColumnDataType, sql } from 'drizzle-orm';
import type { LibSQLDatabase } from 'drizzle-orm/libsql';
import {
@ -9,10 +10,9 @@ import {
sqliteTable,
text,
} from 'drizzle-orm/sqlite-core';
import { SEED_DEFAULT_EXPORT_ERROR, SEED_ERROR } from '../core/errors.js';
import { type DBColumn, type DBTable } from '../core/types.js';
import { type SerializedSQL, isSerializedSQL } from './types.js';
import { SEED_DEFAULT_EXPORT_ERROR, SEED_ERROR } from '../core/errors.js';
import { LibsqlError } from '@libsql/client';
export { sql };
export type SqliteDB = LibSQLDatabase;