From 23c37e9b812a8682776b0b63f500bd6b13aeba84 Mon Sep 17 00:00:00 2001 From: Dave Kerr Date: Thu, 20 Jan 2022 14:19:33 +0800 Subject: [PATCH] fix: fixup relative paths for docusaurus and slugs --- README.md | 8 +++++--- .../01-getting-started/index.md | 4 ++-- .../02-navigating-your-system/index.md | 2 +- .../03-managing-your-files/index.md | 10 +++++----- .../04-clipboard-gymnastics/index.md | 4 ++-- .../05-getting-help/index.md | 4 ++-- .../docs/01-transitioning-to-the-shell/index.md | 2 +- .../the-renaissance-of-the-shell/index.md | 4 ++-- 8 files changed, 20 insertions(+), 18 deletions(-) diff --git a/README.md b/README.md index 9d587821..b74b24de 100644 --- a/README.md +++ b/README.md @@ -141,9 +141,10 @@ This is a short-and-sweet task list for the refactoring process. - [x] Merge index and introduction pages - [x] Getting Started Page - [x] Part 1 -- [ ] Build -- [ ] Deploy -- [ ] Test deployment +- [x] Build +- [x] Deploy +- [x] Test deployment +- [ ] Fix relref links - [ ] Ensure that google analytics integration is working. - [ ] Part 2 - [ ] Part 3 @@ -155,6 +156,7 @@ This is a short-and-sweet task list for the refactoring process. - [ ] Build - [ ] Deploy - [ ] Test deployment +- [ ] Remap google analytics routes (i.e. remove `/docs/` ## Thanks! diff --git a/effective-shell/docs/01-transitioning-to-the-shell/01-getting-started/index.md b/effective-shell/docs/01-transitioning-to-the-shell/01-getting-started/index.md index 4f746b29..e0efac64 100644 --- a/effective-shell/docs/01-transitioning-to-the-shell/01-getting-started/index.md +++ b/effective-shell/docs/01-transitioning-to-the-shell/01-getting-started/index.md @@ -1,7 +1,7 @@ --- title: 'Getting Started' -slug: 'getting-started' id: '01-getting-started' +slug: '/part-1-transitioning-to-the-shell/getting-started/' --- This section is for those who are completely new to this topic. In this section we'll introduce just what the shell is, who this book is useful for, and what you can expect to learn. @@ -490,4 +490,4 @@ We also briefly introduced _variables_, which are special values which start wit With these tasks complete we can now move onto the next section. -[^1]: On Windows you might need to run `start .` and on Linux, `xdg-open .`. \ No newline at end of file +[^1]: On Windows you might need to run `start .` and on Linux, `xdg-open .`. diff --git a/effective-shell/docs/01-transitioning-to-the-shell/02-navigating-your-system/index.md b/effective-shell/docs/01-transitioning-to-the-shell/02-navigating-your-system/index.md index 608d5769..45340378 100644 --- a/effective-shell/docs/01-transitioning-to-the-shell/02-navigating-your-system/index.md +++ b/effective-shell/docs/01-transitioning-to-the-shell/02-navigating-your-system/index.md @@ -1,7 +1,7 @@ --- title: 'Navigating Your System' -slug: 'navigating-your-system' id: '02-navigating-your-system' +slug: '/part-1-transitioning-to-the-shell/navigating-your-system/' --- Switching from a graphical user interface to the shell can take some getting used to. First we'll take a look at how to navigate your system using the shell, and get information on files and folders in the system. diff --git a/effective-shell/docs/01-transitioning-to-the-shell/03-managing-your-files/index.md b/effective-shell/docs/01-transitioning-to-the-shell/03-managing-your-files/index.md index cb53b272..bdfb1dde 100644 --- a/effective-shell/docs/01-transitioning-to-the-shell/03-managing-your-files/index.md +++ b/effective-shell/docs/01-transitioning-to-the-shell/03-managing-your-files/index.md @@ -1,7 +1,7 @@ --- title: 'Managing Your Files' -slug: 'managing-your-files' id: '03-managing-your-files' +slug: '/part-1-transitioning-to-the-shell/managing-your-files/' --- Downloading, unzipping, copying, moving, renaming and deleting files in a graphical user interface is normally fairly intuitive. Now we'll learn how to perform the same operations in a shell. Once you can organise your files, you are well on your way to being able to use the shell more effectively for day to day tasks. @@ -20,9 +20,9 @@ To help with this, I've created a zipped up 'samples' which has a lot of files i We *could* open up a web browser, download the file, unzip it and then start from there, but this book is all about how to deal with every day tasks in your shell, so let's skip the browser and do it in the shell instead! -Open your shell - if you've not yet got set up with your shell, that's OK, just check [Chapter 1 - Getting Started]({{< relref "/docs/getting-started" >}}). +Open your shell - if you've not yet got set up with your shell, that's OK, just check [Chapter 1 - Getting Started](../01-getting-started/index.md). -Now that you have your shell open, we can run the `wget` command (_Web Get_) to download the zip file. Let's download it to our Home folder. If you are not sure what the Home folder is, check [Chapter 2- Navigating Your System]({{< relref "/docs/part-1-transitioning-to-the-shell/navigating-your-system" >}}). +Now that you have your shell open, we can run the `wget` command (_Web Get_) to download the zip file. Let's download it to our Home folder. If you are not sure what the Home folder is, check [Chapter 2- Navigating Your System](../02-navigating-your-system/index.md). First, we'll move to our home directory, then download the file. @@ -167,7 +167,7 @@ We can see we've made a copy. ## Saving Some Keystrokes -Wow, it's painful putting `~/effective-shell-samples` before everything! From [Chapter 2- Navigating Your System]({{< relref "/docs/part-1-transitioning-to-the-shell/navigating-your-system" >}}) we already know how to change directory, so let's do that now: +Wow, it's painful putting `~/effective-shell-samples` before everything! From [Chapter 2- Navigating Your System](../02-navigating-your-system/index.md) we already know how to change directory, so let's do that now: ```sh cd ~/effective-shell-samples @@ -370,4 +370,4 @@ In this chapter we introduced the following: - When we delete files in the shell with `rm` or `rmdir` they are gone forever, no recycle bin! - The `cat` command (_concatenated_) can be used to write the contents of a file to the screen. - We can pass multiple files to commands like `cat` if we use wildcards, such as `quotes/*`. -- We can write the output to a file instead of the screen, if we use the `>` (_redirect to file_) operator. \ No newline at end of file +- We can write the output to a file instead of the screen, if we use the `>` (_redirect to file_) operator. diff --git a/effective-shell/docs/01-transitioning-to-the-shell/04-clipboard-gymnastics/index.md b/effective-shell/docs/01-transitioning-to-the-shell/04-clipboard-gymnastics/index.md index 8947980d..bb367929 100644 --- a/effective-shell/docs/01-transitioning-to-the-shell/04-clipboard-gymnastics/index.md +++ b/effective-shell/docs/01-transitioning-to-the-shell/04-clipboard-gymnastics/index.md @@ -1,7 +1,7 @@ --- title: 'Becoming a Clipboard Gymnast' -slug: 'become-a-clipboard-gymnast' id: '04-become-a-clipboard-gymnast' +slug: '/part-1-transitioning-to-the-shell/become-a-clipboard-gymnast/' --- For those who are new to the shell, we've covered a lot. In this chapter we'll slow down the pace of new commands a bit and instead focus on a core skill which you will already be familiar with from Graphical User Interfaces - using the clipboard. @@ -351,4 +351,4 @@ In this chapter we learnt: - We can sort lines of text with the `sort` command. - There is clearly a lot more we can do with text as we save hints of with the `uniq`, `tr` and `sed` commands - which we'll introduce in detail later. - You can treat the clipboard a bit like a file in the shell. -- On Linux, lots of things can be represented as files - including the clipboard (which is accessed via the `/dev/clipboard` file). \ No newline at end of file +- On Linux, lots of things can be represented as files - including the clipboard (which is accessed via the `/dev/clipboard` file). diff --git a/effective-shell/docs/01-transitioning-to-the-shell/05-getting-help/index.md b/effective-shell/docs/01-transitioning-to-the-shell/05-getting-help/index.md index 1c982b6b..709c3bdb 100644 --- a/effective-shell/docs/01-transitioning-to-the-shell/05-getting-help/index.md +++ b/effective-shell/docs/01-transitioning-to-the-shell/05-getting-help/index.md @@ -1,7 +1,7 @@ --- title: 'Getting Help' -slug: 'getting-help' id: '05-getting-help' +slug: '/part-1-transitioning-to-the-shell/getting-help/' --- In the earlier chapters I've introduced quite a few commands. Having to remember all of these commands and their parameters would be very hard. Fortunately there are built-in capabilities in the shell to help. @@ -478,4 +478,4 @@ In this chapter we looked at some of the ways we can get help. To quickly summar [^1]: Weirdly satisfying to run. [^2]: Which it is always fun to try if you get the chance, and a great way to learn more about the fundamentals of the operating system. -[^3]: Dash is a paid product. Full disclosure - I don't get any money from them or anyone else to write about anything, all content is 100% based on my experiences. I don't run ads on my site either. \ No newline at end of file +[^3]: Dash is a paid product. Full disclosure - I don't get any money from them or anyone else to write about anything, all content is 100% based on my experiences. I don't run ads on my site either. diff --git a/effective-shell/docs/01-transitioning-to-the-shell/index.md b/effective-shell/docs/01-transitioning-to-the-shell/index.md index 346533d6..0ceac955 100644 --- a/effective-shell/docs/01-transitioning-to-the-shell/index.md +++ b/effective-shell/docs/01-transitioning-to-the-shell/index.md @@ -1,6 +1,6 @@ --- title: "Part 1 - Transitioning to the Shell" -slug: "part-1-transitioning-to-the-shell" +slug: '/part-1-transitioning-to-the-shell/' --- These are the key skills which everyone should know. Without them, you might struggle to perform certain tasks at all. Experienced users can probably skip this section, or just review the summary. But if you are new to the shell, this is the best place to start! This section focuses on helping you quickly get up to speed with how to perform the same kind of tasks you might have performed in a GUI (Graphical User Interface) with the shell. diff --git a/effective-shell/docs/01-transitioning-to-the-shell/the-renaissance-of-the-shell/index.md b/effective-shell/docs/01-transitioning-to-the-shell/the-renaissance-of-the-shell/index.md index b2f27a5f..ffa84b82 100644 --- a/effective-shell/docs/01-transitioning-to-the-shell/the-renaissance-of-the-shell/index.md +++ b/effective-shell/docs/01-transitioning-to-the-shell/the-renaissance-of-the-shell/index.md @@ -1,7 +1,7 @@ --- title: 'The Renaissance of the Shell' -slug: 'the-renaissance-of-the-shell' id: '06-the-renaissance-of-the-shell' +slug: '/part-1-transitioning-to-the-shell/the-renaissance-of-the-shell/' --- This is the first of the "interludes" which end each section of the book. They don't teach any specific skills but instead give a little flavour and background about the world of the shell, Linux and modern computing. @@ -102,4 +102,4 @@ The rise in popularity of DevOps as a set of practices and beliefs has perhaps m And for these reasons and many more, learning how to use the shell effectively has never been more relevant or practical. -[^1]: https://insights.stackoverflow.com/survey/2020 \ No newline at end of file +[^1]: https://insights.stackoverflow.com/survey/2020