Skip to content

Improve README: Add a notice to cd into swift directory before building Swift #16227

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 6 commits into from
Nov 11, 2019

Conversation

agisilaos
Copy link
Contributor

Today, I tried to build Swift for the first time and I had an issue. I couldn't build it because I was getting an error: utils/build-script: No such file or directory

Then when I was talking with @harlanhaskins he said that I need to cd into the swift directory first.

I didn't know that and I couldn't see that in the documentation. Even though for many experienced swift contributors that's something they know, for a newbie that's not the case.

With this PR I added a first step/ notice to the README file so newbies and first-time contributors like myself can have all the info that they need in front of them when they try to build Swift.

Added another "step" before someone tries to build swift so I can make the process easier for newbies.
@agisilaos
Copy link
Contributor Author

@swift-ci please smoke test

@harlanhaskins
Copy link
Contributor

Hey Agis!

Thanks for adding this. Just for a heads up, CI privileges are not granted automatically, but only after you’ve shown a track record of good contributions. With that,

@swift-ci please smoke test

@harlanhaskins
Copy link
Contributor

Taking a closer look, it seems earlier in the directions, we cd swift-source before running ./swift/utils/update-checkout. Maybe instead of cd swift-source/swift this should just say cd swift?

@agisilaos
Copy link
Contributor Author

@harlanhaskins I thought of that as well, but when it comes to documentation I "prefer" things to be dead simple. That's why I kept it like: cd swift-source/swift. I guess that's a personal preference so if you strongly dissagree, I can follow the pattern than you wrote above.

One of the edge cases I thought was: What if someone closes the terminal window and needs to cd again in the swift directory, where the swift directory is gonna be found?

Let me know if that makes sense or if it's complete nonsense and if I only think of such edge cases. 😂

@harlanhaskins
Copy link
Contributor

Sorry for dropping this and picking it up just now. I'd like to think of the README as forming some sort of narrative, and we can assume that state changes like cd swift-source/ and cd swift/ are going to be stacked on top of each other. Otherwise, you can easily imagine someone trying to cd swift-source/swift-source/swift. These examples are kinda contrived, but I'd probably optimize for the single read through instead of the edge case you described.

@agisilaos
Copy link
Contributor Author

@harlanhaskins Ready for review. ⭐️ Thank you for the detailed comment!

@harlanhaskins
Copy link
Contributor

One last thing, before we merge, can you rebase your changes into one commit? We’d also prefer you not merge master back into your fork, and instead periodically rebase your fork onto master. It avoids the several merge commits. Once you do, I’ll run CI and merge!

@CodaFi
Copy link
Contributor

CodaFi commented Nov 11, 2019

Let's just take this and squash it down.

@swift-ci please smoke test

@CodaFi
Copy link
Contributor

CodaFi commented Nov 11, 2019

⛵️

@CodaFi CodaFi merged commit 93ce8a0 into swiftlang:master Nov 11, 2019
@agisilaos
Copy link
Contributor Author

agisilaos commented Nov 14, 2019

Thanks @CodaFi & @harlanhaskins. 🙌🏼

CodaFi added a commit to CodaFi/swift that referenced this pull request Nov 14, 2019
Another contributor had gone ahead and added the leading Swifts because
this wasn't here.  Just drop them again.

Supersedes swiftlang#25211
CodaFi added a commit that referenced this pull request Nov 14, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants