Stack Exchange Network

Stack Exchange network consists of 174 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [path]

The concept that software will look in several folders, in the order stored as the path, to find which programs should be allowed to run.

1
vote
2answers
59 views

Problem with displaying file path in Finder's Get Info -> Where

I occasionally need to check some file's location and copy it to the clipboard. I used to use Finder -> Cmd-I then I used to copy the content of "Where" section. Ever since updating to macOs Mojave, ...
1
vote
1answer
13 views

Create an hardlink across storage device (or alternative solutions)

I have named my secondary SSD with a name with a space in it - "My SSD", and have been using it for many years with multimedia applications without any problem. Part of my media library with thousands ...
0
votes
3answers
76 views

Running `nano` uses the old nano(2.0.6) even though nano 3.0 is installed

I installed nano 3.0 with brew install nano, but when I run nano --version, it shows version 2.0.6, which is what came with macOS. Screenshot: echo $PATH also shows that /usr/local/bin is listed ...
3
votes
2answers
76 views

Difference between filename and . filename in macOS terminal

I'm newbie to MacOS. (I'm using mac OS high sierra 10.13.6) I installed a software. They said to initialize the software by . /path/setsas.sh I give no thought to . and space, so I just ran path/...
0
votes
0answers
54 views

How to change to the default $PATH in mac OS, and uninstall anything that changed my path?

I have been tinkering with things like git, mono, x11, python, and homebrew on mac. I am a noob and have no idea what I actually installed on my mac and how it changed my system. This concerns me from ...
0
votes
0answers
38 views

Removing directories from PATH

I am trying to run rkhunter, but it is giving me this output: stack/security/rkhunter-1.4.6 ➜ sudo rkhunter --check Password: Invalid BINDIR configuration option: Invalid directory found: ~/.dotnet/...
2
votes
3answers
114 views

Automator: Service to list File Paths of selected items, into Text File

How can this Automator Service for Finder be created? I'd like to be able to use Finder's Context menu (by right-clicking a Finder item) to run a Service that gets the file paths of the selected ...
4
votes
2answers
209 views

How to get an application executable path from Terminal

In macOS, applications can be launched from the command line with open -a < application name>. I would like to know if there is a command that returns the executable within the application ...
1
vote
2answers
80 views

Adding a new directory to PATH varibale

What is the de-facto way to export a binary/executable to my global PATH? I have seen different answers to this, but I am looking for the best answer. Basically, if I go on Github and download a ...
3
votes
2answers
72 views

Path Variable Limit

Is there a character limit on how long your PATH variable can be on macOS? Or is there a limit in terms of the amount of binaries you can reference in your path?
2
votes
1answer
971 views

Cannot run refind-install from Recovery because “/usr/bin/env: bad interpreter”

I have managed to change the present working directory to the folder containing downloaded rEFInd files. I have booted to Recovery Mode. The refind-bin-0.11.3 folder was downloaded to my Downloads ...
4
votes
1answer
206 views

Add Environment Variable to PATH

I am new to the Apple "eco system" and I am trying to setup my environment variables for local development. Here is what I have in my ~/.bash_profile (simplified for brevity): export PATH="$...
2
votes
1answer
84 views

How can I determine which paths are required?

I am using Mac OS X Snow Leopard 10.6.8. My Mac has several volumes with OS X and each volume has several users. I wish to minimise the work required to ensure that my paths are adequate both for ...
2
votes
1answer
53 views

mdfind -onlyin wildcard without pipe

Can -onlyin contain wildcards? mdfind pattern -onlyin '*bin' I know this works: mdfind pattern | grep bin
2
votes
1answer
61 views

Copy full path of an open file

