├── .github
├── ISSUE_TEMPLATE
│ ├── Bug_report.yml
│ ├── Feature_request.yml
│ ├── Regression.yml
│ └── config.yml
└── PULL_REQUEST_TEMPLATE.md
├── .gitignore
├── .npmignore
├── .prettierrc
├── CODE_OF_CONDUCT.md
├── CONTRIBUTING.md
├── LICENSE
├── README.md
├── lib
├── clickhouse.module.ts
├── index.ts
└── internal
│ └── index.ts
├── package-lock.json
├── package.json
└── tsconfig.json
/.github/ISSUE_TEMPLATE/Bug_report.yml:
--------------------------------------------------------------------------------
1 | name: "\U0001F41B Bug Report"
2 | description: "If something ins't working as expected \U0001F914"
3 | labels: ["needs triage", "bug"]
4 | body:
5 | - type: markdown
6 | attributes:
7 | value: |
8 | ## :warning: We use GitHub Issues to track bug reports, feature requests and regressions
9 |
10 | If you are not sure that your issue is a bug, you could:
11 |
12 | - use our [Discord community](https://discord.gg/NestJS)
13 | - use [StackOverflow using the tag `nestjs`](https://stackoverflow.com/questions/tagged/nestjs)
14 | - If it's just a quick question you can ping [our Twitter](https://twitter.com/nestframework)
15 |
16 | **NOTE:** You don't need to answer questions that you know that aren't relevant.
17 |
18 | ---
19 |
20 | - type: checkboxes
21 | attributes:
22 | label: "Is there an existing issue for this?"
23 | description: "Please search [here](./?q=is%3Aissue) to see if an issue already exists for the bug you encountered"
24 | options:
25 | - label: "I have searched the existing issues"
26 | required: true
27 |
28 | - type: textarea
29 | validations:
30 | required: true
31 | attributes:
32 | label: "Current behavior"
33 | description: "How the issue manifests?"
34 |
35 | - type: input
36 | validations:
37 | required: true
38 | attributes:
39 | label: "Minimum reproduction code"
40 | description: "An URL to some git repository or gist that reproduces this issue. [Wtf is a minimum reproduction?](https://jmcdo29.github.io/wtf-is-a-minimum-reproduction)"
41 | placeholder: "https://github.com/..."
42 |
43 | - type: textarea
44 | attributes:
45 | label: "Steps to reproduce"
46 | description: |
47 | How the issue manifests?
48 | You could leave this blank if you alread write this in your reproduction code/repo
49 | placeholder: |
50 | 1. `npm i`
51 | 2. `npm start:dev`
52 | 3. See error...
53 |
54 | - type: textarea
55 | validations:
56 | required: true
57 | attributes:
58 | label: "Expected behavior"
59 | description: "A clear and concise description of what you expected to happend (or code)"
60 |
61 | - type: markdown
62 | attributes:
63 | value: |
64 | ---
65 |
66 | - type: input
67 | validations:
68 | required: true
69 | attributes:
70 | label: "Package version"
71 | description: |
72 | Which version of `@depyronick/nestjs-clickhouse` are you using?
73 | **Tip**: Make sure that all of yours `@nestjs/*` dependencies are in sync!
74 | placeholder: "8.1.3"
75 |
76 | - type: input
77 | attributes:
78 | label: "NestJS version"
79 | description: "Which version of `@nestjs/core` are you using?"
80 | placeholder: "8.1.3"
81 |
82 | - type: input
83 | attributes:
84 | label: "Node.js version"
85 | description: "Which version of Node.js are you using?"
86 | placeholder: "14.17.6"
87 |
88 | - type: checkboxes
89 | attributes:
90 | label: "In which operating systems have you tested?"
91 | options:
92 | - label: macOS
93 | - label: Windows
94 | - label: Linux
95 |
96 | - type: markdown
97 | attributes:
98 | value: |
99 | ---
100 |
101 | - type: textarea
102 | attributes:
103 | label: "Other"
104 | description: |
105 | Anything else relevant? eg: Logs, OS version, IDE, package manager, etc.
106 | **Tip:** You can attach images, recordings or log files by clicking this area to highlight it and then dragging files in
107 |
--------------------------------------------------------------------------------
/.github/ISSUE_TEMPLATE/Feature_request.yml:
--------------------------------------------------------------------------------
1 | name: "\U0001F680 Feature Request"
2 | description: "I have a suggestion \U0001F63B!"
3 | labels: ["feature"]
4 | body:
5 | - type: markdown
6 | attributes:
7 | value: |
8 | ## :warning: We use GitHub Issues to track bug reports, feature requests and regressions
9 |
10 | If you are not sure that your issue is a bug, you could:
11 |
12 | - use our [Discord community](https://discord.gg/NestJS)
13 | - use [StackOverflow using the tag `nestjs`](https://stackoverflow.com/questions/tagged/nestjs)
14 | - If it's just a quick question you can ping [our Twitter](https://twitter.com/nestframework)
15 |
16 | ---
17 |
18 | - type: checkboxes
19 | attributes:
20 | label: "Is there an existing issue that is already proposing this?"
21 | description: "Please search [here](./?q=is%3Aissue) to see if an issue already exists for the feature you are requesting"
22 | options:
23 | - label: "I have searched the existing issues"
24 | required: true
25 |
26 | - type: textarea
27 | validations:
28 | required: true
29 | attributes:
30 | label: "Is your feature request related to a problem? Please describe it"
31 | description: "A clear and concise description of what the problem is"
32 | placeholder: |
33 | I have an issue when ...
34 |
35 | - type: textarea
36 | validations:
37 | required: true
38 | attributes:
39 | label: "Describe the solution you'd like"
40 | description: "A clear and concise description of what you want to happen. Add any considered drawbacks"
41 |
42 | - type: textarea
43 | validations:
44 | required: true
45 | attributes:
46 | label: "Teachability, documentation, adoption, migration strategy"
47 | description: "If you can, explain how users will be able to use this and possibly write out a version the docs. Maybe a screenshot or design?"
48 |
49 | - type: textarea
50 | validations:
51 | required: true
52 | attributes:
53 | label: "What is the motivation / use case for changing the behavior?"
54 | description: "Describe the motivation or the concrete use case"
55 |
--------------------------------------------------------------------------------
/.github/ISSUE_TEMPLATE/Regression.yml:
--------------------------------------------------------------------------------
1 | name: "\U0001F4A5 Regression"
2 | description: "Report an unexpected behavior while upgrading your Nest application!"
3 | labels: ["needs triage"]
4 | body:
5 | - type: markdown
6 | attributes:
7 | value: |
8 | ## :warning: We use GitHub Issues to track bug reports, feature requests and regressions
9 |
10 | If you are not sure that your issue is a bug, you could:
11 |
12 | - use our [Discord community](https://discord.gg/NestJS)
13 | - use [StackOverflow using the tag `nestjs`](https://stackoverflow.com/questions/tagged/nestjs)
14 | - If it's just a quick question you can ping [our Twitter](https://twitter.com/nestframework)
15 |
16 | **NOTE:** You don't need to answer questions that you know that aren't relevant.
17 |
18 | ---
19 |
20 | - type: checkboxes
21 | attributes:
22 | label: "Did you read the migration guide?"
23 | description: "Check out the [migration guide here](https://docs.nestjs.com/migration-guide)!"
24 | options:
25 | - label: "I have read the whole migration guide"
26 | required: false
27 |
28 | - type: checkboxes
29 | attributes:
30 | label: "Is there an existing issue that is already proposing this?"
31 | description: "Please search [here](./?q=is%3Aissue) to see if an issue already exists for the feature you are requesting"
32 | options:
33 | - label: "I have searched the existing issues"
34 | required: true
35 |
36 | - type: input
37 | attributes:
38 | label: "Potential Commit/PR that introduced the regression"
39 | description: "If you have time to investigate, what PR/date/version introduced this issue"
40 | placeholder: "PR #123 or commit 5b3c4a4"
41 |
42 | - type: input
43 | attributes:
44 | label: "Versions"
45 | description: "From which version of `@depyronick/nestjs-clickhouse` to which version you are upgrading"
46 | placeholder: "8.1.0 -> 8.1.3"
47 |
48 | - type: textarea
49 | validations:
50 | required: true
51 | attributes:
52 | label: "Describe the regression"
53 | description: "A clear and concise description of what the regression is"
54 |
55 | - type: textarea
56 | attributes:
57 | label: "Minimum reproduction code"
58 | description: |
59 | Please share a git repo, a gist, or step-by-step instructions. [Wtf is a minimum reproduction?](https://jmcdo29.github.io/wtf-is-a-minimum-reproduction)
60 | **Tip:** If you leave a minimum repository, we will understand your issue faster!
61 | value: |
62 | ```ts
63 |
64 | ```
65 |
66 | - type: textarea
67 | validations:
68 | required: true
69 | attributes:
70 | label: "Expected behavior"
71 | description: "A clear and concise description of what you expected to happend (or code)"
72 |
73 | - type: textarea
74 | attributes:
75 | label: "Other"
76 | description: |
77 | Anything else relevant? eg: Logs, OS version, IDE, package manager, etc.
78 | **Tip:** You can attach images, recordings or log files by clicking this area to highlight it and then dragging files in
79 |
--------------------------------------------------------------------------------
/.github/ISSUE_TEMPLATE/config.yml:
--------------------------------------------------------------------------------
1 | ## To encourage contributors to use issue templates, we don't allow blank issues
2 | blank_issues_enabled: false
3 |
4 | contact_links:
5 | - name: "\u2753 Discord Community of NestJS"
6 | url: "https://discord.gg/NestJS"
7 | about: "Please ask support questions here."
8 |
--------------------------------------------------------------------------------
/.github/PULL_REQUEST_TEMPLATE.md:
--------------------------------------------------------------------------------
1 | ## PR Checklist
2 |
3 | Please check if your PR fulfills the following requirements:
4 |
5 | - [ ] The commit message follows our guidelines: https://github.com/nestjs/nest/blob/master/CONTRIBUTING.md
6 | - [ ] Tests for the changes have been added (for bug fixes / features)
7 | - [ ] Docs have been added / updated (for bug fixes / features)
8 |
9 | ## PR Type
10 |
11 | What kind of change does this PR introduce?
12 |
13 |
14 |
15 | ```
16 | [ ] Bugfix
17 | [ ] Feature
18 | [ ] Code style update (formatting, local variables)
19 | [ ] Refactoring (no functional changes, no api changes)
20 | [ ] Build related changes
21 | [ ] CI related changes
22 | [ ] Other... Please describe:
23 | ```
24 |
25 | ## What is the current behavior?
26 |
27 |
28 |
29 | Issue Number: N/A
30 |
31 | ## What is the new behavior?
32 |
33 | ## Does this PR introduce a breaking change?
34 |
35 | ```
36 | [ ] Yes
37 | [ ] No
38 | ```
39 |
40 |
41 |
42 | ## Other information
43 |
--------------------------------------------------------------------------------
/.gitignore:
--------------------------------------------------------------------------------
1 | # dependencies
2 | /node_modules
3 |
4 | # IDE
5 | /.idea
6 | /.awcache
7 | /.vscode
8 |
9 | # misc
10 | npm-debug.log
11 | .DS_Store
12 |
13 | # tests
14 | /test
15 | /coverage
16 | /.nyc_output
17 |
18 | # dist
19 | dist
--------------------------------------------------------------------------------
/.npmignore:
--------------------------------------------------------------------------------
1 | # source
2 | lib
3 | tests
4 | index.ts
5 | package-lock.json
6 | tslint.json
7 | tsconfig.json
8 | .prettierrc
9 |
10 | # github
11 | .github
12 | CONTRIBUTING.md
13 | renovate.json
14 |
15 | # misc
16 | .commitlintrc.json
17 | .release-it.json
18 | .eslintignore
19 | .eslintrc.js
--------------------------------------------------------------------------------
/.prettierrc:
--------------------------------------------------------------------------------
1 | {
2 | "trailingComma": "all",
3 | "arrowParens": "always",
4 | "singleQuote": true
5 | }
--------------------------------------------------------------------------------
/CODE_OF_CONDUCT.md:
--------------------------------------------------------------------------------
1 | # Contributor Covenant Code of Conduct
2 |
3 | ## Our Pledge
4 |
5 | We as members, contributors, and leaders pledge to make participation in our
6 | community a harassment-free experience for everyone, regardless of age, body
7 | size, visible or invisible disability, ethnicity, sex characteristics, gender
8 | identity and expression, level of experience, education, socio-economic status,
9 | nationality, personal appearance, race, religion, or sexual identity
10 | and orientation.
11 |
12 | We pledge to act and interact in ways that contribute to an open, welcoming,
13 | diverse, inclusive, and healthy community.
14 |
15 | ## Our Standards
16 |
17 | Examples of behavior that contributes to a positive environment for our
18 | community include:
19 |
20 | * Demonstrating empathy and kindness toward other people
21 | * Being respectful of differing opinions, viewpoints, and experiences
22 | * Giving and gracefully accepting constructive feedback
23 | * Accepting responsibility and apologizing to those affected by our mistakes,
24 | and learning from the experience
25 | * Focusing on what is best not just for us as individuals, but for the
26 | overall community
27 |
28 | Examples of unacceptable behavior include:
29 |
30 | * The use of sexualized language or imagery, and sexual attention or
31 | advances of any kind
32 | * Trolling, insulting or derogatory comments, and personal or political attacks
33 | * Public or private harassment
34 | * Publishing others' private information, such as a physical or email
35 | address, without their explicit permission
36 | * Other conduct which could reasonably be considered inappropriate in a
37 | professional setting
38 |
39 | ## Enforcement Responsibilities
40 |
41 | Community leaders are responsible for clarifying and enforcing our standards of
42 | acceptable behavior and will take appropriate and fair corrective action in
43 | response to any behavior that they deem inappropriate, threatening, offensive,
44 | or harmful.
45 |
46 | Community leaders have the right and responsibility to remove, edit, or reject
47 | comments, commits, code, wiki edits, issues, and other contributions that are
48 | not aligned to this Code of Conduct, and will communicate reasons for moderation
49 | decisions when appropriate.
50 |
51 | ## Scope
52 |
53 | This Code of Conduct applies within all community spaces, and also applies when
54 | an individual is officially representing the community in public spaces.
55 | Examples of representing our community include using an official e-mail address,
56 | posting via an official social media account, or acting as an appointed
57 | representative at an online or offline event.
58 |
59 | ## Enforcement
60 |
61 | Instances of abusive, harassing, or otherwise unacceptable behavior may be
62 | reported to the community leaders responsible for enforcement at
63 | alidemirci@gmail.com.
64 | All complaints will be reviewed and investigated promptly and fairly.
65 |
66 | All community leaders are obligated to respect the privacy and security of the
67 | reporter of any incident.
68 |
69 | ## Enforcement Guidelines
70 |
71 | Community leaders will follow these Community Impact Guidelines in determining
72 | the consequences for any action they deem in violation of this Code of Conduct:
73 |
74 | ### 1. Correction
75 |
76 | **Community Impact**: Use of inappropriate language or other behavior deemed
77 | unprofessional or unwelcome in the community.
78 |
79 | **Consequence**: A private, written warning from community leaders, providing
80 | clarity around the nature of the violation and an explanation of why the
81 | behavior was inappropriate. A public apology may be requested.
82 |
83 | ### 2. Warning
84 |
85 | **Community Impact**: A violation through a single incident or series
86 | of actions.
87 |
88 | **Consequence**: A warning with consequences for continued behavior. No
89 | interaction with the people involved, including unsolicited interaction with
90 | those enforcing the Code of Conduct, for a specified period of time. This
91 | includes avoiding interactions in community spaces as well as external channels
92 | like social media. Violating these terms may lead to a temporary or
93 | permanent ban.
94 |
95 | ### 3. Temporary Ban
96 |
97 | **Community Impact**: A serious violation of community standards, including
98 | sustained inappropriate behavior.
99 |
100 | **Consequence**: A temporary ban from any sort of interaction or public
101 | communication with the community for a specified period of time. No public or
102 | private interaction with the people involved, including unsolicited interaction
103 | with those enforcing the Code of Conduct, is allowed during this period.
104 | Violating these terms may lead to a permanent ban.
105 |
106 | ### 4. Permanent Ban
107 |
108 | **Community Impact**: Demonstrating a pattern of violation of community
109 | standards, including sustained inappropriate behavior, harassment of an
110 | individual, or aggression toward or disparagement of classes of individuals.
111 |
112 | **Consequence**: A permanent ban from any sort of public interaction within
113 | the community.
114 |
115 | ## Attribution
116 |
117 | This Code of Conduct is adapted from the [Contributor Covenant][homepage],
118 | version 2.0, available at
119 | https://www.contributor-covenant.org/version/2/0/code_of_conduct.html.
120 |
121 | Community Impact Guidelines were inspired by [Mozilla's code of conduct
122 | enforcement ladder](https://github.com/mozilla/diversity).
123 |
124 | [homepage]: https://www.contributor-covenant.org
125 |
126 | For answers to common questions about this code of conduct, see the FAQ at
127 | https://www.contributor-covenant.org/faq. Translations are available at
128 | https://www.contributor-covenant.org/translations.
129 |
--------------------------------------------------------------------------------
/CONTRIBUTING.md:
--------------------------------------------------------------------------------
1 | # Contributing to Nest
2 |
3 | We would love for you to contribute to Nest and help make it even better than it is
4 | today! As a contributor, here are the guidelines we would like you to follow:
5 |
6 | - [Code of Conduct](#coc)
7 | - [Question or Problem?](#question)
8 | - [Issues and Bugs](#issue)
9 | - [Feature Requests](#feature)
10 | - [Submission Guidelines](#submit)
11 | - [Coding Rules](#rules)
12 | - [Commit Message Guidelines](#commit)
13 |
14 |
15 |
17 |
18 | ## Got a Question or Problem?
19 |
20 | **Do not open issues for general support questions as we want to keep GitHub issues for bug reports and feature requests.** You've got much better chances of getting your question answered on [Stack Overflow](https://stackoverflow.com/questions/tagged/nestjs) where the questions should be tagged with tag `nestjs`.
21 |
22 | Stack Overflow is a much better place to ask questions since:
23 |
24 |
25 |
26 | - questions and answers stay available for public viewing so your question / answer might help someone else
27 | - Stack Overflow's voting system assures that the best answers are prominently visible.
28 |
29 | To save your and our time, we will systematically close all issues that are requests for general support and redirect people to Stack Overflow.
30 |
31 | If you would like to chat about the question in real-time, you can reach out via [our gitter channel][gitter].
32 |
33 | ## Found a Bug?
34 |
35 | If you find a bug in the source code, you can help us by
36 | [submitting an issue](#submit-issue) to our [GitHub Repository][github]. Even better, you can
37 | [submit a Pull Request](#submit-pr) with a fix.
38 |
39 | ## Missing a Feature?
40 |
41 | You can _request_ a new feature by [submitting an issue](#submit-issue) to our GitHub
42 | Repository. If you would like to _implement_ a new feature, please submit an issue with
43 | a proposal for your work first, to be sure that we can use it.
44 | Please consider what kind of change it is:
45 |
46 | - For a **Major Feature**, first open an issue and outline your proposal so that it can be
47 | discussed. This will also allow us to better coordinate our efforts, prevent duplication of work,
48 | and help you to craft the change so that it is successfully accepted into the project. For your issue name, please prefix your proposal with `[discussion]`, for example "[discussion]: your feature idea".
49 | - **Small Features** can be crafted and directly [submitted as a Pull Request](#submit-pr).
50 |
51 | ## Submission Guidelines
52 |
53 | ### Submitting an Issue
54 |
55 | Before you submit an issue, please search the issue tracker, maybe an issue for your problem already exists and the discussion might inform you of workarounds readily available.
56 |
57 | We want to fix all the issues as soon as possible, but before fixing a bug we need to reproduce and confirm it. In order to reproduce bugs we will systematically ask you to provide a minimal reproduction scenario using a repository or [Gist](https://gist.github.com/). Having a live, reproducible scenario gives us wealth of important information without going back & forth to you with additional questions like:
58 |
59 | - version of NestJS used
60 | - 3rd-party libraries and their versions
61 | - and most importantly - a use-case that fails
62 |
63 |
67 |
68 |
69 |
70 | Unfortunately, we are not able to investigate / fix bugs without a minimal reproduction, so if we don't hear back from you we are going to close an issue that don't have enough info to be reproduced.
71 |
72 | You can file new issues by filling out our [new issue form](https://github.com/nestjs/nest/issues/new).
73 |
74 | ### Submitting a Pull Request (PR)
75 |
76 | Before you submit your Pull Request (PR) consider the following guidelines:
77 |
78 | 1. Search [GitHub](https://github.com/nestjs/nest/pulls) for an open or closed PR
79 | that relates to your submission. You don't want to duplicate effort.
80 |
82 | 1. Fork the nestjs/nest repo.
83 | 1. Make your changes in a new git branch:
84 |
85 | ```shell
86 | git checkout -b my-fix-branch master
87 | ```
88 |
89 | 1. Create your patch, **including appropriate test cases**.
90 | 1. Follow our [Coding Rules](#rules).
91 | 1. Run the full Nest test suite, as described in the [developer documentation][dev-doc],
92 | and ensure that all tests pass.
93 | 1. Commit your changes using a descriptive commit message that follows our
94 | [commit message conventions](#commit). Adherence to these conventions
95 | is necessary because release notes are automatically generated from these messages.
96 |
97 | ```shell
98 | git commit -a
99 | ```
100 |
101 | Note: the optional commit `-a` command line option will automatically "add" and "rm" edited files.
102 |
103 | 1. Push your branch to GitHub:
104 |
105 | ```shell
106 | git push origin my-fix-branch
107 | ```
108 |
109 | 1. In GitHub, send a pull request to `nestjs:master`.
110 |
111 | - If we suggest changes then:
112 |
113 | - Make the required updates.
114 | - Re-run the Nest test suites to ensure tests are still passing.
115 | - Rebase your branch and force push to your GitHub repository (this will update your Pull Request):
116 |
117 | ```shell
118 | git rebase master -i
119 | git push -f
120 | ```
121 |
122 | That's it! Thank you for your contribution!
123 |
124 | #### After your pull request is merged
125 |
126 | After your pull request is merged, you can safely delete your branch and pull the changes
127 | from the main (upstream) repository:
128 |
129 | - Delete the remote branch on GitHub either through the GitHub web UI or your local shell as follows:
130 |
131 | ```shell
132 | git push origin --delete my-fix-branch
133 | ```
134 |
135 | - Check out the master branch:
136 |
137 | ```shell
138 | git checkout master -f
139 | ```
140 |
141 | - Delete the local branch:
142 |
143 | ```shell
144 | git branch -D my-fix-branch
145 | ```
146 |
147 | - Update your master with the latest upstream version:
148 |
149 | ```shell
150 | git pull --ff upstream master
151 | ```
152 |
153 | ## Coding Rules
154 |
155 | To ensure consistency throughout the source code, keep these rules in mind as you are working:
156 |
157 | - All features or bug fixes **must be tested** by one or more specs (unit-tests).
158 |
161 | - We follow [Google's JavaScript Style Guide][js-style-guide], but wrap all code at
162 | **100 characters**. An automated formatter is available (`npm run format`).
163 |
164 | ## Commit Message Guidelines
165 |
166 | We have very precise rules over how our git commit messages can be formatted. This leads to **more
167 | readable messages** that are easy to follow when looking through the **project history**. But also,
168 | we use the git commit messages to **generate the Nest change log**.
169 |
170 | ### Commit Message Format
171 |
172 | Each commit message consists of a **header**, a **body** and a **footer**. The header has a special
173 | format that includes a **type**, a **scope** and a **subject**:
174 |
175 | ```
176 | ():
177 |
178 |
179 |
180 |