Skip to content

Instantly share code, notes, and snippets.

View DannyStreur's full-sized avatar

Danny Streur DannyStreur

View GitHub Profile
@wycks
wycks / Monokai-PhpStorm-Base.xml
Last active December 10, 2015 06:08
Monokai theme for PhpStorm that fits closer to the sublime2 soda dark version.
<?xml version="1.0" encoding="UTF-8"?>
<scheme name="Monokai-Custom" version="1" parent_scheme="Default">
<option name="LINE_SPACING" value="1.0" />
<option name="EDITOR_FONT_SIZE" value="16" />
<option name="EDITOR_FONT_NAME" value="Consolas" />
<colors>
<option name="CARET_COLOR" value="f8f8f0" />
<option name="CARET_ROW_COLOR" value="3e3d32" />
<option name="CONSOLE_BACKGROUND_KEY" value="272822" />
<option name="GUTTER_BACKGROUND" value="272822" />
@stevenaanen
stevenaanen / convert-casing-after-prisma-pull.mjs
Last active November 7, 2023 14:52
Transform Prisma Schema to js-friendly names
// @ts-check
/*
* Run using `node convert-casing-after-prisma-pull.mjs` after installing `change-case` in your workspace.
* Then pipe your schema into it.
*
* Script will normalize the model names, field names and enums.
* It should not affect your database schema, only the generated js client from Prisma.
*
* Tip: after processing, run `prisma format` on the file.
*/
@cayter
cayter / repository.ts
Last active July 8, 2024 22:41
Drizzle ORM Type-Safe Repository With PgTable
import { startSpan } from "@sentry/remix";
import type { StartSpanOptions } from "@sentry/types";
import {
type AnyColumn,
type AnyTable,
type BuildQueryResult,
type DBQueryConfig,
type DrizzleTypeError,
type Equal,
type ExtractTablesWithRelations,