Skip to content
Merged
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
12 changes: 9 additions & 3 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,14 +10,20 @@ jobs:
- name: Checkout
uses: actions/checkout@v4

- name: Setup pnpm
uses: pnpm/action-setup@v4
with:
version: 10
run_install: false

- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: 20
cache: 'npm'
cache: 'pnpm'

- name: Install dependencies
run: npm install
run: pnpm install

- name: Lint
run: npx prisma generate && npm run build
run: pnpm dlx prisma generate && pnpm run build
12 changes: 9 additions & 3 deletions .github/workflows/validations.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,14 +10,20 @@ jobs:
- name: Checkout
uses: actions/checkout@v4

- name: Setup pnpm
uses: pnpm/action-setup@v4
with:
version: 10
run_install: false

- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: 20
cache: 'npm'
cache: 'pnpm'

- name: Install dependencies
run: npm install
run: pnpm install

- name: Lint
run: npx prisma generate && npm run lint
run: pnpm dlx prisma generate && pnpm run lint
12 changes: 6 additions & 6 deletions DATABASE.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,10 +22,10 @@ DATABASE_URL="postgresql://usuario:senha@localhost:5432/nome_do_banco"

| Ação | Comando |
|----------------------------|--------------------------------------------------------|
| Gerar nova migration | `npx prisma migrate dev --name nome_da_migration` |
| Aplicar migrations (prod) | `npx prisma migrate deploy` |
| Regenerar client Prisma | `npx prisma generate` |
| Acessar interface visual | `npx prisma studio` |
| Gerar nova migration | `pnpm dlx prisma migrate dev --name nome_da_migration` |
| Aplicar migrations (prod) | `pnpm dlx prisma migrate deploy` |
| Regenerar client Prisma | `pnpm dlx prisma generate` |
| Acessar interface visual | `pnpm dlx prisma studio` |

---

Expand All @@ -34,8 +34,8 @@ DATABASE_URL="postgresql://usuario:senha@localhost:5432/nome_do_banco"
Após clonar o projeto, configurar o `.env` e rodar:

```bash
npm install
npx prisma migrate deploy
pnpm install
pnpm dlx prisma migrate deploy
```

O projeto já está disponível para uso!
Expand Down
8 changes: 4 additions & 4 deletions DEVELOPMENT.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,27 +27,27 @@ Os IDS basta entrar no discord e clicar com o botão direito no bot e no servido
Instale as dependências:

```bash
npm install
pnpm install
```

Agora leia atentamente o [DATABASE.md](https://github.com/codify-community/codify-bot/blob/main/DATABASE.md) para entender a configuracao local do banco de dados

E rode no seu PC :

```bash
npm run start:dev
pnpm run start:dev
```

Compile para produção:

```bash
npm run build
pnpm run build
```

Rode a versão compilada:

```bash
npm start
pnpm run start
```

---
Expand Down
Loading