Skip to content

Commit

Permalink
More changes
Browse files Browse the repository at this point in the history
  • Loading branch information
taldcroft committed Jun 13, 2024
1 parent 4563ee4 commit e4ade26
Show file tree
Hide file tree
Showing 4 changed files with 21 additions and 31 deletions.
3 changes: 1 addition & 2 deletions docs/development/git_edit_workflow_examples.rst
Original file line number Diff line number Diff line change
Expand Up @@ -43,8 +43,7 @@ Set up an isolated workspace

git switch -b fix-1761 upstream/main

+ Switch to your astropy development environment, assuming you are using the ``conda``
package manager (for other options see :ref:`virtual_envs`)::
+ Switch to your astropy development environment::

conda activate astropy-dev

Expand Down
19 changes: 8 additions & 11 deletions docs/development/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -12,19 +12,18 @@ guidelines.
For newcomers the process may initially seem overwhelming, but with a little patience
and practice you will see that it is not so complex. The key is to follow the steps
outlined here and `ask for help <https://www.astropy.org/help.html>`_ if you get stuck.
The astropy community is welcoming and friendly and will help you!
The Astropy community is welcoming and friendly and will help you!

This is divided into two sections, first a quickstart guide that provides an
introduction to the development workflow, followed by a more detailed guide that covers
all aspects of contributing to Astropy and provides a reference for both developers and
maintainers.
introduction to the development workflow, followed by a number of detailed guides that
cover provide a deeper dive and a reference for both developers and maintainers.

.. Important:: There are useful ways to contribute to Astropy without diving
into the developer workflow which is described here. For an
an overview see the `Contribute to Astropy <https://www.astropy.org/contribute.html>`_
page.

Parts of this content have been adapted from the excellent
Parts of this content have been adapted from the
`pandas developer documentation <https://pandas.pydata.org/pandas-docs/stable/development/index.html>`_.
Astropy is grateful to the pandas team for their documentation efforts.

Expand All @@ -43,7 +42,7 @@ list. These issues are the most accessible ones if you are not familiar with the
source code.

.. toctree::
:maxdepth: 3
:maxdepth: 2

quickstart

Expand All @@ -53,9 +52,9 @@ example with a simple bug fix. This includes more explanation of the steps and g
advice for making a code change.

.. toctree::
:maxdepth: 2
:maxdepth: 1

workflow/git_edit_workflow_examples
git_edit_workflow_examples

Details
-------
Expand All @@ -64,14 +63,12 @@ Details
:maxdepth: 2

development_details
virtual_pythons
codeguide
docguide
style-guide
testguide
workflow/git_resources
git_resources
scripts
building
ccython

Maintaining astropy and affiliated packages
Expand Down
24 changes: 9 additions & 15 deletions docs/development/quickstart.rst
Original file line number Diff line number Diff line change
Expand Up @@ -58,8 +58,7 @@ https://devguide.python.org/setup/#macos.

**Linux**

For Linux-based :ref:`conda <contributing.conda>` installations, you won't have to
install any additional components.
For Linux-based installations, you won't have to install any additional components.

. _contributing.forking:

Expand Down Expand Up @@ -93,15 +92,18 @@ isolated from both your system Python and any other Python environments you may
for doing other work. This is important because the development environment will often
be unstable and possibly broken at times, and you don't want to break your other work.

There are *many* good options (see :ref:`virtual_envs` for discussion), but in this
quickstart guide we use the `conda <https://docs.conda.io/en/latest/>`_ package
There are many good options, including a number of virtual environment managers
starting with the Python built-in `venv <https://docs.python.org/3/library/venv.html>`_
module. Users who have a preference for a particular virtual environment manager are
encouraged to use it! However, maintaining instructions for all of them here would be
impractical.

For this quickstart guide we use the `conda <https://docs.conda.io/en/latest/>`_ package
manager provided by `miniforge <https://github.com/conda-forge/miniforge>`_. This is a
popular choice and generally works well, especially for newcomers. It is easy to install
and use on all platforms and it makes it easy to install different Python versions which
can be useful for testing.

.. _contributing.conda:

Install miniforge and conda
~~~~~~~~~~~~~~~~~~~~~~~~~~~

Expand All @@ -110,9 +112,7 @@ If you do not already have ``conda`` installed, `download and install miniforge
your system but the end result is to provide a ``conda`` executable that you can use
to create and manage isolated Python environments.

Now create and activate an ``astropy-dev`` conda environment using the following:

.. code-block:: shell
Now create and activate an ``astropy-dev`` conda environment using the following::

conda create -n astropy-dev python graphviz
conda activate astropy-dev
Expand Down Expand Up @@ -201,12 +201,6 @@ provides a quick tutorial using a test repository that may help you become more
with forking a repository, cloning a fork, creating a feature branch, pushing changes
and making pull requests.

Below are some useful resources for learning more about forking and pull requests on GitHub:

* `GitHub documentation for forking a repo <https://docs.github.com/en/get-started/quickstart/fork-a-repo>`_.
* `GitHub documentation for collaborating with pull requests <https://docs.github.com/en/pull-requests/collaborating-with-pull-requests>`_.
* `GitHub documentation for working with forks <https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/working-with-forks>`_.

Creating a feature branch
-------------------------

Expand Down
6 changes: 3 additions & 3 deletions docs/development/scripts.rst
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
****************************
Writing Command-Line Scripts
****************************
********************
Command-Line Scripts
********************

Command-line scripts in Astropy should follow a consistent scheme to promote
readability and compatibility.
Expand Down

0 comments on commit e4ade26

Please sign in to comment.