I have a ChromeOS and I installed Miniconda3 on it. It is installed in the Linux folder under sub-folder /opt
When I try to enter the command "/opt" - it shows
bash: /opt: Is a directory
But when I try to command "/opt/miniconda3" - it shows
bash: opt/miniconda3: No such file or directory
Can anyone explain why is this the case?
Use /opt/miniconda3, you miss the leading slash and shell search for opt/miniconda3 related to your current directory
Related
I'm using Ubuntu 20.4.05 LTS. It is not locating any directory as you can see in the image. For example, cd ~/Downloads doesn't take me to the directory.No such file or directory image What should I do?
as a first step you must know the position of the directory by writing the command pwd
pwd
then you can write the ls command to see the contents of the list of folders or directories
ls
if the file you need is in that directory, you can enter that file by writing the command cd
cd
access folder
I am using ubuntu 16.04 and created a virtual environment called 'tensorflow1' as shown above. I am using putty to access a machine remotely. So I was trying to change directory by typing "cd /tensorflow1/models/research" but it says "-bash: cd: /tensorflow1: No such file or directory" in ubuntu, but the file is there. I typed "ls" and it also shows the file. Why is it so?
When you type ls you see the content of the current directory. When you type cd /tensorflow1 you're trying to enter a directory tensorflow1 at the root (/) of the filesystem and the directory is certainly not there. You just need
cd tensorflow1/models/research
to enter a subdirectory of the current directory. Or
cd ./tensorflow1/models/research
because . means "the current directory".
You probably want cd ./tensorflow1/models/research or just cd tensorflow1/models/research.
Read about root directory, home directory, working directory then about path_resolution(7)
When I start bash, the following description appears:
-bash: /usr/share/virtualenvwrapper/virtualenvwrapper_lazy.sh: No such file or directory
-bash: /usr/share/virtualenvwrapper/virtualenvwrapper_lazy.sh: No such file or directory
i'm using Microsoft-Windows-Subsystem-Linux, with ubuntu distro.
I already tried uninstalling by powershell pip uninstall virtualenvwrapper or in bash sudo pip uninstall virtualenvwrapper.
I also entered the share directory to delete the virtualenvwrapper folder, but it does not appear. I'm pressing LS and the folder does not appear.
I am also trying "which virtualenvwrapper" or "which virtualenvwrapper_lazy.sh" but this simply returns the same folder as I am.
i just need help to remove that message of bash
Most likely, there is a reference (potentially with source or .) to virtualenvwrapper_lazy.sh in one of bash startup files. Look at the usual suspects: ~/.bashrc, ~/.profile, /etc/profile, /etc/bash.bash.rc, /etc/.bash_login
To help with debugging, consider getting by adding set -x to ~/.bashrc, or by running interactive session
bash -ix /dev/null
UPDATE, based on log:
Per https://superuser.com/questions/893448/bash-shell-error-no-such-file-or-directory/1049989
I just had the same problem on Linux Mint.
The following file was causing the issue:
/etc/bash_completion.d/virtualenvwrapper
I made a backup (just in case) and deleted it, and everything seems to
be working fine now.
I'm working in Windows 10 with a fresh installation of Anaconda and Git Bash. I decided to set cmd.exe as my default console program to use git bash (instead of the minTTY), and I think already I am getting issues with Unix style characters vs Windows.
When I fire up cmd Bash tells me it can't find my conda.sh file:
bash: C:UsersjoshuAnaconda3/etc/profile.d/conda.sh: No such file or directory
First, it looks like bash is missing the default windows slashes for my root directory ("C:/Users/joshu/"). Does anyone know how to fix this?
Thanks
I have the exact same problem. Run ~/.bashrc in a terminal. Go to the path given and correct the conda.sh path.
In your case, you will replace the C:\Users\joshu\Anaconda3/etc/profile.d/conda.sh to C:/Users/joshu/Anaconda3/etc/profile.d/conda.sh
Your only problem is that your slashes are set wrong.
Fix this issue by opening ~/.bashrc and change location of conda.sh, e.g. in my case
. D:/Users/my_user/ProgramFile/Continuum/anaconda3/etc/profile.d/conda.sh
Had the same problem on Windows 10/Git Bash/Anaconda installation. If you run ~/.bashrc in Git Bash, it should give you the location of the shell script file containing the incorrect path. Once you correct the path in that file, the message should disappear when you restart the terminal.
Another thing to check is make sure your user profile folder under C:\Users has not gone hidden. If it has gone hidden, then the C:\Anaconda\etc\profile.d\conda.sh script
won't be able to find the folder.
I'm doing some Android development and want to access the command line tools from anywhere.
There wasn't an existing .bash_profile file in my home directory so I created one and added the following line:
export PATH="/Users/Me/desktop/Android/Android SDK bundle/sdk/platform-tools"
I can now access the Android tools from terminal, however the ls command has stopped working, though cd still works. I get
-bash: ls: command not found
What should I do to get it to work again (and why has ls stopped working but cd still works?).
Try:
export PATH=$PATH:"/Users/Me/desktop/Android/Android SDK bundle/sdk/platform-tools"
It will append to the current PATH your sdk directory.
As for the later question, it stopped working because you overwritten your PATH variable, so bash can't find your binaries. However cdis a builtin command (http://linux.about.com/library/cmd/blcmdl1_builtin.htm) it doesn't need a path to be located and executed.