{"id":13469462,"url":"https://github.com/nicoalbanese/kirimase","last_synced_at":"2025-04-11T06:27:55.501Z","repository":{"id":186119416,"uuid":"674657039","full_name":"nicoalbanese/kirimase","owner":"nicoalbanese","description":"Build full-stack Next.js apps, incredibly fast","archived":false,"fork":false,"pushed_at":"2024-09-18T08:46:52.000Z","size":710,"stargazers_count":2725,"open_issues_count":90,"forks_count":125,"subscribers_count":28,"default_branch":"master","last_synced_at":"2025-03-27T08:06:03.908Z","etag":null,"topics":["authjs","clerk","cli","drizzle","drizzleorm","lucia-auth","nextauth","nextjs","nextjs13","prisma","rails","resend","shadcn","shadcn-ui"],"latest_commit_sha":null,"homepage":"https://kirimase.dev","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/nicoalbanese.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2023-08-04T13:18:55.000Z","updated_at":"2025-03-27T05:46:56.000Z","dependencies_parsed_at":null,"dependency_job_id":"4f52c6ba-65cc-49fb-93bd-a38ad453ec4a","html_url":"https://github.com/nicoalbanese/kirimase","commit_stats":{"total_commits":401,"total_committers":23,"mean_commits":"17.434782608695652","dds":"0.11471321695760595","last_synced_commit":"b4a11e08d721b262a687780f2227d67eb8547fcf"},"previous_names":["nicoalbanese/kirimase"],"tags_count":29,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nicoalbanese%2Fkirimase","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nicoalbanese%2Fkirimase/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nicoalbanese%2Fkirimase/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nicoalbanese%2Fkirimase/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/nicoalbanese","download_url":"https://codeload.github.com/nicoalbanese/kirimase/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246970318,"owners_count":20862509,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["authjs","clerk","cli","drizzle","drizzleorm","lucia-auth","nextauth","nextjs","nextjs13","prisma","rails","resend","shadcn","shadcn-ui"],"created_at":"2024-07-31T15:01:40.959Z","updated_at":"2025-04-03T09:07:01.551Z","avatar_url":"https://github.com/nicoalbanese.png","language":"TypeScript","funding_links":[],"categories":["TypeScript","Templates","cli","Tools","Tools \u0026 Utilities"],"sub_categories":["Community"],"readme":"\u003e [!NOTE]  \n\u003e Note: Only critical bugs are being addressed right now as we are planning a complete rewrite in the very near future!\n\n\u003cp align=\"center\"\u003e\n  \u003cpicture\u003e\n  \u003cimg src=\"https://github.com/nicoalbanese/gifs_for_demos/blob/main/samurai-helmet.png?raw=true\" width=\"130\" alt=\"Logo for Kirimase\"\u003e\n\u003c/picture\u003e\n\u003c/p\u003e\n\n\u003ch1 align=\"center\"\u003e\n  Kirimase\n\u003c/h1\u003e\n\u003cp align=\"center\"\u003e\n\u003cimg src=\"https://img.shields.io/npm/v/kirimase?style=flat-square\" alt=\"npm_version\"\u003e\n\u003c/p\u003e\n\n\u003cp align=\"center\"\u003eKirimase is a command-line tool for \u003cstrong\u003ebuilding full-stack Next.js apps faster\u003c/strong\u003e. It supercharges your development workflow, allowing you to quickly integrate packages and scaffold resources for your application with best practices in mind.\u003c/p\u003e\n\n\u003cbr /\u003e\n\u003ca href=\"https://www.youtube.com/watch?v=33jlErS3Wxg\" target=\"_blank\"\u003e\n  \u003cp align=\"center\"\u003e\n    \u003cimg src=\"https://github.com/nicoalbanese/gifs_for_demos/blob/main/Screenshot%202023-10-15%20at%2010.36.02.png?raw=true\" alt=\"Kirimase Demo\" width=\"420\" /\u003e\n  \u003c/p\u003e\n\u003c/a\u003e\n\u003ca href=\"https://www.youtube.com/watch?v=33jlErS3Wxg\" target=\"_blank\"\u003e\n  \u003cp align=\"center\"\u003eWatch the most recent demo here\u003c/p\u003e\n\u003c/a\u003e\n\n\u003ca href=\"https://kirimase.dev/the-tutorial\" target=\"_blank\"\u003e\n  \u003cp align=\"center\"\u003eCheck out the official tutorial here\u003c/p\u003e\n\u003c/a\u003e\n\n## Features\n\n1. **Initialization and Configuration**: quickly add and set up essential packages to jump-start your Next.js project.\n2. **Code Generation**: scaffold models, views, and controllers directly from the CLI.\n\n\u003cbr /\u003e\n\n## Quick Start\n\nInstall Kirimase CLI globally:\n\n```bash\nnpm install -g kirimase\n```\n\n\u003cbr /\u003e\n\nIf you don't already have a Nextjs app, run create-next-app with your preferred package manager.\n\nThen run the following command within the directory of your project:\n\n```bash\nkirimase init\n```\n\nNote: Kirimase is not compatible with the the pages directory.\n\n# Commands\n\nRun these commands within the directory of your Nextjs app:\n\n### 1. `kirimase add`\n\nInitializes and configures the following packages for your Next.js project, categorized into:\n\n### ORM\n\n#### Drizzle-ORM\n\n- Based on your chosen database type (PostgreSQL, MySQL, SQLite), Kirimase sets up the required files for [Drizzle-ORM](https://github.com/drizzle-team/drizzle-orm), [drizzle-zod](https://github.com/drizzle-team/drizzle-orm/blob/main/drizzle-zod/README.md) for validations and and [drizzle-kit](https://github.com/drizzle-team/drizzle-kit-mirror) to manage migrations.\n- Scripts are auto-added to `package.json` for immediate use of drizzle-kit.\n\n#### Prisma\n\n- Kirimase sets up required files for [Prisma](https://github.com/prisma/prisma) with [zod-prisma](https://github.com/CarterGrimmeisen/zod-prisma) for validations.\n\n---\n\n### Authentication\n\n#### Auth.js\n\n- Generates files for [Auth.js](https://github.com/nextauthjs/next-auth) (Next-Auth), including the latest Drizzle adapter. (For PlanetScale, references are excluded as it doesn't support foreign keys).\n- Generates a generic sign-in component for immediate use within your Next.js project.\n- Wraps the root layout with the auth provider and generates utilities for auth checks and redirects in your Next.js routes.\n\n#### Clerk\n\n- Generates files for [Clerk](https://github.com/clerkinc/javascript) including all necessary config.\n- Wraps the root layout with the auth provider and generates utilities for auth checks and redirects in your Next.js routes.\n\n#### Lucia\n\n- Generates files for [Lucia](https://github.com/lucia-auth/lucia) including all necessary config.\n- Generates UI and API routes for sign-in and sign-up\n\n#### Kinde\n\n- Generates files for [Kinde](https://github.com/kinde-oss/kinde-auth-nextjs) including all necessary config.\n- Generates sign in component and route handler\n\n---\n\n### Other\n\n#### tRPC\n\n- Generates files to configure [tRPC](https://github.com/trpc/trpc) with the app router.\n- Provides client-side tRPC and scaffolds server-side configuration using the experimental server-invoker pattern.\n- Wraps the root layout in the tRPC provider.\n\n#### Shadcn-UI\n\n- Installs and configures [Shadcn-UI](https://github.com/shadcn-ui/ui) including button and toast components.\n- Inserts the toast-provider (`\u003cToaster /\u003e`) to the root layout for instant toast notifications in your Next.js app.\n\n#### Stripe\n\n- Installs and configures Stripe within your Next.js project so you can start accepting subscription payments.\n\n#### Resend\n\n- Installs and configures [Resend](https://resend.com/)\n\nKirimase also adds relevant keys to your `.env` which you'll need to provide values for.\n\n\u003cbr /\u003e\n\n## 2. `kirimase generate`\n\nAkin to `rails scaffold` but for Next.js:\n\n![](https://github.com/nicoalbanese/gifs_for_demos/blob/main/gif_generate_script_1.gif?raw=true)\n\n![](https://github.com/nicoalbanese/gifs_for_demos/blob/main/gif_generate_script_2.gif?raw=true)\n\nKirimase generates:\n\n#### a) Model:\n\n- Generates a drizzle schema with column types based on your SQL flavor and database provider.\n- Uses drizzle-zod to generate Zod schemas for frontend and backend validation.\n- Generates queries and mutations for CRUD operations, fully typed and optimized for consumption via a Next.js front-end.\n\n#### b) Controller:\n\n- Gives you an option to scaffold tRPC, Server Actions and/or API routes.\n- Uses Zod schemas from models for request validation.\n- Includes built-in error handling for API routes and auto-adding of tRPC routes to the root router.\n\n#### c) Views:\n\n- Scaffolds views using Shadcn-UI to enable immediate CRUD operations (including select fields for adding relations and datepickers for dates).\n- Option to use either React Hook Form with tRPC or plain React (useOptimistic and useValidated Form hooks)\n\n## Run in non-interactive mode\n\nAs of v0.0.23, you can run `kirimase init` and `kirimase add` entirely via the command line as follows:\n\n```sh\nkirimase init -sf yes -pm bun --orm prisma -db pg -a next-auth -ap github discord -mp trpc stripe resend -cl shadcn-ui -ie yes\n```\n\n| Command | Short Flag | Long Option       | Description                                    | Argument          |\n| ------- | ---------- | ----------------- | ---------------------------------------------- | ----------------- |\n| init    | -          | -                 | initialise and configure kirimase              | -                 |\n| -       | -h         | --headless        | initialise without any ui                      | `yes` or `no`     |\n| -       | -sf        | --src-folder      | use a src folder                               | `yes` or `no`     |\n| -       | -pm        | --package-manager | package manager                                | `\u003cpm\u003e`            |\n| -       | -cl        | --component-lib   | component library                              | `\u003ccomponent-lib\u003e` |\n| -       | -o         | --orm             | orm                                            | `\u003corm\u003e`           |\n| -       | -db        | --db              | database (\"pg\", \"mysql\", \"sqlite\")             | `\u003cdb\u003e`            |\n| -       | -dbp       | --db-provider     | database provider - important if using drizzle | `\u003cdbp\u003e`           |\n| -       | -a         | --auth            | auth                                           | `\u003cauth\u003e`          |\n| -       | -ap        | --auth-providers  | auth providers (if using next-auth)            | `\u003cproviders\u003e`     |\n| -       | -mp        | --misc-packages   | packages (\"trpc\", \"shadcn-ui\", \"resend\")       | `\u003cpackages\u003e`      |\n| -       | -ie        | --include-example | include example                                | `yes` or `no`     |\n\n## Contributing\n\nKeen on enhancing Kirimase? Contributions, bug reports, and feature requests are always welcome. Feel free to open an issue or submit a pull request.\n\nTo run locally:\n\n```sh\npnpm i\npnpm run dev\n\nnpm install -g . (in a second terminal - this will then make kirimase available across your machine using \"kirimase *command*\")\n```\n\n## License\n\n[MIT](LICENSE)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnicoalbanese%2Fkirimase","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fnicoalbanese%2Fkirimase","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnicoalbanese%2Fkirimase/lists"}