https://github.com/liuzhch1/paste-bin
A nice looking Pastebin that just works great. Play with the demo ↓ https://paste-bin.demos.liuzhch1.com/
https://github.com/liuzhch1/paste-bin
docker fusejs monaco-editor nuxt pastebin prisma-orm self-hosted shiki
Last synced: 9 months ago
JSON representation
A nice looking Pastebin that just works great. Play with the demo ↓ https://paste-bin.demos.liuzhch1.com/
- Host: GitHub
- URL: https://github.com/liuzhch1/paste-bin
- Owner: liuzhch1
- Archived: true
- Created: 2024-10-02T08:41:21.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2024-12-12T13:14:36.000Z (over 1 year ago)
- Last Synced: 2025-03-14T23:11:14.324Z (over 1 year ago)
- Topics: docker, fusejs, monaco-editor, nuxt, pastebin, prisma-orm, self-hosted, shiki
- Language: Vue
- Homepage: https://paste-bin.demos.liuzhch1.com/
- Size: 444 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# J's Pastebin
It's too annoying to send code snippet files through Airdrop or whatever, so I made this.
Try it out: https://paste-bin.demos.liuzhch1.com/
## Features
- Dark / Light mode
- Code highlight with themes
- Really short paste link, starting with one letter: `/pastes/a`
- VSCode like editor(Monaco)
- Search all pastes
- Nice looking UI
- Export data supported
## Screenshot

## Deploy
### With Docker
```sh
docker build -t pastebin .
docker run -d -p 3000:3000 pastebin
```
The sqlite file stored in the docker container.
### Locally
```sh
pnpm install
pnpm build
export DATABASE_URL="file:/path/to/sqlite.db"
pnpm prisma generate
pnpm prisma migrate deploy
node .output/server/index.mjs
```
## Tech stack
- [Nuxt 3](https://nuxt.com/) for the frontend and simple backend. [Nuxt UI](https://ui.nuxt.com/) and [Color-Mode](https://color-mode.nuxtjs.org/) plugins are used
- [Monaco Editor](https://microsoft.github.io/monaco-editor/) for the code editor
- [Shiki](https://shiki.matsu.io/) for the syntax highlighting
- [Fuse.js](https://fusejs.io/) for the search functionality
- [Prisma](https://prisma.io/) for the database ORM with SQLite
## Development
```sh
pnpm install
pnpm dev
```
[](https://hits.seeyoufarm.com)