From 6db52496bd533b9567a3be068814442647d74a24 Mon Sep 17 00:00:00 2001 From: Richard Regan Date: Tue, 16 May 2023 16:29:10 +0100 Subject: [PATCH 1/2] Update 03-create.md - Case sensitivity Added a Call out section on case sensitivity. --- episodes/03-create.md | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/episodes/03-create.md b/episodes/03-create.md index ac0eb0864..dcd26fa8a 100644 --- a/episodes/03-create.md +++ b/episodes/03-create.md @@ -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 + +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. + +It is standard practice to use lowercase for your files and directories, but this is only a guideline. + +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. + + :::::::::::::::::::::::::::::::::::::::::::::::::: ### Create a text file From c35da47730813ca1c37e550dee7651d01e776f96 Mon Sep 17 00:00:00 2001 From: Richard Regan Date: Wed, 17 May 2023 09:14:38 +0100 Subject: [PATCH 2/2] Update 03-create.md Added short section on case sensitivity to the Good names section. --- episodes/03-create.md | 13 ++----------- 1 file changed, 2 insertions(+), 11 deletions(-) diff --git a/episodes/03-create.md b/episodes/03-create.md index dcd26fa8a..1c90c035a 100644 --- a/episodes/03-create.md +++ b/episodes/03-create.md @@ -148,19 +148,10 @@ 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 - -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. - -It is standard practice to use lowercase for your files and directories, but this is only a guideline. +Whether or not your Bash shell is case-sensitive is normally determined by the underlying operating system. In most implementations of Bash it is case sensitive. On MacOS, however, it is not case sensitive. -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. +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. 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. -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. ::::::::::::::::::::::::::::::::::::::::::::::::::