You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@@ -7,80 +7,132 @@ Welcome to **Steam Sales Analysis** – an innovative project designed to harnes
7
7
8
8
But we don’t stop there. The culmination of this data journey sees the information elegantly loaded into a MySQL database hosted on Aiven Cloud. From this solid foundation, we take it a step further: the data is analyzed and visualized through dynamic and interactive Tableau dashboards. This transforms raw numbers into actionable insights, offering a clear window into gaming trends and sales performance. Join us as we dive deep into the data and bring the world of gaming to life!
9
9
10
-
# Setup Instructions
11
-
12
-
## General Use Case
10
+
# `steamstore` CLI
13
11
12
+
## Setup
13
+
### Installing the package
14
14
For general use, setting up the environment and dependencies is straightforward:
source game/bin/activate # On Windows use `game\Scripts\activate`
52
-
```
53
-
- Using `conda`:
54
-
```bash
55
-
conda env create -f environment.yml
56
-
conda activate game
57
-
```
37
+
To load the variables from the `.env` file into your current terminal session, you can use the `export` command along with the `dotenv` command if you have the `dotenv` utility installed.
58
38
59
-
3. **Install dependencies**:
60
-
- Install general dependencies:
61
-
```bash
62
-
pip install -r requirements.txt
63
-
```
64
-
- Install development dependencies:
65
-
```bash
66
-
pip install -r dev-requirements.txt
67
-
```
39
+
**Using `export` directly (manual method):**
68
40
69
-
4. **Configuration**:
70
-
- Create an `.env` file in the root directory of the repository.
71
-
- Add the following variables to the `.env` file:
72
-
```ini
73
-
# Database configuration
74
-
MYSQL_USERNAME=<your_mysql_username>
75
-
MYSQL_PASSWORD=<your_mysql_password>
76
-
MYSQL_HOST=<your_mysql_host>
77
-
MYSQL_PORT=<your_mysql_port>
78
-
MYSQL_DB_NAME=<your_mysql_db_name>
79
-
```
41
+
```bash
42
+
export$(grep -v '^#' .env | xargs)
43
+
```
80
44
81
-
# `steamstore` CLI
45
+
- `grep -v '^#' .env` removes any comments from the file.
46
+
- `xargs` converts the output into environment variable export commands.
47
+
48
+
**Using `dotenv` (requires installation):**
49
+
50
+
If you prefer a tool, you can use `dotenv`:
51
+
52
+
- Install `dotenv`if you don't have it:
53
+
54
+
```bash
55
+
sudo apt-get install python3-dotenv
56
+
```
57
+
58
+
- Then, use the following command to load the `.env` file:
59
+
60
+
```bash
61
+
dotenv
62
+
```
63
+
64
+
**Using `source` (not typical for `.env` but useful for `.sh` files):**
82
65
83
-
CLI for Steam Store Data Ingestion ETL Pipeline
66
+
If your `.env` file is simple, you can use `source` directly (this method assumes no special parsing is needed):
67
+
68
+
```bash
69
+
source .env
70
+
```
71
+
72
+
Note that `source` works well if your `.env` file only contains simple `KEY=VALUE` pairs.
73
+
74
+
2. **Verify the Variables**
75
+
76
+
After loading, you can check that the environment variables are set:
77
+
78
+
```bash
79
+
echo $MYSQL_USERNAME
80
+
```
81
+
82
+
#### For Windows
83
+
84
+
1. **Load `.env` Variables into PowerShell**
85
+
86
+
You can use a PowerShell script to load the variables from the `.env` file.
87
+
88
+
**Create a PowerShell script (e.g., `load_env.ps1`):**
0 commit comments