Questions tagged [macos]

macOS (previously "Mac OS X" and "OS X") is the Unix developed and distributed by Apple Inc. since 2001.

833 questions
96
votes
4 answers

How do I install htop in mac OS X?

How do I install htop for macOS (OS X)? (The easiest and laziest path)
Ruvenss
  • 1,061
  • 1
  • 7
  • 8
50
votes
3 answers

How can I set the default editor as nano on my Mac?

I have vim as default editor on my Mac and every time I run commands on Mac terminal, it automatically opens "vim". How can I set up "nano" instead and make sure the terminal will open "nano" every time is needed?
g_tech
  • 603
  • 1
  • 5
  • 4
47
votes
4 answers

ssh connection "client_loop: send disconnect: Broken pipe" or "Connection reset by port 22"

I have been using ssh to access remote servers for many months, but recently I haven't been able to establish a reliable connection. Sometimes I cannot login and get the message "Connection reset by port 22", when I can login I get the error…
Ashka Shah
  • 571
  • 1
  • 4
  • 4
39
votes
2 answers

Why does awk -F work for most letters, but not for the letter "t"?

July 2022 mac os Monterey V12.1 awk --version 20200816 GNU bash, version 3.2.57(1)-release (x86_64-apple-darwin21) Why does awk -F work for most letters, but NOT for the letter t? I have the solution, but I would like to understand why…
Ian Christy
  • 503
  • 3
  • 8
35
votes
7 answers

Why do I lose my ZSH history?

Every once in a while I discover my zsh history has been truncated (or maybe lost entirely, difficult to tell), and I have to restore it from backup. For example, today: ls -lh ~/.zsh_history -rw------- 1 stripe staff 32K 21 Feb 10:20…
34
votes
6 answers

How to install docker-engine in macOS without docker desktop?

Recently Docker announced that Docker Desktop would cease to be free for some kinds of users. See announcement in blog post. I don't need any of the features that are exclusive to Docker Desktop®. I have used docker in a laptop with debian on it and…
santiago arizti
  • 551
  • 1
  • 5
  • 6
34
votes
4 answers

GZip doesn't produce the same compressed result on macOS vs Linux

I have a few thousand files that are individually GZip compressed (passing of course the -n flag so the output is deterministic). They then go into a Git repository. I just discovered that for 3 of these files, Gzip doesn't produce the same output…
Pol
  • 442
  • 4
  • 6
32
votes
9 answers

How to move directory into a directory with the same name?

I have a directory foo with several files: . └── foo ├── a.txt └── b.txt and I want to move it into a directory with the same name: . └── foo └── foo ├── a.txt └── b.txt I'm currently creating a temporary directory bar,…
Stefan
  • 431
  • 1
  • 4
  • 8
24
votes
3 answers

How can I print well formatted code (hardcopy printout)

Similar to using markdown on Stack Overflow to create monospace output, how can I do that for my programs. I tried lp filename.txt and was pleasantly please to find that it was able to use the local network printer and print 'as is' The problem is…
Michael Durrant
  • 41,213
  • 69
  • 165
  • 232
22
votes
2 answers

What is this weird directory in my PATH on my Mac, (running latest macOS Ventura)?

I found that my PATH on my MacBook Pro running Mac OS Ventura 13.0.1 has a strange directory inside all of the normal ones, i.e. /opt/homebrew/bin:/usr/local/bin:XXX:/usr/bin:/bin:/usr/sbin:/sbin: /System/Cryptexes/App/usr/bin is inserted into my…
l3v1tat3
  • 223
  • 1
  • 1
  • 4
20
votes
2 answers

Does Windows recognize Linux's symbolic links?

I was just wondering how a Windows system handles symbolic links (when created via Linux's ln -s on a filesystem that Windows natively supports and that supports symbolic links, such as NTFS). My best guess is that it will not recognize them, but…
JamesTheAwesomeDude
  • 825
  • 3
  • 14
  • 28
20
votes
4 answers

How to fix "VirtualBox VM quit unexpectedly" when running my Ubuntu 20.04 LTS VM on MacOS Catalina 10.15 in VirtualBox?

I am running VirtualBox 6.1 on Catalina 10.15.6 and when I start my Ubuntu 20.04 LTS VM it says "VirtualBox VM quit unexpectedly". How can I fix this? The Apple report is below Path: …
Jaid AM
  • 201
  • 1
  • 2
  • 3
17
votes
1 answer

Why did {} start appearing as äå in Terminal.app?

I'm running CentOS 7.9 and today my terminal is showing weird characters. Some letters look fine, but some symbols appear as some non-English characters. For example I made a text file with the following contents: !@#$%^&*()_+{} When I open this…
Elliott B
  • 533
  • 1
  • 4
  • 18
15
votes
1 answer

The 01:00 in 1 January 1970 at 01:00

I will not ask why a timestamp is 1 January 1970 at 00:00 but in several cases in my computer they are 1 January 1970 at 01:00, how did the 01:00 coincidentally get set with a number of apps?
Niklas Rosencrantz
  • 4,112
  • 6
  • 36
  • 58
14
votes
2 answers

Why does 'ls' only display contents when I'm in a certain directory?

I am facing a very confusing behaviour of ls that I cannot search for. It displays that there are contents in a directory, but only when I'm in the directory where these were created from. Let me show you: ciprian Documents $…
1
2 3
55 56