Skip to content

Commit 283aa44

Browse files
committed
Add .devcontainer for Visual Studio Code and Github Codespaces
1 parent d86d805 commit 283aa44

File tree

2 files changed

+25
-0
lines changed

2 files changed

+25
-0
lines changed

.devcontainer/devcontainer.json

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
{
2+
"name": "pydata-book",
3+
// We use the universal image and not the python one because containers based on the default image are not counted as used storage in github codespaces.
4+
// https://docs.github.com/en/billing/managing-billing-for-github-codespaces/about-billing-for-github-codespaces
5+
"image": "mcr.microsoft.com/devcontainers/universal:2-linux",
6+
"forwardPorts": [
7+
6006,
8+
8888
9+
],
10+
"customizations": {
11+
"vscode": {
12+
"extensions": [
13+
"ms-python.python",
14+
"ms-toolsai.jupyter"
15+
]
16+
}
17+
},
18+
"onCreateCommand": "pip3 install --user -r requirements.txt notebook",
19+
"postStartCommand": "jupyter notebook --ip='0.0.0.0' --port=8888 --no-browser"
20+
}

README.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,11 @@ reorganized book materials on the [`1st-edition` branch][2].
3535
* [Chapter 13: Data Analysis Examples](http://nbviewer.ipython.org/github/pydata/pydata-book/blob/3rd-edition/ch13.ipynb)
3636
* [Appendix A: Advanced NumPy](http://nbviewer.ipython.org/github/pydata/pydata-book/blob/3rd-edition/appa.ipynb)
3737

38+
You can also run these notebooks using dev containers:
39+
40+
* [![Open in Visual Studio Code](https://img.shields.io/static/v1?label=&message=Open%20in%20Visual%20Studio%20Code&color=blue&logo=visualstudiocode&style=flat)](https://vscode.dev/redirect?url=vscode://ms-vscode-remote.remote-containers/cloneInVolume?url=https://github.com/wesm/pydata-book)
41+
* [![Open in Github Codespaces](https://img.shields.io/static/v1?label=&message=Open%20in%20Github%20Codespaces&color=2f362d&logo=github)](https://codespaces.new/wesm/pydata-book?quickstart=1&hide_repo_select=true)
42+
3843
## License
3944

4045
### Code

0 commit comments

Comments
 (0)