Skip to content
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

Update 03-create.md - Case sensitivity #1393

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 15 additions & 0 deletions episodes/03-create.md
Original file line number Diff line number Diff line change
Expand Up @@ -148,6 +148,21 @@ expected and can even result in data loss.
If you need to refer to names of files or directories that have spaces
or other special characters, you should surround the name in quotes (`""`).

::::::::::::::::::::::::::::::::::::::::::::::::::

::::::::::::::::::::::::::::::::::::::::: callout

## Case Sensitivity
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
## Case Sensitivity
## Case sensitivity

Section headers don't use full title case in our style guide.


This is normally driven by the underlying OS. In most implementations of BASH it is case sensitive, with the exception of MacOS which is case insensitive. Some OSs have predefined directories that use a capital letter at the start, such as Download, and Desktop. This is used to make these directors stand out.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
This is normally driven by the underlying OS. In most implementations of BASH it is case sensitive, with the exception of MacOS which is case insensitive. Some OSs have predefined directories that use a capital letter at the start, such as Download, and Desktop. This is used to make these directors stand out.
Whether or not your Bash shell is case-sensitive is normally determined by the underlying operating system (Windows, MacOS, Linux, etc.). In most implementations of Bash, it _is_ case sensitive. On MacOS, however, it is not case sensitive.


It is standard practice to use lowercase for your files and directories, but this is only a guideline.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
It is standard practice to use lowercase for your files and directories, but this is only a guideline.
It can be a good practice to use all lowercase for files and directories, but this is not a rule; you are likely to see uppercase used in practice.


If you choose to use capital letters at the start of your file names, you should bear in mind the fact that sorting order in Unix is (sometimes) case sensitive, and some commands such as grep you may need additional options to achieve the desired result.

Also this effect is negligible if the letter isn't the first letter in the name, so it's not an issue if you use naming standards such as camelCase.


Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
If you choose to use capital letters at the start of your file names, you should bear in mind the fact that sorting order in Unix is (sometimes) case sensitive, and some commands such as grep you may need additional options to achieve the desired result.
Also this effect is negligible if the letter isn't the first letter in the name, so it's not an issue if you use naming standards such as camelCase.

Some of this is rolled into my previous suggestion and the camelCase bit is probably too much for this early in the lesson.

::::::::::::::::::::::::::::::::::::::::::::::::::

### Create a text file
Expand Down