Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[feat 🔥] Multi-Telended Insert #80

Open
wants to merge 19 commits into
base: main
Choose a base branch
from
Open
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
1 change: 0 additions & 1 deletion .eslintrc.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
{

"extends": ["standard-with-typescript", "airbnb", "prettier"],
"plugins": ["prettier"],
"rules": {}
Expand Down
7 changes: 6 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,9 @@
node_modules
.env
.vscode
dist/
dist/
package-lock.json
pnpm-lock.yaml
sql
.DS_Store
csv/long2.csv
7 changes: 7 additions & 0 deletions .prettierrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
{
"trailingComma": "es5",
"tabWidth": 4,
"semi": true,
"singleQuote": false,
"embeddedLanguageFormatting": "auto"
}
34 changes: 17 additions & 17 deletions CODE_OF_CONDUCT.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,24 +17,24 @@ diverse, inclusive, and healthy community.
Examples of behavior that contributes to a positive environment for our
community include:

* Demonstrating empathy and kindness toward other people
* Being respectful of differing opinions, viewpoints, and experiences
* Giving and gracefully accepting constructive feedback
* Accepting responsibility and apologizing to those affected by our mistakes,
and learning from the experience
* Focusing on what is best not just for us as individuals, but for the
overall community
- Demonstrating empathy and kindness toward other people
- Being respectful of differing opinions, viewpoints, and experiences
- Giving and gracefully accepting constructive feedback
- Accepting responsibility and apologizing to those affected by our mistakes,
and learning from the experience
- Focusing on what is best not just for us as individuals, but for the
overall community

Examples of unacceptable behavior include:

* The use of sexualized language or imagery, and sexual attention or
advances of any kind
* Trolling, insulting or derogatory comments, and personal or political attacks
* Public or private harassment
* Publishing others' private information, such as a physical or email
address, without their explicit permission
* Other conduct which could reasonably be considered inappropriate in a
professional setting
- The use of sexualized language or imagery, and sexual attention or
advances of any kind
- Trolling, insulting or derogatory comments, and personal or political attacks
- Public or private harassment
- Publishing others' private information, such as a physical or email
address, without their explicit permission
- Other conduct which could reasonably be considered inappropriate in a
professional setting

## Enforcement Responsibilities

Expand Down Expand Up @@ -106,7 +106,7 @@ Violating these terms may lead to a permanent ban.
### 4. Permanent Ban

**Community Impact**: Demonstrating a pattern of violation of community
standards, including sustained inappropriate behavior, harassment of an
standards, including sustained inappropriate behavior, harassment of an
individual, or aggression toward or disparagement of classes of individuals.

**Consequence**: A permanent ban from any sort of public interaction within
Expand All @@ -125,4 +125,4 @@ enforcement ladder](https://github.com/mozilla/diversity).

For answers to common questions about this code of conduct, see the FAQ at
https://www.contributor-covenant.org/faq. Translations are available at
https://www.contributor-covenant.org/translations.
https://www.contributor-covenant.org/translations.
12 changes: 10 additions & 2 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -1,34 +1,42 @@
# Contributing

Contributions of any kind are welcome!

## General Steps
1. Identify an Issue or feature to add

1. Identify an Issue or feature to add
2. Check posted Issues to see if your issue has already been posted
3. If not, create a new Issue (see directions below)
4. Fork this repository to your GitHub
5. Clone the repository from your GitHub
6. Create a new branch with: `git checkout -b newBranchName`
6. Create a new branch with: `git checkout -b newBranchName`
7. Complete your work and push your new branch to your GitHub
8. Come back to this repo and create a Pull Request to merge your branch with the fix/feature (see directions below)

## Issues

### Creating an Issue

If you find a bug or problem, or the documentation doesn't make sense, please create an Issue to document the concern.

### Description

Please be descriptive in your Issue. The more information you provide, the more likely someone will be able to help.

### Code Examples

If you're experiencing an issue with the code, the most helpful thing you can do is create an example reproducing the problem. This can be an GitHub repository or [gist](https://gist.github.com/), a private repository you share with the maintainers, or anything to reproduce the issue and show the code causing it.

## Pull Requests

### Creating a Pull Request

If you fix an active Issue, please create a new Pull Request for the problem. There are no guarantees that the code will be merged _"as is"_, but, if you're willing to work with the maintainers, we will surely solve the Issue.

### Description

Please be descriptive in your Pull Request. It's important to be able to understand the context of a change throughout the history of a project.

### Linking Fixed Issues

If the Pull Request is addressing an active Issue, please link that Issue by specifying the `Fixes [Issue #]` syntax within the Pull Request.
40 changes: 31 additions & 9 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,20 +1,42 @@
# csv-to-sql-insert

Provide table data as a CSV ([comma-separated values](https://en.wikipedia.org/wiki/Comma-separated_values)) file and output a SQL insert statement for a table with the same name as the file.

## Usage ⚙

1. Confirm you have a directory named `csv`
2. Confirm you have a directory named `sql`
3. Save your input CSV file in the `csv` directory
4. In a terminal window, first run `npm install` to install dependencies and then run `npm start YourFileName`
5. Watch the terminal window for any error messages
6. Your SQL insert statement will be saved in `sql/YourFileName.sql`
2. Save your input CSV file in the `csv` directory
3. In a terminal window, first run `npm install` to install dependencies and then run `npm start`

- **Question 1**: Enter your CSV file name:
- You have enter your file name like `ExampleTable` (**without file extension**)
- **Question 2**: Destination name(file):
- Just put your output file name like `mysql` or `post` or `table` etc (**without file extension**)

4. Watch the terminal window for any error messages
5. Your SQL insert statement will be saved in `sql/YourFileName.sql`

## `MAC & LINUX` USER ⚙

If you are using Mac or Linux then have a very good opportunity to handle all of these very easily.
**To run your program just execute the below command**

```bash
sudo bash start.sh
```

- Enter your CSV filename
- Enter your destination file name

## Support 👨‍💻
- [Create an Issue](https://github.com/gitdagray/csv-to-sql/issues)
- [X: @yesdavidgray](https://x.com/yesdavidgray)

- [Create an Issue](https://github.com/gitdagray/csv-to-sql/issues)
- [X: @yesdavidgray](https://x.com/yesdavidgray)

## Contributing 🛠
Please read [CONTRIBUTING.md](https://github.com/gitdagray/csv-to-sql/blob/main/CONTRIBUTING.md) prior to contributing.

## Code of Conduct
Please read [CONTRIBUTING.md](https://github.com/gitdagray/csv-to-sql/blob/main/CONTRIBUTING.md) prior to contributing.

## Code of Conduct

Please see [CODE_OF_CONDUCT.md](https://github.com/gitdagray/csv-to-sql/blob/main/CODE_OF_CONDUCT.md).
74 changes: 0 additions & 74 deletions index.js

This file was deleted.

Loading