docs : setting_up : allow anonymous downloads
The current doc structure requires the creation of a Linux Foundation account, which is not really a valid open source usage model. In fact, it isn't even required to download anything as anonymous git clone works. Content on creating a Linux Foundation ID will be moved to the collaboration section in another commit. Change-Id: I50253d7b3da85b64986d62f2e5bee25da3eb3987 Signed-off-by: Dan Kalowsky <daniel.kalowsky@intel.com>
This commit is contained in:
parent
017394c2a6
commit
40781ac1d0
1 changed files with 7 additions and 122 deletions
|
@ -5,138 +5,23 @@ Setting Up for Zephyr Development
|
|||
|
||||
Setting up your development environment for Zephyr is done in two steps:
|
||||
|
||||
1. Access the code
|
||||
1. Downloading the code
|
||||
2. Set up the development environment
|
||||
|
||||
Access the Code
|
||||
***************
|
||||
Download the Code
|
||||
*****************
|
||||
|
||||
The code is hosted at the Linux Foundation and code review is done using
|
||||
Gerrit. Therefore, a Linux Foundation account is needed to contribute to the
|
||||
code. Follow these steps to create an account if you don't have one already:
|
||||
|
||||
#. Go to the `Linux Foundation ID website`_.
|
||||
|
||||
#. Select the option :guilabel:`I need to create a Linux Foundation ID`.
|
||||
|
||||
.. figure:: figures/setting_up01.png
|
||||
:scale: 75 %
|
||||
:alt: linuxfoundation.org identity page
|
||||
|
||||
#. Fill out the form that appears:
|
||||
|
||||
.. figure:: figures/setting_up02.png
|
||||
:scale: 75 %
|
||||
:alt: New account form
|
||||
|
||||
#. Open your email account and look for a message with the subject line:
|
||||
"Validate your Linux Foundation ID email".
|
||||
|
||||
#. Open the received URL to validate your email address.
|
||||
|
||||
#. Verify the browser displays the message :guilabel:`You have successfully
|
||||
validated your e-mail address`.
|
||||
|
||||
#. Access `Gerrit`_ by selecting :guilabel:`Sign In`:
|
||||
|
||||
.. figure:: figures/setting_up03.png
|
||||
:scale: 75 %
|
||||
:alt: Gerrit without being signed in
|
||||
|
||||
#. Use your Linux Foundation ID to Sign In:
|
||||
|
||||
.. figure:: figures/setting_up04.png
|
||||
:scale: 75 %
|
||||
:alt: Gerrit sign in screen
|
||||
|
||||
Configuring Gerrit to Use SSH
|
||||
=============================
|
||||
|
||||
Gerrit uses SSH to interact with your Git client. A SSH private key
|
||||
needs to be generated on the development machine with a matching public
|
||||
key on the Gerrit server.
|
||||
|
||||
If you already have a SSH key-pair, skip this section.
|
||||
|
||||
As an example, we provide the steps to generate the SSH key-pair on a Linux
|
||||
environment. Follow the equivalent steps on your OS.
|
||||
|
||||
#. Create a key-pair, enter:
|
||||
|
||||
.. code-block:: console
|
||||
|
||||
$ ssh-keygen -t rsa -C "John Doe john.doe@example.com"
|
||||
|
||||
.. note::
|
||||
This will ask you for a password to protect the private key as it
|
||||
generates a unique key. Please keep this password private, and DO NOT
|
||||
enter a blank password.
|
||||
|
||||
The generated key-pair is found in:
|
||||
:file:`~/.ssh/id_rsa` and :file:`~/.ssh/id_rsa.pub`.
|
||||
|
||||
#. Add the private key in the :file:`id_rsa` file in your key ring:
|
||||
|
||||
.. code-block:: console
|
||||
|
||||
$ ssh-add ~/.ssh/id_rsa
|
||||
|
||||
Once the key-pair has been generated, the public key must be added to Gerrit.
|
||||
|
||||
Follow these steps to add your public key :file:`id_rsa.pub` to the Gerrit
|
||||
account:
|
||||
|
||||
1. Go to `Gerrit`_.
|
||||
|
||||
2. Click on your account name in the upper right corner.
|
||||
|
||||
3. From the pop-up menu, select :guilabel:`Settings`.
|
||||
|
||||
4. On the left side menu, click on :guilabel:`SSH Public Keys`.
|
||||
|
||||
5. Paste the contents of your public key :file:`~/.id/id_rsa.pub` and click
|
||||
:guilabel:`Add key`.
|
||||
|
||||
.. note::
|
||||
The :file:`id_rsa.pub` file can be opened using any text editor. Ensure
|
||||
that all the contents of the file are selected, copied and pasted into the
|
||||
:guilabel:`Add SSH key` window in Gerrit.
|
||||
|
||||
.. warning::
|
||||
Potential Security Risk! Do not copy your private key
|
||||
:file:`~/.ssh/id_rsa` Use only the public :file:`~/.id/id_rsa.pub`.
|
||||
|
||||
Gerrit Commit Message Hook
|
||||
==========================
|
||||
|
||||
.. include:: ../collaboration/code/gerrit_practices.rst
|
||||
:start-line: 42
|
||||
:end-line: 49
|
||||
|
||||
.. _code_check_out:
|
||||
The code is hosted at the Linux Foundation with a Gerrit backend that supports
|
||||
anonymous cloning via GIT.
|
||||
|
||||
Checking Out the Source Code
|
||||
============================
|
||||
|
||||
#. Ensure that SSH has been set up properly. See
|
||||
`Configuring Gerrit to Use SSH`_ for details.
|
||||
|
||||
#. Clone the repository:
|
||||
|
||||
a. Use your Linux Foundation ID:
|
||||
.. code-block:: console
|
||||
|
||||
.. code-block:: console
|
||||
|
||||
$ git clone
|
||||
ssh://LFID@gerrit.zephyrproject.org:29418/zephyr zephyr-project
|
||||
|
||||
.. note:: LFID should be replaced with your Linux Foundation ID.
|
||||
|
||||
b. Alternatively you can clone anonymously:
|
||||
|
||||
.. code-block:: console
|
||||
|
||||
$ git clone https://gerrit.zephyrproject.org/zephyr zephyr-project
|
||||
$ git clone https://gerrit.zephyrproject.org/r/zephyr zephyr-project
|
||||
|
||||
You have successfully checked out a copy of the source code to your local
|
||||
machine.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue