Mac tip: Apply the path to the terminal via drag and drop – my pick from KW11

Mac Terminal Tips & Tricks

Every now and then, as a Mac user, you have to go into the terminal and type in a command. I often find it difficult because I have to enter paths that sometimes contain spaces and other special characters that puzzle me when I enter them. I'll admit I'm not exactly a great light when it comes to using the terminal, but sometimes just knowing a few good tricks is enough.

Today there is again an interesting tip for the terminal on the Mac.
Today there is another interesting tip for the terminal on the Mac.

Auto-complete with the tab key

The first tip I want to share here is the Tab key. If you enter the first part of a file or folder name and press TAB, the name is completed. If there are several possibilities, for example because there are several files that start with the characters you have already entered, nothing will be completed.

In this case you can press TAB twice and then you will get the Port a list of the various possibilities that would come into question.

Drag and drop a file or folder into the terminal

But here's the real tip: If you want to switch to a specific folder in the terminal, you can use a Finderwindow, click the folder with the mouse and then drag it into the terminal window. In my case, the command “cd /path/to/folder” then appeared in the terminal. So all I had to do was press return and I ended up in the appropriate folder. There I could then enter the remaining commands that affected a specific file.

You can change the path in the terminal using drag and drop.
You can change the path in the terminal using drag and drop.

Terminal trick: Turn off Mac by timer

Speaking of the terminal: Enter the following command in the terminal:

sudo shutdown -h +30

This helps so that you don't sit at the computer forever and also get some fresh air, because with this command you tell the Mac to shut down after 30 minutes (+30) (-h). But before you lose important work: I'm not sure how to stop the timer. 😊

For me, these little “hacks” are very helpful when dealing with the terminal. If you also have a nice trick for the terminal, please leave it here as a comment.

Did you like the article and did the instructions on the blog help you? Then I would be happy if you the blog via a Steady Membership would support.

1 comment on "Mac tip: Take the path into the terminal via drag and drop - my pick of the KW11"

  1. brother mosses of lobdenberg

    How to cancel shutdown? Well, by aborting the process. GuxDu man shutdown:

    A scheduled shutdown can be canceled by killing the shutdown process (a SIGTERM should suffice).

Post a comment

Your e-mail address will not be published. Required fields are marked with * marked

In the Sir Apfelot Blog you will find advice, instructions and reviews on Apple products such as the iPhone, iPad, Apple Watch, AirPods, iMac, Mac Pro, Mac Mini and Mac Studio.