https://github.com/Shrimad-Bhagwat/CSV-Importer
Simple Python App to import data from CSV to Google Sheets
https://github.com/Shrimad-Bhagwat/CSV-Importer
csv google-sheets python3
Last synced: about 2 months ago
JSON representation
Simple Python App to import data from CSV to Google Sheets
- Host: GitHub
- URL: https://github.com/Shrimad-Bhagwat/CSV-Importer
- Owner: Shrimad-Bhagwat
- Created: 2023-10-20T09:57:19.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2023-10-20T10:04:11.000Z (over 1 year ago)
- Last Synced: 2024-04-18T05:50:37.112Z (about 1 year ago)
- Topics: csv, google-sheets, python3
- Language: Python
- Homepage:
- Size: 51.1 MB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# StackIt Hiring Assignment
## โจ **Problem Statement: Crafting a CSV Importer for Google Sheets** โจ
**Problem Statement**:
Make a CSV Importer for Google Sheets that lets users drag and drop CSV files onto the Google Sheet. The moment they drop the CSV file, allow them to select which columns to import ๐๏ธ.## Tech Stack ๐ ๏ธ
- Python ๐
- Tkinter ๐ฅ๏ธ
- gspread ๐
- pandas ๐ผ
- OAuth2 ๐## Workflow ๐
1. **Create or Use Existing Sheet** ๐๏ธ
Users have the option to either create a new Google Sheet or use an existing one for the data import. If they choose to create a new sheet, they will be prompted to provide a file name and an access email for sharing the sheet.2. **Import Data** ๐ค
Once the user confirms their selections, then the user is asked to upload the csv file.If a new sheet was created, it will be shared with the specified email for collaborative access.3. **Upload CSV** ๐
Users then have to click the "Upload CSV" button. This action prompts them to select a CSV file from their local system. The selected file will be used for further processing.4. **Select Columns** โ
After the CSV file is uploaded, users are presented with a list of columns from the file. They can then choose which columns they want to import into the Google Sheet. This step allows for customization and flexibility in data selection.5. **Close Application** ๐
After the import process is complete, users have the option to close the application using the "Close" button. This concludes the workflow.This workflow ensures a user-friendly experience, guiding users through the necessary steps to import CSV data into Google Sheets. It offers flexibility in data selection, allows for both new and existing sheets, and provides clear instructions for a smooth process.
## Usage ๐งพ
**Create a Service Account Key (***Important Step***)** ๐:
For this project to work on your device you must have the service account key.
- Go to the [Google Cloud Console](https://console.cloud.google.com/).
- Select your project or create a new one.
- In the sidebar, navigate to the "APIs & Services" > "Credentials" section.
- Click "Create credentials" and select "Service Account Key".
- Fill out the form and select the role "Editor" or "Owner".
- Click "Create" to generate the key. This will download a JSON file containing your credentials.
- Place this JSON file in the project directory with the name `csv_key.json` inside data.1. Launch the application. ๐
2. Choose to either create a new Google Sheet or use an existing one. ๐๏ธ
3. Click the "Upload CSV" button to select a CSV file. ๐
4. Select the columns you want to import. โ
5. Confirm the import. โ## Developer's Section ๐จโ๐ป๐ฉโ๐ป
Watch this demo video walkthrough. Feel free to leave comments and ask any questions.
### [Demo Video](https://youtu.be/tQpk7mAm6qk)
[](https://youtu.be/tQpk7mAm6qk)
## Contributing ๐ค
Contributions are welcome! Feel free to open an issue or submit a pull request. ๐ ๏ธ
To contribute to this project, follow these steps:
1. **Fork this repository** ๐ด: Click the "Fork" button at the top-right corner of this page to create your own copy of the repository.
2. **Clone your fork** ๐ฅ: Use `git clone` to clone your forked repository to your local machine. Replace `[your_username]` with your GitHub username.
```bash
git clone https://github.com/[your_username]/StackIt-Hiring-Assignment.git
```3. **Create a new branch** ๐ฟ: Create a new branch for your contributions. This keeps your changes isolated from the `main` branch.
```bash
cd StackIt-Hiring-Assignment
git checkout -b feature/new-feature
```4. **Set up a virtual environment** โ๏ธ: It's recommended to create a virtual environment to manage dependencies.
```bash
python -m venv venv
source venv/bin/activate
```5. **Install dependencies** ๐ฆ: Install the required packages listed in `requirements.txt`.
```bash
pip install -r requirements.txt
```6. **Create a Service Account Key (***Important Step***)** ๐:
- Go to the [Google Cloud Console](https://console.cloud.google.com/).
- Select your project or create a new one.
- In the sidebar, navigate to the "APIs & Services" > "Credentials" section.
- Click "Create credentials" and select "Service Account Key".
- Fill out the form and select the role "Editor" or "Owner".
- Click "Create" to generate the key. This will download a JSON file containing your credentials.
- Place this JSON file in the project directory with the name `csv_key.json` inside data.7. **Make your changes** ๐ ๏ธ: Make the necessary changes and improvements in the code.
8. **Commit your changes** ๐: Once you're satisfied with your changes, commit them with a descriptive message.
```bash
git add .
git commit -m "Add your commit message here"
```9. **Push your changes** ๐: Push your changes to your forked repository.
```bash
git push origin feature/new-feature
```10. **Create a pull request** ๐: Go to the original repository and click on the "New Pull Request" button. Provide a clear description of your changes.
11. **Review and merge** โ๏ธ: Collaborators will review your pull request. Once approved, your changes will be merged into the main branch.
Now you're all set to start contributing to this project! Happy coding! ๐
## License ๐
This project is licensed under the [MIT License](link_to_license). ๐