Skip to content

Commit 3fe3500

Browse files
committedSep 9, 2020
[docs] Add First Pull Request guide and Getting Started guide.
This improves upon the existing documentation to provide a clearer end-to-end workflow for new contributors and people who wish to build the toolchain locally but do not intend to submit patches. We also provide more directions for systematically utilizing our existing documentation.

7 files changed

+915
-253
lines changed
 

‎Brewfile

+1
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,3 @@
11
brew "cmake"
22
brew "ninja"
3+
brew "sccache"

‎README.md

+17-253
Original file line numberDiff line numberDiff line change
@@ -50,14 +50,9 @@ To learn more about the programming language, visit [swift.org](https://swift.or
5050

5151
- [Contributing to Swift](#contributing-to-swift)
5252
- [Getting Started](#getting-started)
53-
- [System Requirements](#system-requirements)
54-
- [Getting Sources for Swift and Related Projects](#getting-sources-for-swift-and-related-projects)
55-
- [Building Swift](#building-swift)
5653
- [Swift Toolchains](#swift-toolchains)
5754
- [Build Failures](#build-failures)
58-
- [Testing Swift](#testing-swift)
5955
- [Learning More](#learning-more)
60-
- [Build Dependencies](#build-dependencies)
6156

6257
## Contributing to Swift
6358

@@ -77,206 +72,15 @@ well. For more, see the [Code of Conduct](https://swift.org/community/#code-of-c
7772

7873
## Getting Started
7974

80-
These instructions give the most direct path to a working Swift development
81-
environment. To build from source you will need about 2 GB of disk space for the
82-
source code and up to 70 GB of disk space for the build artifacts with full
83-
debugging. Depending on your machine, a clean build can take a few minutes to
84-
several hours. Naturally, incremental builds are much faster.
75+
If you are interested in:
76+
- Contributing fixes and features to the compiler: See our
77+
[How to Submit Your First Pull Request guide](/docs/HowToGuides/FirstPullRequest.md).
78+
- Building the compiler as a one-off: See our [Getting Started guide][].
79+
- Building a toolchain as a one-off: Follow the [Getting Started guide][]
80+
up until the "Building the project" section. After that, follow the
81+
instructions in the [Swift Toolchains](#swift-toolchains) section below.
8582

86-
Once you are able to build things successfully and have a compile-test-debug
87-
loop going, check out the [development tips](docs/DevelopmentTips.md) for
88-
better productivity while working on the compiler.
89-
90-
You can also skim [docs/README.md](/docs/README.md) to understand what
91-
high-level documentation is available.
92-
93-
### System Requirements
94-
95-
macOS, Ubuntu Linux LTS, and the latest Ubuntu Linux release are currently
96-
supported as host development operating systems.
97-
98-
Please make sure you use Python 2.x. Python 3.x is not supported currently.
99-
100-
#### macOS
101-
102-
To build for macOS, you need [Xcode 12 beta 3](https://developer.apple.com/xcode/resources/).
103-
The required version of Xcode changes frequently, and is often a beta release.
104-
Check this document or the host information on <https://ci.swift.org> for the
105-
current required version.
106-
107-
Swift's build tooling is meant to support spaces in the paths passed to them,
108-
but using spaces sometimes tickles bugs in Swift's build scripts or the tools
109-
they rely on. For example, [SR-13441](https://bugs.swift.org/browse/SR-13441)
110-
is caused by a space in the Xcode path used on macOS. If you see Swift's build
111-
tooling misbehave due to a space in a path, please
112-
[report the bug on the Swift bug tracker](https://swift.org/contributing/#reporting-bugs)
113-
and then change the path to work around it.
114-
115-
You will also need [CMake](https://cmake.org) and [Ninja](https://ninja-build.org),
116-
which can be installed via a package manager:
117-
118-
**[Homebrew](https://brew.sh/)**
119-
120-
brew install cmake ninja
121-
122-
You can also use [homebrew-bundle](https://github.com/Homebrew/homebrew-bundle)
123-
from the root of this repository's working directory to install all of these
124-
dependencies:
125-
126-
brew bundle
127-
128-
**[MacPorts](https://macports.org)**
129-
130-
sudo port install cmake ninja
131-
132-
Instructions for installing CMake and Ninja directly can be found [below](#build-dependencies).
133-
134-
#### Linux
135-
136-
For Ubuntu, you'll need the following development dependencies:
137-
138-
```
139-
sudo apt-get install \
140-
clang \
141-
cmake \
142-
git \
143-
icu-devtools \
144-
libcurl4-openssl-dev \
145-
libedit-dev \
146-
libicu-dev \
147-
libncurses5-dev \
148-
libpython-dev \
149-
libsqlite3-dev \
150-
libxml2-dev \
151-
ninja-build \
152-
pkg-config \
153-
python \
154-
python-six \
155-
rsync \
156-
swig \
157-
systemtap-sdt-dev \
158-
tzdata \
159-
uuid-dev
160-
```
161-
162-
**Note:** LLDB currently requires at least `swig-1.3.40` but will successfully build
163-
with version 2 shipped with Ubuntu.
164-
165-
**Note:** For Ubuntu 20.04, use `libpython2-dev` in place of the libpython-dev package above.
166-
167-
### Getting Sources for Swift and Related Projects
168-
169-
First create a directory for all of the Swift sources:
170-
171-
mkdir swift-source
172-
cd swift-source
173-
174-
**Note:** This is important since update-checkout (see below) checks out
175-
repositories next to the Swift source directory. This means that if one clones
176-
Swift and has other unrelated repositories, update-checkout may not clone those
177-
repositories and will update them instead. Be aware that `update-checkout`
178-
currently does not support paths with non-ASCII characters. If such characters
179-
are present in the path to `swift-source`, `update-checkout` will fail.
180-
181-
**Via HTTPS** For those checking out sources as read-only, HTTPS works best:
182-
183-
git clone https://github.com/apple/swift.git
184-
./swift/utils/update-checkout --clone
185-
186-
**Via SSH** For those who plan on regularly making direct commits,
187-
cloning over SSH may provide a better experience (which requires
188-
[uploading SSH keys to GitHub](https://help.github.com/articles/adding-a-new-ssh-key-to-your-github-account/)):
189-
190-
git clone git@github.com:apple/swift.git
191-
./swift/utils/update-checkout --clone-with-ssh
192-
193-
### Building Swift
194-
195-
The `build-script` is a high-level build automation script that supports basic
196-
options such as building a Swift-compatible LLDB, building the Swift Package
197-
Manager, building for various platforms, running tests after builds, and more.
198-
199-
There are two primary build systems to use: Xcode and Ninja. The Xcode build
200-
system allows you to work in Xcode, but Ninja is a bit faster and supports
201-
more environments.
202-
203-
First, make sure that you're in the swift directory:
204-
205-
cd swift
206-
207-
To build using Ninja, run:
208-
209-
utils/build-script --release-debuginfo
210-
211-
When developing Swift, it helps to build what you're working on in a debug
212-
configuration while building the rest of the project with optimizations. Below
213-
are some examples of using debug variants:
214-
215-
utils/build-script --release-debuginfo --debug-swift # Swift frontend built in debug
216-
utils/build-script --release-debuginfo --debug-swift-stdlib # Standard library built in debug
217-
utils/build-script --release-debuginfo --debug-swift --force-optimized-typechecker # Swift frontend sans type checker built in debug
218-
219-
Limiting the amount of debug code in the compiler has a very large impact on
220-
Swift compile times, and in turn the test execution time. If you want to build
221-
the entire project in debug, you can run:
222-
223-
utils/build-script --debug
224-
225-
For documentation of all available arguments, as well as additional usage
226-
information, see the inline help:
227-
228-
utils/build-script -h
229-
230-
#### Xcode
231-
232-
To build using Xcode, specify the `--xcode` argument on any of the above commands.
233-
Xcode can be used to edit the Swift source code, but it is not currently
234-
fully supported as a build environment for SDKs other than macOS. The generated
235-
Xcode project does not integrate with the test runner, but the tests can be run
236-
with the 'check-swift' target.
237-
238-
#### Build Products
239-
240-
All of the build products are placed in `swift-source/build/${TOOL}-${MODE}/${PRODUCT}-${PLATFORM}/`.
241-
If macOS Swift with Ninja in DebugAssert mode was built, all of the products
242-
would be in `swift-source/build/Ninja-DebugAssert/swift-macosx-x86_64/`. It
243-
helps to save this directory as an environment variable for future use.
244-
245-
export SWIFT_BUILD_DIR="~/swift-source/build/Ninja-DebugAssert/swift-macosx-x86_64"
246-
247-
#### Ninja
248-
249-
Once the first build has completed, Ninja can perform fast incremental builds of
250-
various products. These incremental builds are a big timesaver when developing
251-
and debugging.
252-
253-
cd ${SWIFT_BUILD_DIR}
254-
ninja swift-frontend
255-
256-
This will build the Swift compiler, but will not rebuild the standard library or
257-
any other target. Building the `swift-stdlib` target as an additional layer of
258-
testing from time to time is also a good idea. To build just the standard
259-
library, run:
260-
261-
ninja swift-stdlib
262-
263-
It is always a good idea to do a full build after using `update-checkout`.
264-
265-
#### Using Xcode
266-
267-
To open the Swift project in Xcode, open `${SWIFT_BUILD_DIR}/Swift.xcodeproj`.
268-
It will auto-create a *lot* of schemes for all of the available targets. A
269-
common debug flow would involve:
270-
271-
- Select the 'swift-frontend' scheme.
272-
- Pull up the scheme editor (⌘⇧<).
273-
- Select the 'Arguments' tab and click the '+'.
274-
- Add the command line options.
275-
- Close the scheme editor.
276-
- Build and run.
277-
278-
Another option is to change the scheme to "Wait for executable to be launched",
279-
then run the build product in Terminal.
83+
[Getting Started guide]: /docs/HowToGuides/GettingStarted.md
28084

28185
### Swift Toolchains
28286

@@ -335,26 +139,24 @@ compiler crashes.
335139

336140
### Build Failures
337141

338-
Make sure you are using the [correct release](#macos) of Xcode.
142+
Try the suggestions in
143+
[Troubleshooting build issues](/docs/HowToGuides/GettingStarted.md#troubleshooting-build-issues).
144+
145+
Make sure you are using the
146+
[correct release](/docs/HowToGuides/GettingStared.md#installing-dependencies)
147+
of Xcode.
339148

340149
If you have changed Xcode versions but still encounter errors that appear to
341150
be related to the Xcode version, try passing `--clean` to `build-script`.
342151

343152
When a new version of Xcode is released, you can update your build without
344153
recompiling the entire project by passing the `--reconfigure` option.
345154

346-
Make sure all repositories are up to date with the `update-checkout` command
347-
described above.
348-
349-
## Testing Swift
350-
351-
See [docs/Testing.md](docs/Testing.md), in particular the section on [lit.py](docs/Testing.md#using-litpy).
352-
353155
## Learning More
354156

355-
Be sure to look through the [docs](https://github.com/apple/swift/tree/master/docs)
356-
directory for more information about the compiler. In particular, the documents
357-
titled [Debugging the Swift Compiler](docs/DebuggingTheCompiler.md) and
157+
Be sure to look at the [documentation index](/docs/README.md) for a bird's eye
158+
view of the available documentation. In particular, the documents titled
159+
[Debugging the Swift Compiler](docs/DebuggingTheCompiler.md) and
358160
[Continuous Integration for Swift](docs/ContinuousIntegration.md) are very
359161
helpful to understand before submitting your first PR.
360162

@@ -378,41 +180,3 @@ Another source of documentation is the standard library itself, located in
378180
`stdlib`. Much of the language is actually implemented in the library
379181
(including `Int`), and the standard library gives some examples of what can be
380182
expressed today.
381-
382-
## Build Dependencies
383-
384-
### CMake
385-
[CMake](https://cmake.org) is the core infrastructure used to configure builds of
386-
Swift and its companion projects; at least version 3.16.5 is required.
387-
388-
On macOS, you can download the [CMake Binary Distribution](https://cmake.org/download),
389-
bundled as an application, copy it to `/Applications`, and add the embedded
390-
command line tools to your `PATH`:
391-
392-
export PATH=/Applications/CMake.app/Contents/bin:$PATH
393-
394-
On Linux, if you have not already installed Swift's [development
395-
dependencies](#linux), you can download and install the CMake
396-
package separately using the following command:
397-
398-
sudo apt-get install cmake
399-
400-
401-
### Ninja
402-
[Ninja](https://ninja-build.org) is the current recommended build system
403-
for building Swift and is the default configuration generated by CMake. [Pre-built
404-
packages](https://github.com/ninja-build/ninja/wiki/Pre-built-Ninja-packages)
405-
are available for macOS and Linux distributions. You can also clone Ninja
406-
next to the other projects and it will be bootstrapped automatically:
407-
408-
**Via HTTPS**
409-
410-
git clone https://github.com/ninja-build/ninja.git && cd ninja
411-
git checkout release
412-
cat README
413-
414-
**Via SSH**
415-
416-
git clone git@github.com:ninja-build/ninja.git && cd ninja
417-
git checkout release
418-
cat README

‎docs/GitHubCreatePRScreenshot.png

61.7 KB
Loading

‎docs/HowToGuides/FAQ.md

+101
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,101 @@
1+
# Frequently Asked Questions
2+
3+
## Build System and CMake Configuration
4+
5+
### How do I add a new file to CMake?
6+
7+
If you forget to add a new file to the CMake configuration, you may end up with
8+
undefined symbol errors at link time.
9+
10+
There should be a `CMakeLists.txt` in the directory where you added the new
11+
file, which has the list of different .h/.cpp files to be included in the build.
12+
Add your new file to that list.
13+
14+
### How do I speed up iterating on changes to the build system?
15+
16+
The general idea is to build as little as you can.
17+
- [Use `sccache`](/docs/HowToGuides/GettingStarted.md) or `ccache` if you
18+
aren't doing so already.
19+
- Use `build-script`'s various `--skip-*` flags to skip configuring for
20+
platforms that you do not care about.
21+
- If you're on macOS, use `--swift-darwin-supported-archs="x86_64"`.
22+
- Use a release build without assertions (`--release --no-assertions`).
23+
While debuginfo and assertions are valuable to enable when working on the
24+
toolchain itself, they are not so useful if you are working only on changes
25+
to the build system.
26+
27+
## Using a Locally Built Toolchain
28+
29+
### How do I use a locally built compiler to build X?
30+
31+
You can use the `SWIFT_EXEC` environment variable to use a locally
32+
built compiler to compile both packages and Xcode projects.
33+
34+
1. For SwiftPM packages, pass the environment variable when invoking SwiftPM.
35+
```sh
36+
# Assuming the current working directory contains the package, build the
37+
# package using a custom compiler.
38+
SWIFT_EXEC=/path/to/swiftc swift build
39+
```
40+
2. For Xcode projects, select the project in the Project Navigator. In the
41+
Build Settings tab, click '+' and then 'Add User-Defined Setting'.
42+
Create a build setting `SWIFT_EXEC` with the value set to `/path/to/swiftc`.
43+
If you now do a clean build, your locally built compiler will be used.
44+
45+
At the time of writing, in the latest Xcode 12 beta, `SWIFT_EXEC` does not
46+
work for SwiftPM integration inside Xcode, so this will not work for Xcode
47+
projects that depend on SwiftPM packages.
48+
49+
**Note:** Even thought the variable says 'SWIFT', it needs to point to
50+
'swift**c**', not 'swift'. The extra 'c' is not a typo.
51+
52+
## Testing and CI
53+
54+
### How do I reproduce/fix a test that fails in CI but passes for me locally?
55+
56+
TODO: Write some tips here, point to Testing.md for simulator setup.
57+
58+
## Documentation
59+
60+
### Where can I find documentation on X?
61+
62+
This very depends on what X is, but some broad guidelines are:
63+
64+
1. Do a case-insensitive recursive string search.
65+
- Use a specialized tool like [ripgrep](https://github.com/BurntSushi/ripgrep)
66+
or [ag](https://github.com/ggreer/the_silver_searcher).
67+
- Use 'Find in Workspace' in Xcode (<kbd>⌘</kbd>+<kbd>⇧</kbd>+<kbd>F</kbd>).
68+
- Use `grep -i -r "mypattern" .`.
69+
2. Go through the [Documentation Index](/docs/README.md).
70+
71+
## Pull Request Workflow
72+
73+
### How do I format my changes?
74+
75+
First, install `clang-format` using your system's package manager. This should
76+
also install the `git-clang-format` script (try `git-clang-format --help`).
77+
In case it doesn't, you can replace `git-clang-format` in the following
78+
commands with `../llvm-project/clang/tools/clang-format/git-clang-format`.
79+
80+
Start out at the tip of the branch where you want to reformat the commits.
81+
82+
```
83+
# If there is only one commit that needs to be reformatted.
84+
git-clang-format HEAD~1
85+
git add .
86+
git commit --amend --no-edit
87+
88+
# Say the last N commits need to be reformatted.
89+
# Mark them as 'edit' instead of 'pick'.
90+
git rebase -i HEAD~N
91+
# Re-run N times, reformatting each commit.
92+
git-clang-format HEAD~1
93+
git add .
94+
git commit --amend --no-edit
95+
git rebase --continue
96+
```
97+
98+
### How do I clean up my git history?
99+
100+
TODO: Link to a beginner-friendly external resource, or (less preferably)
101+
describe basic usage of rebase here.

‎docs/HowToGuides/FirstPullRequest.md

+179
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,179 @@
1+
# How to Submit Your First Pull Request
2+
3+
So you've decided to contribute to the Swift toolchain, welcome!
4+
Maybe this is your first time contributing to an open source project, or maybe
5+
you are an experienced open source contributor who is excited about Swift, or
6+
maybe you are somewhere in-between. Regardless of your background, we are
7+
excited to have you contribute and improve the developer experience for Swift
8+
programmers all over the globe.
9+
:sparkles::child::student::woman_technologist::technologist::man_technologist::sparkles:
10+
11+
This document provides a high-level overview of different parts of the
12+
contribution process.
13+
14+
## How do I pick something to work on?
15+
16+
In case you don't have something specific you'd like to work on, such as
17+
implementing something for a Swift Evolution pitch, you could start off by
18+
working on a bug labeled `StarterBug` on [Swift JIRA][StarterBug]. If the
19+
bug hasn't been assigned to someone, check the comments in case someone has
20+
already started working on it. If not, feel free to assign it to yourself and
21+
start working on it!
22+
23+
[StarterBug]: https://bugs.swift.org/issues/?jql=labels%20%3D%20StarterBug%20AND%20(status%20%3D%20Open%20OR%20status%20%3D%20Reopened)%20AND%20project%20%3D%20Swift
24+
25+
## Getting Help
26+
27+
Usually, Starter Bugs try to provide some instructions to help you get started.
28+
In case those are missing, please ask the bug reporter for more detailed steps
29+
and they will be happy to help.
30+
31+
Once you start working on the bug, you will inevitably end up having a lot of
32+
questions. Don't be afraid to ask for help! The codebase is large and wrapping
33+
your head around it will take time. For example, you might have questions like:
34+
35+
- Where can I find documentation on X?
36+
- I'm seeing a cryptic error E when trying to build the compiler. How do I fix
37+
it or work around it?
38+
- I'm seeing very long build times even for incremental builds. How do I speed
39+
up iteration time?
40+
- I'm not sure how to implement X. Any suggestions on where I should start?
41+
- What is the difference between types T1 and T2? They look very similar.
42+
- Should I split my new X into a separate file?
43+
- Should I create a new test file or update an existing test?
44+
- How should I test that I actually fixed this bug?
45+
- Test X is failing and I can't understand why. What might be going wrong here?
46+
- Test X is failing in CI but passing locally. Any tips for debugging?
47+
- I made some change but that seems to be not getting picked up. What should
48+
I do to fix it?
49+
- I need to update the CMake but I'm not familiar with CMake. Could you give me
50+
more guidance?
51+
- How do I do X in git?
52+
53+
Some of these already have answers in our [FAQ](/docs/HowToGuides/FAQ.md).
54+
Maybe you have a question that's not on this list. That's fine.
55+
We're here to help. There are a couple of options to ask for help:
56+
57+
- [Development category on the Swift forums](https://forums.swift.org/c/development):
58+
Prefer using the forums for broad questions, such as those related to
59+
building the toolchain, or understanding how something works at a high-level.
60+
Since more people are likely to see and be able to answer your question, the
61+
question is likely to get an answer sooner. Another benefit of asking in
62+
public is that the answers you receive will be helpful to bystanders too.
63+
- Bug report/Pull request comments: Prefer asking in the bug report/pull request
64+
when the question involves additional context specific to the
65+
bug report/pull request.
66+
67+
These are suggestions, not rules. For example, it's okay if you ask a broad
68+
question in a bug report or a pull request.
69+
70+
When asking for help, prefer giving as much information as possible, while
71+
highlighting the parts that you think are important.
72+
73+
Remember that the [Swift Code of Conduct][] applies whenever you are
74+
participating in the Swift project.
75+
76+
[Swift Code of Conduct]: https://swift.org/community/#code-of-conduct
77+
78+
### I didn't get a response from someone. What should I do?
79+
80+
It's possible that you ask someone a question in a bug report/pull request and
81+
you don't get a response as quickly as you'd like. Maybe they are juggling
82+
several tasks and the discussion with you accidentally slipped by. Maybe they
83+
are on vacation or on leave for some reason. If you don't get a response
84+
within a week, it's okay to politely ping them using an `@` mention with a
85+
reminder. If you don't get a response for 2-3 weeks in a row, please ping
86+
someone else.
87+
88+
## Working on a change
89+
90+
Please see our [Getting Started guide][] to understand how to build the code,
91+
make changes, run tests and debug issues.
92+
93+
[Getting Started guide]: /docs/HowToGuides/GettingStarted.md
94+
95+
## Submitting a pull request
96+
97+
### Tidying up
98+
99+
Alright! You've implemented a change and would like to submit it.
100+
Double-check that you've tidied your Git history, such as squashing
101+
work-in-progress commits, and that your commit messages provide context.
102+
For example, if a commit fixes a bug, then include a "Fixes SR-NNNNN" with the
103+
bug number in the commit message.
104+
105+
Next, [format your changes](/docs/HowToGuides/FAQ.md#how-do-i-format-my-changes)
106+
using `clang-format`.
107+
108+
### Pushing and creating a pull request
109+
110+
Assuming you followed the steps in our [Getting Started guide][], you should now
111+
be able to push your latest changes to GitHub using `git push`.
112+
113+
Next, [create a pull request][] (PR). Usually, if you navigate to
114+
https://github.com/apple/swift right after pushing your change, GitHub will
115+
show a helpful "Compare & Pull Request" button.
116+
117+
![Compare & Pull Request button in GitHub UI](/docs/GitHubCreatePRScreenshot.png)
118+
119+
[create a pull request]: https://docs.github.com/en/github/collaborating-with-issues-and-pull-requests/creating-a-pull-request#creating-the-pull-request
120+
121+
## Asking for code review
122+
123+
If you had an active discussion with someone on how to implement your change,
124+
you can `@` mention them in the PR description and ask for code review.
125+
If you directly implemented the change without any guidance from anyone else,
126+
`@` mention someone from GitHub's suggested reviewers. If GitHub doesn't
127+
make any suggestions, ask the [Code Owner](/CODE_OWNERS.txt) based on the
128+
component for your change. Please ask someone though! We don't want you to get
129+
stuck because you were not sure who to ask for code review.
130+
131+
At the beginning, contributors are not able to run the continuous integration
132+
(CI) bot, which builds the project and runs tests. Please ask your code
133+
reviewer(s) to invoke the bot for you.
134+
135+
## Responding to code review comments
136+
137+
During the process of code review, someone might suggest changes or have
138+
questions about the implementation. If something is unclear, such as someone
139+
using a technical term you don't recognize, check our
140+
[Lexicon](/docs/Lexicon.md) or ask someone instead of trying to figure out
141+
everything by yourself. Code review does not need to be a one-way
142+
street. It is also a good opportunity for you to ask highly contextual
143+
questions on topics that you struggled with or were unable to understand.
144+
145+
While making changes based on code review, if you are comfortable with
146+
rebasing, prefer rebasing and force-pushing for small patches (say < 100 lines).
147+
For larger patches, you can add fixup commits (`git commit --fixup ...`)
148+
addressing the suggestions and rebase after it the patch has been approved
149+
to clean up the history.
150+
151+
When you push again and want the tests to be re-run, please ask the reviewer
152+
to invoke `swift-ci` for you.
153+
154+
At the end, once the tests are passing, the pull request is approved by
155+
the reviewer, and you are satisfied with your changes, ask your reviewer
156+
to merge your changes. :tada:
157+
158+
## I can't finish the contribution I started. :frowning_face:
159+
160+
That's totally okay! There is no shame in that. You only have limited time and
161+
energy in a day. If you can, leave a comment on the bug report/pull request
162+
that you will not be able to continue and unassign yourself from the bug on
163+
JIRA. Don't worry about trying to explain _why_ you aren't able to contribute
164+
further. We understand. Unanticipated things come up all the time and you
165+
should do what _works for you_.
166+
167+
This point also applies if you don't have time right now but hope to get to
168+
something in the near future. Please don't feel sad or apologetic!
169+
170+
## I submitted and merged my first pull request. What now?
171+
172+
Awesome! You could try fixing a few more Starter Bugs until you feel some
173+
level of comfort working with the codebase. You could also start looking at
174+
other bugs which interest you and you think you might be able to tackle.
175+
Don't forget to ask for help if you need directions or you get stuck!
176+
177+
Once you've made multiple substantial contributions, you can
178+
[ask for commit access](https://swift.org/contributing/#commit-access),
179+
which will allow you to pick reviewers, trigger the CI bot and merge changes.

‎docs/HowToGuides/GettingStarted.md

+609
Large diffs are not rendered by default.

‎docs/README.md

+8
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,14 @@ documentation, please create a thread on the Swift forums under the
5555

5656
## How-To Guides
5757

58+
- [FAQ.md](/docs/HowToGuides/FAQ.md):
59+
Answers "How do I do X?" for a variety of common tasks.
60+
- [FirstPullRequest.md](/docs/HowToGuides/FirstPullRequest.md):
61+
Describes how to submit your first pull request. This is the place to start
62+
if you're new to the project!
63+
- [GettingStarted.md](/docs/HowToGuides/GettingStarted.md):
64+
Describes how to set up a working Swift development environment
65+
for Linux and macOS, and get an edit-build-test-debug loop going.
5866
- [DebuggingTheCompiler.md](/docs/DebuggingTheCompiler.md):
5967
Describes a variety of techniques for debugging.
6068
- Building for Android:

0 commit comments

Comments
 (0)
Please sign in to comment.