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
Copy file name to clipboardExpand all lines: getting-started/setup-building.rst
+39-18Lines changed: 39 additions & 18 deletions
Original file line number
Diff line number
Diff line change
@@ -666,40 +666,61 @@ Contribute using GitHub Codespaces
666
666
667
667
What is GitHub Codespaces?
668
668
--------------------------
669
-
670
-
If you'd like to start contributing to CPython without needing to set up a local developer environment, you can use `GitHub Codespaces <https://github.com/features/codespaces>`_.
671
-
Codespaces is a cloud-based development environment offered by GitHub that allows developers to write, build, test, and debug code directly within their web browser or in Visual Studio Code (VS Code).
672
-
673
-
To help you get started, CPython contains a `devcontainer folder <https://github.com/python/cpython/tree/main/.devcontainer>`_ with a JSON configuration file that provides consistent and versioned codespace configurations for all users of the project.
674
-
It also contains a Dockerfile that allows you to set up the same environment but locally in a Docker container if you'd prefer to use that directly.
669
+
set up the same environment but locally in a docker container if you'd prefer th
670
+
If you'd like to start contributing to CPython without needing to set up a local
with a JSON configuration file that provides consistent and versioned codespace
680
+
configurations for all users of the project. It also contains a Dockerfile that
681
+
allows you to set up the same environment but locally in a Docker container if
682
+
you'd prefer to use that directly.
675
683
676
684
.. _codespaces-create-a-codespace:
677
685
678
686
Create a CPython codespace
679
687
--------------------------
680
688
681
689
Here are the basic steps needed to contribute a patch using Codespaces.
682
-
You first need to navigate to the `CPython repo <https://github.com/python/cpython>`_ hosted on GitHub.
690
+
You first need to navigate to the
691
+
`CPython repo <https://github.com/python/cpython>`_ hosted on GitHub.
683
692
684
693
Then you will need to:
685
694
686
-
1. Press the ``,`` key to launch the codespace setup screen for the current branch (alternatively, click the green :guilabel:`Code` button and choose the ``codespaces`` tab and then press the green :guilabel:`Create codespace on main` button).
687
-
3. A screen should appear that lets you know your codespace is being set up. (Note: Since the CPython devcontainer is provided, codespaces will use the configuration it specifies.)
688
-
4. A `web version of VS Code <https://vscode.dev/>`_ will open inside your web browser, already linked up with your code and a terminal to the remote codespace where CPython and its documentation have already been built.
689
-
5. Use the terminal with the usual Git commands to create a new branch, commit and push your changes once you're ready!
690
-
691
-
If you close your repository and come back later you can always resume your codespace by navigating to the CPython repo, selecting the codespaces tab and selecting your most recent codespaces session.
692
-
You should then be able to pick up from where you left off!
695
+
1. Press the ``,`` key to launch the codespace setup screen for the current
696
+
branch (alternatively, click the green :guilabel:`Code` button and choose
697
+
the ``codespaces`` tab and then press the
698
+
green :guilabel:`Create codespace on main` button).
699
+
2. A screen should appear that lets you know your codespace is being set up.
700
+
(Note: Since the CPython devcontainer is provided, codespaces will use the
701
+
configuration it specifies.)
702
+
3. A `web version of VS Code <https://vscode.dev/>`_ will open inside your web
703
+
browser, already linked up with your code and a terminal to the remote
704
+
codespace where CPython and its documentation have already been built.
705
+
4. Use the terminal with the usual Git commands to create a new branch, commit
706
+
and push your changes once you're ready!
707
+
708
+
If you close your repository and come back later you can always resume your
709
+
codespace by navigating to the CPython repo, selecting the codespaces tab and
710
+
selecting your most recent codespaces session. You should then be able to pick
711
+
up from where you left off!
693
712
694
713
.. _codespaces-use-locally:
695
714
696
715
Use Codespaces Locally
697
716
----------------------
698
717
699
-
On the bottom left side of the codespace screen you will see a green or grey square that says :guilabel:`Codespaces`.
700
-
You can click this for additional options. If you prefer working in a locally installed copy of VS Code you can select the option ``Open in VS Code``.
701
-
You will still be working on the remote codespace instance, thus using the remote instance's compute power.
702
-
The compute power may be a much higher spec than your local machine which can be helpful.
718
+
On the bottom left side of the codespace screen you will see a green or grey
719
+
square that says :guilabel:`Codespaces`. You can click this for additional
720
+
options. If you prefer working in a locally installed copy of VS Code you can
721
+
select the option ``Open in VS Code``. You will still be working on the remote
722
+
codespace instance, thus using the remote instance's compute power. The compute
723
+
power may be a much higher spec than your local machine which can be helpful.
0 commit comments