-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
82 changed files
with
1,077 additions
and
238 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
PORT=3000 | ||
|
||
DB_HOST=localhost | ||
DB_PORT=27017 | ||
DB_NAME=devparana | ||
DB_USER= | ||
DB_PASS= | ||
|
||
JWT_SECRET= |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,77 +1,73 @@ | ||
# Devmx | ||
|
||
<a alt="Nx logo" href="https://nx.dev" target="_blank" rel="noreferrer"><img src="https://raw.githubusercontent.com/nrwl/nx/master/images/nx-logo.png" width="45"></a> | ||
|
||
✨ Your new, shiny [Nx workspace](https://nx.dev) is almost ready ✨. | ||
|
||
[Learn more about this workspace setup and its capabilities](https://nx.dev/getting-started/intro#learn-nx?utm_source=nx_project&utm_medium=readme&utm_campaign=nx_projects) or run `npx nx graph` to visually explore what was created. Now, let's get you up to speed! | ||
``` | ||
_ | ||
__| | _____ ___ __ ___ __ __ | ||
/ _` |/ _ \ \ / / '_ ` _ \\ \/ / | ||
| (_| | __/\ V /| | | | | |> < | ||
\__,_|\___| \_/ |_| |_| |_/_/\_\ | ||
``` | ||
# dev member experience | ||
|
||
## Finish your CI setup | ||
|
||
[Click here to finish setting up your workspace!](https://cloud.nx.app/connect/MMUTh7bF3w) | ||
## Para executar em dev | ||
|
||
### Requisitos | ||
1. [pnpm](https://pnpm.io/installation) instalado | ||
1. [docker](https://docs.docker.com/engine/install) instalado | ||
|
||
## Run tasks | ||
### Configurações | ||
|
||
To run tasks with Nx use: | ||
Clone o projeto | ||
|
||
```sh | ||
npx nx <target> <project-name> | ||
git clone https://github.com/DeveloperParana/devmx | ||
``` | ||
|
||
For example: | ||
Configure a senha do banco e segredo jwt como quiser para uso local | ||
|
||
```sh | ||
npx nx build myproject | ||
mv .env-example .env | ||
``` | ||
|
||
These targets are either [inferred automatically](https://nx.dev/concepts/inferred-tasks?utm_source=nx_project&utm_medium=readme&utm_campaign=nx_projects) or defined in the `project.json` or `package.json` files. | ||
|
||
[More about running tasks in the docs »](https://nx.dev/features/run-tasks?utm_source=nx_project&utm_medium=readme&utm_campaign=nx_projects) | ||
|
||
## Add new projects | ||
Preencha os valores para `DB_USER`, `DB_PASS`, `JWT_SECRET` e salve antes de executar o docker. | ||
|
||
While you could add new projects to your workspace manually, you might want to leverage [Nx plugins](https://nx.dev/concepts/nx-plugins?utm_source=nx_project&utm_medium=readme&utm_campaign=nx_projects) and their [code generation](https://nx.dev/features/generate-code?utm_source=nx_project&utm_medium=readme&utm_campaign=nx_projects) feature. | ||
|
||
To install a new plugin you can use the `nx add` command. Here's an example of adding the React plugin: | ||
```sh | ||
npx nx add @nx/react | ||
docker compose up -d | ||
``` | ||
|
||
Use the plugin's generator to create new projects. For example, to create a new React app or library: | ||
Instale as dependências | ||
|
||
```sh | ||
# Genenerate an app | ||
npx nx g @nx/react:app demo | ||
|
||
# Generate a library | ||
npx nx g @nx/react:lib some-lib | ||
pnpm install | ||
``` | ||
|
||
You can use `npx nx list` to get a list of installed plugins. Then, run `npx nx list <plugin-name>` to learn about more specific capabilities of a particular plugin. Alternatively, [install Nx Console](https://nx.dev/getting-started/editor-setup?utm_source=nx_project&utm_medium=readme&utm_campaign=nx_projects) to browse plugins and generators in your IDE. | ||
|
||
[Learn more about Nx plugins »](https://nx.dev/concepts/nx-plugins?utm_source=nx_project&utm_medium=readme&utm_campaign=nx_projects) | [Browse the plugin registry »](https://nx.dev/plugin-registry?utm_source=nx_project&utm_medium=readme&utm_campaign=nx_projects) | ||
Execute o back-end e front-end | ||
|
||
```sh | ||
pnpm dev | ||
``` | ||
|
||
[Learn more about Nx on CI](https://nx.dev/ci/intro/ci-with-nx#ready-get-started-with-your-provider?utm_source=nx_project&utm_medium=readme&utm_campaign=nx_projects) | ||
## Para commits | ||
|
||
## Install Nx Console | ||
```sh | ||
pnpm cmt | ||
``` | ||
|
||
Nx Console is an editor extension that enriches your developer experience. It lets you run tasks, generate code, and improves code autocompletion in your IDE. It is available for VSCode and IntelliJ. | ||
Responda as perguntas para fazer o commit. | ||
|
||
[Install Nx Console »](https://nx.dev/getting-started/editor-setup?utm_source=nx_project&utm_medium=readme&utm_campaign=nx_projects) | ||
|
||
## Useful links | ||
## Responsabilidades e relacionamentos | ||
|
||
Learn more: | ||
Trata-se de responsabilidade e relacionamentos, ou seja, qual a responsabilidade de cada camada e quais camadas podem depender diretamente uma das outras. Na tabela a seguir vemos que camadas do tipo `util` podem depender apenas de camadas que também sejam do tipo `util`, camadas do tipo `domain` podem depender apenas de camadas do tipo `util`, camadas do tipo `data-source` podem depender apenas dos tipos `util` e `domain` e assim por diante. | ||
|
||
- [Learn more about this workspace setup](https://nx.dev/getting-started/intro#learn-nx?utm_source=nx_project&utm_medium=readme&utm_campaign=nx_projects) | ||
- [Learn about Nx on CI](https://nx.dev/ci/intro/ci-with-nx?utm_source=nx_project&utm_medium=readme&utm_campaign=nx_projects) | ||
- [Releasing Packages with Nx release](https://nx.dev/features/manage-releases?utm_source=nx_project&utm_medium=readme&utm_campaign=nx_projects) | ||
- [What are Nx plugins?](https://nx.dev/concepts/nx-plugins?utm_source=nx_project&utm_medium=readme&utm_campaign=nx_projects) | ||
Caso tenha interesse em aprofundar neste assunto e descobrir os motivos, recomendo que leia um conteúdo que escrevi ano passado, você pode fazer download através do link a seguir. [Arquitetura em camadas, uma abordagem sobre responsabilidades e relacionamentos](https://conteudode.dev/pdf/nx) | ||
|
||
And join the Nx community: | ||
- [Discord](https://go.nx.dev/community) | ||
- [Follow us on X](https://twitter.com/nxdevtools) or [LinkedIn](https://www.linkedin.com/company/nrwl) | ||
- [Our Youtube channel](https://www.youtube.com/@nxdevtools) | ||
- [Our blog](https://nx.dev/blog?utm_source=nx_project&utm_medium=readme&utm_campaign=nx_projects) | ||
| | util | domain | data-source | data-access | resource | feature | app | api | | ||
| ------------: | :--: | :----: | :---------: | :---------: | :------: | :-----: | :-: | :-: | | ||
| `util` | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | | ||
| `domain` | 𝗫 | 𝗫 | ✓ | ✓ | 𝗫 | 𝗫 | 𝗫 | ✓ | | ||
| `data-source` | 𝗫 | 𝗫 | 𝗫 | 𝗫 | ✓ | 𝗫 | ✓ | ✓ | | ||
| `data-access` | 𝗫 | 𝗫 | 𝗫 | 𝗫 | 𝗫 | ✓ | ✓ | ✓ | | ||
| `resource` | 𝗫 | 𝗫 | 𝗫 | 𝗫 | ✓ | 𝗫 | ✓ | ✓ | | ||
| `feature` | 𝗫 | 𝗫 | 𝗫 | 𝗫 | 𝗫 | ✓ | ✓ | ✓ | | ||
| `app` | 𝗫 | 𝗫 | 𝗫 | 𝗫 | 𝗫 | 𝗫 | 𝗫 | 𝗫 | | ||
| `api` | 𝗫 | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,4 +2,7 @@ export const env = { | |
api: { | ||
url: '/api', | ||
}, | ||
photos: { | ||
url: '/photos' | ||
} | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,64 @@ | ||
// prettier-ignore | ||
/** @type {import('cz-git').UserConfig['prompt']} */ | ||
module.exports = { | ||
alias: { fd: 'docs: fix typos' }, | ||
messages: { | ||
type: 'Selecione o tipo de alteração que você está comitando:', | ||
scope: 'Informe o ESCOPO desta alteração (opcional):', | ||
customScope: 'Escreva o ESCOPO desta alteração:', | ||
subject: 'Escreva uma descrição CURTA e IMPERATIVA da mudança:\n', | ||
body: 'Forneça uma descrição MAIS LONGA da mudança (opcional). Use "|" para quebrar uma nova linha:\n', | ||
breaking: 'Liste quaisquer BREAKING CHANGES (opcional). Use "|" para quebrar nova linha:\n', | ||
footerPrefixesSelect: 'Select the ISSUES type of change List by this change (optional):', | ||
customFooterPrefix: 'Input ISSUES prefix:', | ||
footer: 'List any ISSUES by this change. E.g.: #31, #34:\n', | ||
generatingByAI: 'Generating your AI commit subject...', | ||
generatedSelectByAI: 'Select suitable subject by AI generated:', | ||
confirmCommit: 'Are you sure you want to proceed with the commit above?' | ||
}, | ||
types: [ | ||
{ value: 'feat', name: 'feat: Nova funcionalidade', emoji: ':sparkles:' }, | ||
{ value: 'fix', name: 'fix: Correção de bug', emoji: ':bug:' }, | ||
{ value: 'docs', name: 'docs: Apenas mudanças em documentação', emoji: ':memo:' }, | ||
{ value: 'style', name: 'style: Mudança no código que não afeta seu funcionamento', emoji: ':lipstick:' }, | ||
{ value: 'refactor', name: 'refactor: Alteração de código que não corrige bug nem adiciona recurso', emoji: ':recycle:' }, | ||
{ value: 'perf', name: 'perf: Mudança no código que melhora o desempenho', emoji: ':zap:' }, | ||
{ value: 'test', name: 'test: Adiciona testes ou corrige testes existentes', emoji: ':white_check_mark:' }, | ||
{ value: 'build', name: 'build: Alteração que afeta o build ou dependências externas', emoji: ':package:' }, | ||
{ value: 'ci', name: 'ci: Alteração em arquivos de configuração e scripts de CI', emoji: ':ferris_wheel:' }, | ||
{ value: 'chore', name: 'chore: Alteração fora dos diretórios src/**/*', emoji: ':hammer:' }, | ||
{ value: 'revert', name: 'revert: Reverte um commit anterior', emoji: ':rewind:' } | ||
], | ||
useEmoji: false, | ||
emojiAlign: 'center', | ||
useAI: false, | ||
aiNumber: 1, | ||
themeColorCode: '', | ||
scopes: [], | ||
allowCustomScopes: true, | ||
allowEmptyScopes: true, | ||
customScopesAlign: 'bottom', | ||
customScopesAlias: 'custom', | ||
emptyScopesAlias: 'empty', | ||
upperCaseSubject: false, | ||
markBreakingChangeMode: false, | ||
allowBreakingChanges: ['feat', 'fix'], | ||
breaklineNumber: 100, | ||
breaklineChar: '|', | ||
skipQuestions: [], | ||
issuePrefixes: [{ value: 'closed', name: 'closed: ISSUES has been processed' }], | ||
customIssuePrefixAlign: 'top', | ||
emptyIssuePrefixAlias: 'skip', | ||
customIssuePrefixAlias: 'custom', | ||
allowCustomIssuePrefix: false, | ||
allowEmptyIssuePrefix: false, | ||
confirmColorize: true, | ||
maxHeaderLength: Infinity, | ||
maxSubjectLength: Infinity, | ||
minSubjectLength: 0, | ||
scopeOverrides: undefined, | ||
defaultBody: '', | ||
defaultIssues: '', | ||
defaultScope: '', | ||
defaultSubject: '' | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.