I have a file open in Preview.app. I can easily view the full path for the same by ⌘ + clicking on the file proxy icon (the icon shown besides the filename in Preview's title bar). How do I copy ...
0
votes
3answers
52 views

Software uninstalled from brew still on $PATH

I've uninstalled software from brew (as I want to use a different version), using MacOS High Sierra 10.13.1 brew uninstall bowtie2 And downloaded the software from SourceForge instead, then copied ...
2
votes
1answer
47 views

Restore path to be read from /private/etc/paths

I used the how to from https://docs.aws.amazon.com/cli/latest/userguide/cli-install-macos.html to install AWS CLI on macOS. After executing command source ~/.bash_profile it seems that my default ...
2
votes
1answer
78 views

Path bar High Sierra doesn't work with search results on SMB fileserver

Yosemite High Sierra Hi there! At our Prepress department I’ve updated some iMacs from Yosemite to High Sierra. When I search in Yosemite on the SMB fileserver for a specific file, I see after a ...
3
votes
1answer
210 views

When I type 'echo $path' in Terminal, I see only a blank line - why?

I know I have a $path variable. If I type 'env' or 'set' at the Terminal command line, I can see what's in the $path variable - along with lots of other extraneous stuff. But if I just type 'echo $...
2
votes
0answers
55 views

path difference on script vs in shell

Why is the output of $PATH different when in a script vs when running $PATH from the terminal? Even for a minimal script like this: #!/bin/bash echo $PATH it will not match what I get when typing in ...
1
vote
1answer
145 views

Deleting a line from Bash profile

So using terminal I typed in: nano .bash_profile I then have access to the following bash_profile : GNU nano 2.0.6 File: .bash_profile ...
2
votes
1answer
118 views

Force terminal to use binary from a different path

I have installed pandoc using homebrew and the Anaconda python distribution using pyenv. I've just found that Anaconda comes with its own pandoc binary and since the pyenv shims come before homebrew ...
0
votes
1answer
2k views

Changed my PATH to have /usr/local/bin ahead of /usr/bin and now pip isn't found

I was following this guide to get Python 3 setup, which recommended changing the PATH variable such that "# If you still see 2.7 ensure in PATH /usr/local/bin/ takes pecedence over /usr/bin/". I put ...
2
votes
1answer
411 views

Not a valid identifier upon terminal startup

I am getting this line each time I open my terminal. Everything else seems to be working ok but I would like to get this fixed since I don't think it is a good sign. Last login: Mon Feb 19 09:21:05 ...
2
votes
1answer
136 views

How to revert launchctl PATH to defaults?

There are many questions and commentary about using launchctl setenv PATH /path/to/include in order to have GUI apps inherit user-specified paths. I did this about four years ago, and the changes I ...
0
votes
0answers
23 views

Customize path name for easier use cd [duplicate]

I am currently working on a project which involves working on files in two different directories, both with very long path names. I want to make some kind of "terminal shortcut" (apologies for not ...
2
votes
2answers
451 views

How can one use /etc/paths.d to add a path with spaces in it to $PATH?

I recently installed VMware Fusion 10 on a Mac running macOS 10.12.6. After doing so, my bash PATH is broken. I traced the problem to a /etc/paths.d path file that Fusion installed; it contains the ...
2
votes
1answer
407 views

Missing /usr/local/sbin directory in the /etc/paths file

Why doesn’t the /etc/paths file include the /usr/local/sbin directory on macOS? $ cat /etc/paths /usr/local/bin /usr/bin /bin /usr/sbin /sbin I would have expected: $ cat /etc/paths /usr/local/bin /...
1
vote
0answers
437 views

Terminal OS X export command not working, cannot set new variable/pathway

I'm trying to set a variable, e.g. BIN=../../../../bin but I get BIN=../../../../bin: Command not found. The same for export BIN export: Command not found. It seems that I can't edit the path ...
4
votes
1answer
320 views

Convert a PC path to Mac path with AppleScript

I am a lone Mac user in a company that uses PCs...I often get file paths that I need to manually navigate. I have found some scripts, but they don't seem to be working for me. I'd like to be able to ...
7
votes
4answers
227 views

Get/Copy current Excel file's path

When in Windows 10 or in Windows 7, if I have an Excel file open and I want to know the path to the file I can use the ‘open current file in explorer’ button and it opens that file in the Windows ...
1
vote
1answer
91 views

Accidentally deleted /etc/paths

I had recently messed up my $PATH variable so I thought if fixing it by removing the /etc/paths but I found out online solutions to fix the $PATH variable by just editing the ~/.bash_profile so I ...
1
vote
1answer
518 views

Homebrew (unlike Macports) does not put programs ahead of system's

Macports inserts /opt/local/bin/ ahead of /usr/bin in the path, and so if the same program exists in both folders, the Macports-installed one takes precedence. I'm unclear on how Homebrew manages ...
1
vote
0answers
322 views

how to set node path in at /usr/local/bin using nvm

I have installed node using nvm first time and now when I run which node in terminal it gives me /Users/username/.nvm/versions/node/v6.11.4/bin/node but what I need that node path must be at /usr/...
1
vote
0answers
45 views

How to set the Screenshot directory with Jamf?

I'm using Jamf to configure my companies MacBooks and just recently got the request from Management, that every screenshot taken should be placed in a special Directory. For now, the only thing I ...
2
votes
0answers
41 views

Where do I find what's all affecting my $PATH?

When I echo $PATH I get: /Library/Frameworks/Python.framework/Versions/3.5/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/Users/arukaj/Library/Android/sdk/platform-tools/:/Applications/XAMPP/...
0
votes
0answers
64 views

What prevents using .bashrc to initialize Terminal?

A few months ago, I made it easier to run scripts I'd written by creating a .bashrc file. It worked for a while, but it has not worked in a few weeks. As the Terminal snippet below shows, the file ...
1
vote
3answers
90 views

Use incomplete file path in terminal

In terminal is there a way for Terminal to guess a file based on an incomplete file path? For example: Instead of /Users/me/foo1/foo2/foo3/foo4/TargetFile, is there a way to just do /foo3/foo4/...
3
votes
1answer
71 views

Correct Sierra 10.12.5 file paths to Spotlight and SpotlightNetHelper files to be blocked with Little Snitch?

The article belowmentions using LittleSnitch for blocking Spotlight and SpotlightNetHelper: Spotlight makes repeated http requests It includes two screenshots. The first image shows two separate ...
0
votes
1answer
632 views

How to export to $PATH permanently because .bashrc file doesn't exist in $HOME directory

I am trying to figure out macOS and want to install Composer which was not a problem....but I need the Laravel and Symfony installer and in the documentation it says that I need to export the variable ...
3
votes
1answer
81 views

Copy pathname from Finder with tilde (~/) instead of absolute home directory

Since OS X El Capitan, right-clicking on a file in Finder while pressing "Option" shows a menu function Copy "File.txt" as Pathname. I wonder if I can replace the absolute path of the home directory ...
3
votes
2answers
3k views

Locate long file paths on external drive with terminal

I need to move a large volume to a new raid server that's PC formatted. However I have a couple paths and filenames that are interrupting this process. I would just like to know how to use the ...
1
vote
1answer
1k views

My terminal path in macOS SIerra is messed up

Few months ago, I was trying to download pygame on mac. It was very difficult but I finally did it through terminal using bash. But after the download, I think there was some change on default path ...
2
votes
2answers
659 views

Terminal problem: “-bash: $: command not found”

I'm trying to start learning Swift and when I use the terminal line $ export PATH=/Library/Developer/Toolchains/swift-latest.xctoolchain/usr/bin:"${PATH}" it gives me -bash: $: command not found ...
2
votes
0answers
2k views

Xcode 8 and iOS 11 incompatibility despite having copied device support files

I have set up up a new computer (MacBook Pro) from a backup I made yesterday from my old computer (MacBook Air). In the process of that setup, I changed my user's home folder name, strictly following ...
0
votes
2answers
81 views

Command path for exit

How would I find the command path for exit? I have already tried which exit but that returns nothing (it just goes to a new line). I have also played around cd /usr/bin, and when in that directory ...
1
vote
0answers
25 views

Including server names in file paths

We have two servers, ServerOne and ServerTwo. Each server contains a folder called Projects. On Windows, the paths to each of these folders are \\ServerOne\Projects and \\ServerTwo\Projects, ...
1
vote
1answer
30 views

can i find usb path and save to variable for quick backups?

i would like to add the path to inserted flash drive named backup1 to a variable so i can copy /Documents/dir to this flash drive path in one script without user interaction
0
votes
2answers
2k views

ERROR: AUCTeX cannot find a working TeX distribution (macOS Sierra)

I have installed MacTex and GNU Emacs on my iMac. I have created a simple tex file (the one suggested here) and tried to run LaTeX on it by hitting C-c C-c, but the following message appeared: ...
4
votes
2answers
265 views

Python path added to $PATH — cannot find origin

I just installed Python 3.6 from python.org on macOS Sierra. Somehow, the path to python's bin is added to my every $PATH but I can't figure out how: 22:15 : echo $PATH ...