Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 15 additions & 8 deletions .env.example
Original file line number Diff line number Diff line change
@@ -1,8 +1,15 @@
NEXT_PUBLIC_BASE_URL=
AUTH_SECRET=

# Supabase
NEXT_PUBLIC_SUPABASE_URL=
NEXT_PUBLIC_SUPABASE_ANON_KEY=


NEXT_PUBLIC_BASE_URL=http://localhost:3000

# next-auth
AUTH_SECRET=
AUTH_RESEND_KEY=

# Database
POSTGRES_URL=
POSTGRES_PRISMA_URL=
POSTGRES_URL_NO_SSL=
POSTGRES_URL_NON_POOLING=
POSTGRES_USER=
POSTGRES_HOST=
POSTGRES_PASSWORD=
POSTGRES_DATABASE=
79 changes: 43 additions & 36 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,36 +1,43 @@
# See https://help.github.com/articles/ignoring-files/ for more about ignoring files.

# dependencies
/node_modules
/.pnp
.pnp.js
.yarn/install-state.gz

# testing
/coverage

# next.js
/.next/
/out/

# production
/build

# misc
.DS_Store
*.pem

# debug
npm-debug.log*
yarn-debug.log*
yarn-error.log*

# local env files
.env*.local

# vercel
.vercel

# typescript
*.tsbuildinfo
next-env.d.ts
# See https://help.github.com/articles/ignoring-files/ for more about ignoring files.

# dependencies
/node_modules
/.pnp
.pnp.js
.yarn/install-state.gz

# testing
/coverage

# next.js
/.next/
/out/

# production
/build

# misc
.DS_Store
*.pem

# debug
npm-debug.log*
yarn-debug.log*
yarn-error.log*

# local env files
.env
.env*.local

# vercel
.vercel

# typescript
*.tsbuildinfo
next-env.d.ts

# nextjs public
public/uploads

# drizzle
/drizzle
133 changes: 70 additions & 63 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,63 +1,70 @@
# cardia

**cardia** is a blood pressure documentation application built with Next.js, using Drizzle as an ORM, and Supabase for authentication and database management. It allows users to easily add and track their blood pressure records.

## Getting Started

To set up cardia locally, follow these steps:

1. Clone this repository to your local machine:

```bash
git clone https://github.com/visualcookie/cardia.git

OR

gh repo clone visualcookie/cardia
```

2. Navigate to the project directory:

```bash
cd cardia
```

3. Install dependencies:

```bash
bun install
```

4. Set up your Supabase project:

- Sign up or log in to [Supabase](https://supabase.io/).
- Create a new project and database.
- Set up authentication and obtain your Supabase URL and public key.

5. Configure environment variables:

Create a `.env.local` file in the root directory and add the following:

```plaintext
NEXT_PUBLIC_BASE_URL=http://localhost:3000
NEXT_PUBLIC_SUPABASE_URL=your-supabase-url
NEXT_PUBLIC_SUPABASE_ANON_KEY=your-supabase-public-key
```

6. Run the development server:

```bash
bun run dev
```

7. Open [http://localhost:3000](http://localhost:3000) in your browser to access cardia.

## TODO

- [ ] Add data visualization for blood pressure records.
- [ ] Implement reminders or notifications for regular blood pressure checks.
- [ ] Improve the export.

## License

This project is licensed under the "The Unlicense" license. See the [LICENSE.md](LICENSE.md) file for details.
# cardia

**cardia** is a blood pressure documentation application built with Next.js, using Drizzle as an ORM, and Supabase for authentication and database management. It allows users to easily add and track their blood pressure records.

## Getting Started

To set up cardia locally, follow these steps:

1. Clone this repository to your local machine:

```bash
git clone https://github.com/visualcookie/cardia.git

OR

gh repo clone visualcookie/cardia
```

2. Navigate to the project directory:

```bash
cd cardia
```

3. Install dependencies:

```bash
bun install
```

4. Set up your Supabase project:

- Sign up or log in to [Supabase](https://supabase.io/).
- Create a new project and database.
- Set up authentication and obtain your Supabase URL and public key.

5. Configure environment variables:

Create a `.env.local` file in the root directory and add the following:

```plaintext
NEXT_PUBLIC_BASE_URL=http://localhost:3000
NEXT_PUBLIC_SUPABASE_URL=your-supabase-url
NEXT_PUBLIC_SUPABASE_ANON_KEY=your-supabase-public-key
```

6. Run the development server:

```bash
bun run dev
```

7. Open [http://localhost:3000](http://localhost:3000) in your browser to access cardia.

## TODO

- [ ] Add data visualization for blood pressure records
- [ ] Implement reminders for regular blood pressure checks
- [ ] Improve the export
- [ ] Add import from CSV
- [ ] Add filter to stages
- [ ] Group data by day/date
- [ ] Add filter by date range
- [ ] Display last 10 records
- [ ] Add "Load more" functionality
- [ ] Settings page

## License

This project is licensed under the "The Unlicense" license. See the [LICENSE.md](LICENSE.md) file for details.
Binary file modified bun.lockb
100644 → 100755
Binary file not shown.
26 changes: 15 additions & 11 deletions drizzle.config.ts
Original file line number Diff line number Diff line change
@@ -1,11 +1,15 @@
import 'dotenv/config'
import type { Config } from 'drizzle-kit'

export default {
schema: './src/db/schema.ts',
out: './drizzle',
driver: 'pg',
dbCredentials: {
connectionString: process.env.DB_URL!,
},
} satisfies Config
import 'dotenv/config'
import { defineConfig } from 'drizzle-kit'

export default defineConfig({
dialect: 'postgresql',
dbCredentials: {
url: process.env.POSTGRES_URL!,
},
migrations: {
table: 'migrations',
schema: 'cardia',
},
schema: './src/db/schema.ts',
out: './drizzle',
})
30 changes: 0 additions & 30 deletions drizzle/0000_careful_shotgun.sql

This file was deleted.

Loading