Skip to content

Commit a6c56f1

Browse files
Toggled mach speed instructions for variety of shells (#27)
* Mach speed instructions for variety of shells * Consistent python reference for pip upgrade * Apply suggestions from code review Move the "Prerequisites: Python >= 3.5" directly underneath the "Running this project" H2 Co-authored-by: Kira Furuichi <[email protected]> * Apply suggestions from code review Expand the description in the "What's in this repo?" section Co-authored-by: Kira Furuichi <[email protected]> Co-authored-by: Kira Furuichi <[email protected]>
1 parent 0c6c14e commit a6c56f1

File tree

1 file changed

+127
-18
lines changed

1 file changed

+127
-18
lines changed

README.md

+127-18
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,14 @@
1-
## Testing dbt project: `jaffle_shop`
1+
# Testing dbt project: `jaffle_shop`
22

33
`jaffle_shop` is a fictional ecommerce store. This dbt project transforms raw data from an app database into a customers and orders model ready for analytics.
44

5-
### What is this repo?
5+
<details>
6+
<summary>
7+
8+
## What is this repo?
9+
10+
</summary>
11+
612
What this repo _is_:
713
- A self-contained playground dbt project, useful for testing out scripts, and communicating some of the core dbt concepts.
814

@@ -14,14 +20,24 @@ What this repo _is not_:
1420
- CI/CD integrations
1521
- A demonstration of using dbt for a high-complex project, or a demo of advanced features (e.g. macros, packages, hooks, operations) — we're just trying to keep things simple here!
1622

17-
### What's in this repo?
18-
This repo contains [seeds](https://docs.getdbt.com/docs/building-a-dbt-project/seeds) that includes some (fake) raw data from a fictional app.
23+
</details>
24+
25+
<details>
26+
<summary>
27+
28+
## What's in this repo?
29+
30+
</summary>
31+
32+
This repo contains [seeds](https://docs.getdbt.com/docs/building-a-dbt-project/seeds) that includes some (fake) raw data from a fictional app along with some basic dbt [models](https://docs.getdbt.com/docs/building-a-dbt-project/building-models), tests, and docs for this data.
1933

2034
The raw data consists of customers, orders, and payments, with the following entity-relationship diagram:
2135

2236
![Jaffle Shop ERD](/etc/jaffle_shop_erd.png)
2337

24-
### Why should I care about this repo?
38+
</details>
39+
40+
## Why should I care about this repo?
2541
If you're just starting your cloud data warehouse journey and are hungry to get started with dbt before your organization officially gets a data warehouse, you should check out this repo.
2642

2743
If you want to run 28 SQL operations with dbt in less than `1 second`, for free, and all on your local machine, you should check out this repo.
@@ -33,11 +49,16 @@ If you want an adrenaline rush from a process that used to take dbt newcomers `1
3349

3450
[Verified GitHub Action on dbt Performance](https://github.com/dbt-labs/jaffle_shop_duckdb/runs/7141529753?check_suite_focus=true#step:4:306)
3551

36-
### Running this project
52+
## Running this project
53+
Prerequisities: Python >= 3.5
54+
55+
### Mach Speed: No explanation needed
3756

38-
**Mach Speed: No explanation needed**
3957
> Run `dbt` as fast as possible in a single copy and paste motion!
4058
59+
<details open>
60+
<summary>POSIX bash/zsh</summary>
61+
4162
```shell
4263
git clone https://github.com/dbt-labs/jaffle_shop_duckdb.git
4364
cd jaffle_shop_duckdb
@@ -50,8 +71,96 @@ dbt build
5071
dbt docs generate
5172
dbt docs serve
5273
```
74+
</details>
5375

54-
Prerequisities: Python >= 3.5
76+
<details>
77+
<summary>POSIX fish</summary>
78+
79+
```shell
80+
git clone https://github.com/dbt-labs/jaffle_shop_duckdb.git
81+
cd jaffle_shop_duckdb
82+
python3 -m venv venv
83+
source venv/bin/activate.fish
84+
python3 -m pip install --upgrade pip
85+
python3 -m pip install -r requirements.txt
86+
source venv/bin/activate.fish
87+
dbt build
88+
dbt docs generate
89+
dbt docs serve
90+
```
91+
</details>
92+
93+
<details>
94+
<summary>POSIX csh/tcsh</summary>
95+
96+
```shell
97+
git clone https://github.com/dbt-labs/jaffle_shop_duckdb.git
98+
cd jaffle_shop_duckdb
99+
python3 -m venv venv
100+
source venv/bin/activate.csh
101+
python3 -m pip install --upgrade pip
102+
python3 -m pip install -r requirements.txt
103+
source venv/bin/activate.csh
104+
dbt build
105+
dbt docs generate
106+
dbt docs serve
107+
```
108+
</details>
109+
110+
<details>
111+
<summary>POSIX PowerShell Core</summary>
112+
113+
```shell
114+
git clone https://github.com/dbt-labs/jaffle_shop_duckdb.git
115+
cd jaffle_shop_duckdb
116+
python3 -m venv venv
117+
venv/bin/Activate.ps1
118+
python3 -m pip install --upgrade pip
119+
python3 -m pip install -r requirements.txt
120+
venv/bin/Activate.ps1
121+
dbt build
122+
dbt docs generate
123+
dbt docs serve
124+
```
125+
</details>
126+
127+
<details>
128+
<summary>Windows cmd.exe</summary>
129+
130+
```shell
131+
git clone https://github.com/dbt-labs/jaffle_shop_duckdb.git
132+
cd jaffle_shop_duckdb
133+
python -m venv venv
134+
venv\Scripts\activate.bat
135+
python -m pip install --upgrade pip
136+
python -m pip install -r requirements.txt
137+
venv\Scripts\activate.bat
138+
dbt build
139+
dbt docs generate
140+
dbt docs serve
141+
```
142+
</details>
143+
144+
<details>
145+
<summary>Windows PowerShell</summary>
146+
147+
```shell
148+
git clone https://github.com/dbt-labs/jaffle_shop_duckdb.git
149+
cd jaffle_shop_duckdb
150+
python -m venv venv
151+
venv\Scripts\Activate.ps1
152+
python -m pip install --upgrade pip
153+
python -m pip install -r requirements.txt
154+
venv\Scripts\Activate.ps1
155+
dbt build
156+
dbt docs generate
157+
dbt docs serve
158+
```
159+
</details>
160+
161+
162+
163+
### Step-by-step explanation
55164

56165
To get up and running with this project:
57166

@@ -66,13 +175,13 @@ To get up and running with this project:
66175

67176
Expand your shell below:
68177

69-
<details>
178+
<details open>
70179
<summary>POSIX bash/zsh</summary>
71180

72181
```shell
73182
python3 -m venv venv
74183
source venv/bin/activate
75-
venv/bin/python3 -m pip install --upgrade pip
184+
python3 -m pip install --upgrade pip
76185
python3 -m pip install -r requirements.txt
77186
source venv/bin/activate
78187
```
@@ -84,7 +193,7 @@ To get up and running with this project:
84193
```shell
85194
python3 -m venv venv
86195
source venv/bin/activate.fish
87-
venv/bin/python3 -m pip install --upgrade pip
196+
python3 -m pip install --upgrade pip
88197
python3 -m pip install -r requirements.txt
89198
source venv/bin/activate.fish
90199
```
@@ -96,7 +205,7 @@ To get up and running with this project:
96205
```shell
97206
python3 -m venv venv
98207
source venv/bin/activate.csh
99-
venv/bin/python3 -m pip install --upgrade pip
208+
python3 -m pip install --upgrade pip
100209
python3 -m pip install -r requirements.txt
101210
source venv/bin/activate.csh
102211
```
@@ -108,7 +217,7 @@ To get up and running with this project:
108217
```shell
109218
python3 -m venv venv
110219
venv/bin/Activate.ps1
111-
venv/bin/python3 -m pip install --upgrade pip
220+
python3 -m pip install --upgrade pip
112221
python3 -m pip install -r requirements.txt
113222
venv/bin/Activate.ps1
114223
```
@@ -164,7 +273,7 @@ To get up and running with this project:
164273
```shell
165274
$ python3 -m venv venv
166275
$ source venv/bin/activate
167-
(venv) $ venv/bin/python3 -m pip install --upgrade pip
276+
(venv) $ python3 -m pip install --upgrade pip
168277
(venv) $ python3 -m pip install -r requirements.txt
169278
```
170279

@@ -247,7 +356,7 @@ To get up and running with this project:
247356
dbt docs serve
248357
```
249358
250-
### Running `build` steps independently
359+
## Running `build` steps independently
251360
252361
1. Load the CSVs with the demo data set. This materializes the CSVs as tables in your target schema. Note that a typical dbt project **does not require this step** since dbt assumes your raw data is already in your warehouse.
253362
```shell
@@ -266,13 +375,13 @@ To get up and running with this project:
266375
dbt test
267376
```
268377
269-
### Browsing the data
378+
## Browsing the data
270379
Some options:
271380
- [duckcli](https://pypi.org/project/duckcli/)
272381
- [DuckDB CLI](https://duckdb.org/docs/installation/?environment=cli)
273382
- [How to set up DBeaver SQL IDE for DuckDB](https://duckdb.org/docs/guides/sql_editors/dbeaver)
274383
275-
#### Troubleshooting
384+
### Troubleshooting
276385
277386
You may get an error like this, in which case you will need to disconnect from any sessions that are locking the database:
278387
```
@@ -287,4 +396,4 @@ Very worst-case, deleting the database file will get you back in action (BUT you
287396
For more information on dbt:
288397
- Read the [introduction to dbt](https://docs.getdbt.com/docs/introduction)
289398
- Read the [dbt viewpoint](https://docs.getdbt.com/docs/about/viewpoint)
290-
- Join the [dbt Community](http://community.getdbt.com/)
399+
- Join the [dbt Community](http://community.getdbt.com/)

0 commit comments

Comments
 (0)