From 00eb561042e74ae4b1102381c820f4cf811053d4 Mon Sep 17 00:00:00 2001 From: melissawm Date: Mon, 26 Jun 2023 18:13:30 -0300 Subject: [PATCH 1/6] DOC: Add documentation on codespaces usage --- .devcontainer/devcontainer.json | 19 +++--- doc/devel/codespaces.md | 107 ++++++++++++++++++++++++++++++++ doc/devel/contribute.rst | 97 +++++++++++++++++++++++------ 3 files changed, 196 insertions(+), 27 deletions(-) create mode 100644 doc/devel/codespaces.md diff --git a/.devcontainer/devcontainer.json b/.devcontainer/devcontainer.json index 87d381c9a68b..a43a383536a1 100644 --- a/.devcontainer/devcontainer.json +++ b/.devcontainer/devcontainer.json @@ -1,4 +1,3 @@ - { "hostRequirements": { "memory": "8gb", @@ -22,11 +21,17 @@ "ms-vscode.live-server" ], "settings": {} + }, + "codespaces": { + "openFiles": [ + "README.md", + "doc/devel/codespaces.md" + ] } -}, -"portsAttributes": { - "6080": { - "label": "desktop" - } -} + }, + "portsAttributes": { + "6080": { + "label": "desktop" + } + } } diff --git a/doc/devel/codespaces.md b/doc/devel/codespaces.md new file mode 100644 index 000000000000..3a41aae560a3 --- /dev/null +++ b/doc/devel/codespaces.md @@ -0,0 +1,107 @@ +# Contributing to Matplotlib using GitHub codespaces + +You've discovered a bug or something else you want to change +in Matplotlib — excellent! + +You've worked out a way to fix it — even better! + +You want to tell us about it — best of all! + +This project is a community effort, and everyone is welcome to contribute. +Everyone within the community is expected to abide by our +[Code of Conduct](../../CODE_OF_CONDUCT.md). + +## GitHub codespaces contribution workflow + +The preferred way to contribute to Matplotlib is to fork the main +repository at https://github.com/matplotlib/matplotlib, then submit a "pull +request" (PR). You can do this by cloning a copy of the Maplotlib repository to +your own computer, or alternatively using +[GitHub Codespaces](https://docs.github.com/codespaces) (a cloud-based +in-browser development environment, that comes with the appropriated setup to +contribute to Matplotlib). + +A brief overview of the workflows is as follows. + +1. Go to the GitHub web interface +2. Fork the [project repository](https://github.com/matplotlib/matplotlib): +3. Open codespaces on your fork by clicking on the green "Code" button on the + GitHub web interface and selecting the "Codespaces" tab. Next, click on "Open + codespaces on ". You will be able to change branches later, + so you can select the default `main` branch. + + After the codespace is created, you will be taken to a new browser tab where + you can use the terminal to activate a pre-defined conda environment called + `mpl-dev`: + + ``` + conda activate mpl-dev + ``` + +4. Install the local version of Matplotlib with: + + ``` + python -m pip install -e . + ``` + + (See [Setting up Matplotlib for development](https://matplotlib.org/devdocs/devel/development_setup.html) + for detailed instructions.) + +5. Create a branch to hold your changes: + + ``` + git checkout -b my-feature origin/main + ``` + + and start making changes. Never work in the `main` branch! + +6. Work on this task using Git to do the version control. Codespaces persist for + some time (check the [documentation for details](https://docs.github.com/codespaces/getting-started/the-codespace-lifecycle)) + and can be managed on https://github.com/codespaces. When you're done editing + e.g., `lib/matplotlib/collections.py`, do: + + ``` + git add lib/matplotlib/collections.py + git commit + ``` + + to record your changes in Git, then push them to your GitHub fork with: + + ``` + git push -u origin my-feature + ``` + +Finally, go to the web page of your fork of the Matplotlib repo, and click +'Pull request' to send your changes to the maintainers for review. + +## Other stuff you may want to do + +* If you need to run tests to verify your changes before sending your PR, you + can run (in your `mpl-dev` conda environment): + + ``` + pytest + ``` + +* If you need to build the documentation, you can move to the `doc` folder and + run (in your `mpl-dev` conda environment): + + ``` + cd doc + make html + ``` + +* If you need to open a GUI window with Matplotlib output, our Codespaces + configuration includes a + [light-weight Fluxbox-based desktop](https://github.com/devcontainers/features/tree/main/src/desktop-lite). + You can use it by connecting to this desktop via your web browser. To do this: + + 1. Press `F1` or `Ctrl/Cmd+Shift+P` and select `Ports: Focus on Ports View` in + VS Code to bring it into focus. Open the ports view in your tool, select + the `noVNC` port, and click the Globe icon. + 2. In the browser that appears, click the Connect button and enter the desktop + password (`vscode` by default). + + Check the + [GitHub instructions](https://github.com/devcontainers/features/tree/main/src/desktop-lite#connecting-to-the-desktop) + for more details on connecting to the desktop. diff --git a/doc/devel/contribute.rst b/doc/devel/contribute.rst index c6e1a2199fae..2f8ed9271e10 100644 --- a/doc/devel/contribute.rst +++ b/doc/devel/contribute.rst @@ -222,39 +222,96 @@ How to contribute The preferred way to contribute to Matplotlib is to fork the `main repository `__ on GitHub, -then submit a "pull request" (PR). +then submit a "pull request" (PR). You can do this by cloning a copy of the +Maplotlib repository to your own computer, or alternatively using +`GitHub Codespaces `_ (a cloud-based +in-browser development environment, that comes with the appropriated setup to +contribute to Matplotlib). -A brief overview is: +A brief overview of the workflows is as follows. -1. `Create an account `_ on GitHub if you do not - already have one. +.. tab-set:: -2. Fork the `project repository `_: - click on the 'Fork' button near the top of the page. This creates a copy of - the code under your account on the GitHub server. + .. tab-item:: Local development -3. Clone this copy to your local disk:: + 1. `Create an account `_ on GitHub if you do + not already have one. - git clone https://github.com//matplotlib.git + 2. Fork the + `project repository `_: + click on the 'Fork' button near the top of the page. This creates a + copy of the code under your account on the GitHub server. -4. Enter the directory and install the local version of Matplotlib. - See :ref:`installing_for_devs` for instructions + 3. Clone this copy to your local disk:: -5. Create a branch to hold your changes:: + git clone https://github.com//matplotlib.git - git checkout -b my-feature origin/main + 4. Enter the directory and install the local version of Matplotlib. + See :ref:`installing_for_devs` for instructions - and start making changes. Never work in the ``main`` branch! + 5. Create a branch to hold your changes:: -6. Work on this copy, on your computer, using Git to do the version control. - When you're done editing e.g., ``lib/matplotlib/collections.py``, do:: + git checkout -b my-feature origin/main - git add lib/matplotlib/collections.py - git commit + and start making changes. Never work in the ``main`` branch! - to record your changes in Git, then push them to GitHub with:: + 6. Work on this copy, on your computer, using Git to do the version + control. When you're done editing e.g., + ``lib/matplotlib/collections.py``, do:: - git push -u origin my-feature + git add lib/matplotlib/collections.py + git commit + + to record your changes in Git, then push them to GitHub with:: + + git push -u origin my-feature + + .. tab-item:: Using GitHub Codespaces + + 1. `Create an account `_ on GitHub if you do + not already have one. + + 2. Fork the + `project repository `_: + click on the 'Fork' button near the top of the page. This creates a + copy of the code under your account on the GitHub server. + + 3. Open codespaces on your fork by clicking on the green "Code" button + on the GitHub web interface and selecting the "Codespaces" tab. Next, + click on "Open codespaces on ". You will be able to + change branches later, so you can select the default ``main`` branch. + + After the codespace is created, you will be taken to a new browser + tab where you can use the terminal to activate a pre-defined conda + environment called ``mpl-dev``:: + + conda activate mpl-dev + + 4. Install the local version of Matplotlib with:: + + python -m pip install -e . + + (See :ref:`installing_for_devs` for detailed instructions.) + + 5. Create a branch to hold your changes:: + + git checkout -b my-feature origin/main + + and start making changes. Never work in the ``main`` branch! + + 6. Work on this task using Git to do the version control. Codespaces + persist for some time (check the `documentation for details + `_) + and can be managed on https://github.com/codespaces. When you're done + editing e.g., ``lib/matplotlib/collections.py``, do:: + + git add lib/matplotlib/collections.py + git commit + + to record your changes in Git, then push them to your GitHub fork + with:: + + git push -u origin my-feature Finally, go to the web page of your fork of the Matplotlib repo, and click 'Pull request' to send your changes to the maintainers for review. From a28db8665683188cb30d985618935813199500ea Mon Sep 17 00:00:00 2001 From: melissawm Date: Mon, 26 Jun 2023 20:12:03 -0300 Subject: [PATCH 2/6] MAINT: Fix port forwarding for desktop on codespaces --- .devcontainer/devcontainer.json | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/.devcontainer/devcontainer.json b/.devcontainer/devcontainer.json index a43a383536a1..814c066c43b1 100644 --- a/.devcontainer/devcontainer.json +++ b/.devcontainer/devcontainer.json @@ -12,6 +12,12 @@ }, "onCreateCommand": ".devcontainer/setup.sh", "postCreateCommand": "", + "forwardPorts": [6080], + "portsAttributes": { + "6080": { + "label": "desktop" + } + }, "customizations": { "vscode": { "extensions": [ @@ -28,10 +34,5 @@ "doc/devel/codespaces.md" ] } - }, - "portsAttributes": { - "6080": { - "label": "desktop" - } } } From 9a089fb03e92b7419e40b16b1fb1ce172c29e116 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Melissa=20Weber=20Mendon=C3=A7a?= Date: Fri, 11 Aug 2023 11:07:11 -0300 Subject: [PATCH 3/6] Addressing reviewer's comments * Reducing duplication by linking out to contribute guide * Rewording instructions and adding notes on codespaces-specific workflows --- doc/devel/codespaces.md | 106 ++------------------------------------- doc/devel/contribute.rst | 100 +++++++++++++++++------------------- 2 files changed, 51 insertions(+), 155 deletions(-) diff --git a/doc/devel/codespaces.md b/doc/devel/codespaces.md index 3a41aae560a3..f0a4f96ba249 100644 --- a/doc/devel/codespaces.md +++ b/doc/devel/codespaces.md @@ -1,107 +1,9 @@ # Contributing to Matplotlib using GitHub codespaces -You've discovered a bug or something else you want to change -in Matplotlib — excellent! +For a general overview of contributing to Matplotlib, see https://matplotlib.org/devdocs/devel/index.html -You've worked out a way to fix it — even better! +For instructions on how to submit Pull Requests using GitHub codespaces, see https://matplotlib.org/devdocs/devel/contribute.html#contributing-code -You want to tell us about it — best of all! +For instructions on running tests to verify your changes, see https://matplotlib.org/devdocs/devel/testing.html -This project is a community effort, and everyone is welcome to contribute. -Everyone within the community is expected to abide by our -[Code of Conduct](../../CODE_OF_CONDUCT.md). - -## GitHub codespaces contribution workflow - -The preferred way to contribute to Matplotlib is to fork the main -repository at https://github.com/matplotlib/matplotlib, then submit a "pull -request" (PR). You can do this by cloning a copy of the Maplotlib repository to -your own computer, or alternatively using -[GitHub Codespaces](https://docs.github.com/codespaces) (a cloud-based -in-browser development environment, that comes with the appropriated setup to -contribute to Matplotlib). - -A brief overview of the workflows is as follows. - -1. Go to the GitHub web interface -2. Fork the [project repository](https://github.com/matplotlib/matplotlib): -3. Open codespaces on your fork by clicking on the green "Code" button on the - GitHub web interface and selecting the "Codespaces" tab. Next, click on "Open - codespaces on ". You will be able to change branches later, - so you can select the default `main` branch. - - After the codespace is created, you will be taken to a new browser tab where - you can use the terminal to activate a pre-defined conda environment called - `mpl-dev`: - - ``` - conda activate mpl-dev - ``` - -4. Install the local version of Matplotlib with: - - ``` - python -m pip install -e . - ``` - - (See [Setting up Matplotlib for development](https://matplotlib.org/devdocs/devel/development_setup.html) - for detailed instructions.) - -5. Create a branch to hold your changes: - - ``` - git checkout -b my-feature origin/main - ``` - - and start making changes. Never work in the `main` branch! - -6. Work on this task using Git to do the version control. Codespaces persist for - some time (check the [documentation for details](https://docs.github.com/codespaces/getting-started/the-codespace-lifecycle)) - and can be managed on https://github.com/codespaces. When you're done editing - e.g., `lib/matplotlib/collections.py`, do: - - ``` - git add lib/matplotlib/collections.py - git commit - ``` - - to record your changes in Git, then push them to your GitHub fork with: - - ``` - git push -u origin my-feature - ``` - -Finally, go to the web page of your fork of the Matplotlib repo, and click -'Pull request' to send your changes to the maintainers for review. - -## Other stuff you may want to do - -* If you need to run tests to verify your changes before sending your PR, you - can run (in your `mpl-dev` conda environment): - - ``` - pytest - ``` - -* If you need to build the documentation, you can move to the `doc` folder and - run (in your `mpl-dev` conda environment): - - ``` - cd doc - make html - ``` - -* If you need to open a GUI window with Matplotlib output, our Codespaces - configuration includes a - [light-weight Fluxbox-based desktop](https://github.com/devcontainers/features/tree/main/src/desktop-lite). - You can use it by connecting to this desktop via your web browser. To do this: - - 1. Press `F1` or `Ctrl/Cmd+Shift+P` and select `Ports: Focus on Ports View` in - VS Code to bring it into focus. Open the ports view in your tool, select - the `noVNC` port, and click the Globe icon. - 2. In the browser that appears, click the Connect button and enter the desktop - password (`vscode` by default). - - Check the - [GitHub instructions](https://github.com/devcontainers/features/tree/main/src/desktop-lite#connecting-to-the-desktop) - for more details on connecting to the desktop. +For instructions on building the Matplotlib documentation, see https://matplotlib.org/devdocs/devel/document.html#documenting-matplotlib diff --git a/doc/devel/contribute.rst b/doc/devel/contribute.rst index 2f8ed9271e10..62e4d50af8c5 100644 --- a/doc/devel/contribute.rst +++ b/doc/devel/contribute.rst @@ -230,55 +230,26 @@ contribute to Matplotlib). A brief overview of the workflows is as follows. -.. tab-set:: +1. `Create an account `_ on GitHub if you do not + already have one. - .. tab-item:: Local development +2. Fork the `project repository `_: + click on the 'Fork' button near the top of the page. This creates a copy of + the code under your account on the GitHub server. - 1. `Create an account `_ on GitHub if you do - not already have one. +.. tab-set:: - 2. Fork the - `project repository `_: - click on the 'Fork' button near the top of the page. This creates a - copy of the code under your account on the GitHub server. + .. tab-item:: Local development 3. Clone this copy to your local disk:: git clone https://github.com//matplotlib.git - 4. Enter the directory and install the local version of Matplotlib. - See :ref:`installing_for_devs` for instructions - - 5. Create a branch to hold your changes:: - - git checkout -b my-feature origin/main - - and start making changes. Never work in the ``main`` branch! - - 6. Work on this copy, on your computer, using Git to do the version - control. When you're done editing e.g., - ``lib/matplotlib/collections.py``, do:: - - git add lib/matplotlib/collections.py - git commit - - to record your changes in Git, then push them to GitHub with:: - - git push -u origin my-feature - .. tab-item:: Using GitHub Codespaces - 1. `Create an account `_ on GitHub if you do - not already have one. - - 2. Fork the - `project repository `_: - click on the 'Fork' button near the top of the page. This creates a - copy of the code under your account on the GitHub server. - 3. Open codespaces on your fork by clicking on the green "Code" button on the GitHub web interface and selecting the "Codespaces" tab. Next, - click on "Open codespaces on ". You will be able to + click on "Open codespaces on ". You will be able to change branches later, so you can select the default ``main`` branch. After the codespace is created, you will be taken to a new browser @@ -287,31 +258,30 @@ A brief overview of the workflows is as follows. conda activate mpl-dev - 4. Install the local version of Matplotlib with:: +4. Install the local version of Matplotlib with:: - python -m pip install -e . + python -m pip install -e . - (See :ref:`installing_for_devs` for detailed instructions.) + (See :ref:`installing_for_devs` for detailed instructions.) - 5. Create a branch to hold your changes:: +5. Create a branch to hold your changes:: - git checkout -b my-feature origin/main + git checkout -b my-feature origin/main - and start making changes. Never work in the ``main`` branch! + and start making changes. Never work in the ``main`` branch! - 6. Work on this task using Git to do the version control. Codespaces - persist for some time (check the `documentation for details - `_) - and can be managed on https://github.com/codespaces. When you're done - editing e.g., ``lib/matplotlib/collections.py``, do:: +6. Work on this task using Git to do the version control. Codespaces persist for + some time (check the `documentation for details + `_) + and can be managed on https://github.com/codespaces. When you're done editing + e.g., ``lib/matplotlib/collections.py``, do:: - git add lib/matplotlib/collections.py - git commit + git add lib/matplotlib/collections.py + git commit - to record your changes in Git, then push them to your GitHub fork - with:: + to record your changes in Git, then push them to your GitHub fork with:: - git push -u origin my-feature + git push -u origin my-feature Finally, go to the web page of your fork of the Matplotlib repo, and click 'Pull request' to send your changes to the maintainers for review. @@ -319,6 +289,30 @@ Finally, go to the web page of your fork of the Matplotlib repo, and click For more detailed instructions on how to set up Matplotlib for development and best practices for contribution, see :ref:`installing_for_devs`. +.. note:: GitHub Codespaces workflows + + * If you need to open a GUI window with Matplotlib output on Codespaces, our + configuration includes a `light-weight Fluxbox-based desktop + `_. + You can use it by connecting to this desktop via your web browser. To do + this: + + 1. Press ``F1`` or ``Ctrl/Cmd+Shift+P`` and select + ``Ports: Focus on Ports View`` in the VSCode session to bring it into + focus. Open the ports view in your tool, select the ``noVNC`` port, and + click the Globe icon. + 2. In the browser that appears, click the Connect button and enter the desktop + password (``vscode`` by default). + + Check the `GitHub instructions + `_ + for more details on connecting to the desktop. + + * If you also built the documentation pages, you can view them using + Codespaces. Use the "Extensions" icon in the activity bar to install the + "Live Server" extension. Locate the ``doc/build/html`` folder in the + Explorer, right click the file you want to open and select "Open with Live + Server." .. _contributing_documentation: From 97c999cdb73a49c26f6aa949b3c3cac8c9cd5830 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Melissa=20Weber=20Mendon=C3=A7a?= Date: Fri, 11 Aug 2023 12:28:58 -0300 Subject: [PATCH 4/6] Fix Codespaces admonition title --- doc/devel/contribute.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/doc/devel/contribute.rst b/doc/devel/contribute.rst index 62e4d50af8c5..48aabfae286a 100644 --- a/doc/devel/contribute.rst +++ b/doc/devel/contribute.rst @@ -289,7 +289,7 @@ Finally, go to the web page of your fork of the Matplotlib repo, and click For more detailed instructions on how to set up Matplotlib for development and best practices for contribution, see :ref:`installing_for_devs`. -.. note:: GitHub Codespaces workflows +.. admonition:: GitHub Codespaces workflows * If you need to open a GUI window with Matplotlib output on Codespaces, our configuration includes a `light-weight Fluxbox-based desktop From 8c3a9c02faa261be891a48adb723a562be1e6744 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Melissa=20Weber=20Mendon=C3=A7a?= Date: Fri, 11 Aug 2023 18:48:49 -0300 Subject: [PATCH 5/6] Fix headings, wording and numbered list in codespaces docs Co-authored-by: marbled-toast <69227427+marbled-toast@users.noreply.github.com> Co-authored-by: hannah --- doc/devel/codespaces.md | 8 ++--- doc/devel/contribute.rst | 78 +++++++++++++++++++++------------------- 2 files changed, 45 insertions(+), 41 deletions(-) diff --git a/doc/devel/codespaces.md b/doc/devel/codespaces.md index f0a4f96ba249..cb002c9b2e6e 100644 --- a/doc/devel/codespaces.md +++ b/doc/devel/codespaces.md @@ -1,9 +1,9 @@ # Contributing to Matplotlib using GitHub codespaces -For a general overview of contributing to Matplotlib, see https://matplotlib.org/devdocs/devel/index.html +* For a general overview of contributing to Matplotlib, see https://matplotlib.org/devdocs/devel/index.html -For instructions on how to submit Pull Requests using GitHub codespaces, see https://matplotlib.org/devdocs/devel/contribute.html#contributing-code +* For instructions on how to submit Pull Requests using GitHub codespaces, see https://matplotlib.org/devdocs/devel/contribute.html#contributing-code -For instructions on running tests to verify your changes, see https://matplotlib.org/devdocs/devel/testing.html +* For instructions on running tests to verify your changes, see https://matplotlib.org/devdocs/devel/testing.html -For instructions on building the Matplotlib documentation, see https://matplotlib.org/devdocs/devel/document.html#documenting-matplotlib +* For instructions on building the Matplotlib documentation, see https://matplotlib.org/devdocs/devel/document.html#documenting-matplotlib diff --git a/doc/devel/contribute.rst b/doc/devel/contribute.rst index 48aabfae286a..4e03e0b2c811 100644 --- a/doc/devel/contribute.rst +++ b/doc/devel/contribute.rst @@ -224,11 +224,11 @@ The preferred way to contribute to Matplotlib is to fork the `main repository `__ on GitHub, then submit a "pull request" (PR). You can do this by cloning a copy of the Maplotlib repository to your own computer, or alternatively using -`GitHub Codespaces `_ (a cloud-based -in-browser development environment, that comes with the appropriated setup to -contribute to Matplotlib). +`GitHub Codespaces `_, a cloud-based +in-browser development environment that comes with the appropriated setup to +contribute to Matplotlib. -A brief overview of the workflows is as follows. +A brief overview of the workflow is as follows. 1. `Create an account `_ on GitHub if you do not already have one. @@ -247,22 +247,27 @@ A brief overview of the workflows is as follows. .. tab-item:: Using GitHub Codespaces - 3. Open codespaces on your fork by clicking on the green "Code" button - on the GitHub web interface and selecting the "Codespaces" tab. Next, - click on "Open codespaces on ". You will be able to - change branches later, so you can select the default ``main`` branch. + 3. Check out the Matplotlib repository and activate your development + environment: - After the codespace is created, you will be taken to a new browser - tab where you can use the terminal to activate a pre-defined conda - environment called ``mpl-dev``:: + a. Open codespaces on your fork by clicking on the green "Code" + button on the GitHub web interface and selecting the "Codespaces" + tab. Next, click on "Open codespaces on ". You + will be able to change branches later, so you can select the + default ``main`` branch. + + b. After the codespace is created, you will be taken to a new browser + tab where you can use the terminal to activate a pre-defined conda + environment called ``mpl-dev``:: + + conda activate mpl-dev - conda activate mpl-dev 4. Install the local version of Matplotlib with:: python -m pip install -e . - (See :ref:`installing_for_devs` for detailed instructions.) + See :ref:`installing_for_devs` for detailed instructions. 5. Create a branch to hold your changes:: @@ -289,30 +294,29 @@ Finally, go to the web page of your fork of the Matplotlib repo, and click For more detailed instructions on how to set up Matplotlib for development and best practices for contribution, see :ref:`installing_for_devs`. -.. admonition:: GitHub Codespaces workflows - - * If you need to open a GUI window with Matplotlib output on Codespaces, our - configuration includes a `light-weight Fluxbox-based desktop - `_. - You can use it by connecting to this desktop via your web browser. To do - this: - - 1. Press ``F1`` or ``Ctrl/Cmd+Shift+P`` and select - ``Ports: Focus on Ports View`` in the VSCode session to bring it into - focus. Open the ports view in your tool, select the ``noVNC`` port, and - click the Globe icon. - 2. In the browser that appears, click the Connect button and enter the desktop - password (``vscode`` by default). - - Check the `GitHub instructions - `_ - for more details on connecting to the desktop. - - * If you also built the documentation pages, you can view them using - Codespaces. Use the "Extensions" icon in the activity bar to install the - "Live Server" extension. Locate the ``doc/build/html`` folder in the - Explorer, right click the file you want to open and select "Open with Live - Server." +GitHub Codespaces workflows +~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +* If you need to open a GUI window with Matplotlib output on Codespaces, our + configuration includes a `light-weight Fluxbox-based desktop + `_. + You can use it by connecting to this desktop via your web browser. To do this: + + 1. Press ``F1`` or ``Ctrl/Cmd+Shift+P`` and select + ``Ports: Focus on Ports View`` in the VSCode session to bring it into + focus. Open the ports view in your tool, select the ``noVNC`` port, and + click the Globe icon. + 2. In the browser that appears, click the Connect button and enter the desktop + password (``vscode`` by default). + + Check the `GitHub instructions + `_ + for more details on connecting to the desktop. + +* If you also built the documentation pages, you can view them using Codespaces. + Use the "Extensions" icon in the activity bar to install the "Live Server" + extension. Locate the ``doc/build/html`` folder in the Explorer, right click + the file you want to open and select "Open with Live Server." .. _contributing_documentation: From 34c7e524fa2b8862ecb4e47b72cb68f439dfdfda Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Melissa=20Weber=20Mendon=C3=A7a?= Date: Mon, 14 Aug 2023 18:22:28 -0300 Subject: [PATCH 6/6] Add bullet points to codespaces instructions --- doc/devel/contribute.rst | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/doc/devel/contribute.rst b/doc/devel/contribute.rst index 4e03e0b2c811..994d5448b876 100644 --- a/doc/devel/contribute.rst +++ b/doc/devel/contribute.rst @@ -250,17 +250,17 @@ A brief overview of the workflow is as follows. 3. Check out the Matplotlib repository and activate your development environment: - a. Open codespaces on your fork by clicking on the green "Code" - button on the GitHub web interface and selecting the "Codespaces" - tab. Next, click on "Open codespaces on ". You - will be able to change branches later, so you can select the - default ``main`` branch. + * Open codespaces on your fork by clicking on the green "Code" button + on the GitHub web interface and selecting the "Codespaces" tab. + * Next, click on "Open codespaces on ". You will be + able to change branches later, so you can select the default + ``main`` branch. + * After the codespace is created, you will be taken to a new browser + tab where you can use the terminal to activate a pre-defined conda + environment called ``mpl-dev``:: - b. After the codespace is created, you will be taken to a new browser - tab where you can use the terminal to activate a pre-defined conda - environment called ``mpl-dev``:: + conda activate mpl-dev - conda activate mpl-dev 4. Install the local version of Matplotlib with:: pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy