Questions tagged [cd]

cd is the "change directory" command offered by most shells. For CD-ROMs, please use the [cd-rom] tag.

673 questions
-1
votes
1 answer

How to cd into a folder using linux alias?

This alias searching a folder and printing out the location of the folder. findme 1234567 --> Searching and printing /xxx_data/xxe/TK/1234567/ --> This is the output of above alias. alias findme='program -x SR $1' --> This is…
-1
votes
1 answer

Error on runing a raw iso on virtualbox

I have download a raw iso cd from the internet. Try one: I'm import the iso on the vbox storage but when it boots i get "Fatal: no bootable device". Try two: Convert the iso to vmdk with VBoxManage , imported to vbox storage but the error still…
spiros_m
  • 11
  • 3
-1
votes
3 answers

How to cd into the first directory after sorting

I have a folder in which there are directories ABC_1 ABC_2 ABC_3 ABC_4 ABC_5 Test XYZ I want to sort them by date,remove the directories which do not contain ABC in their name and cd into the first directory. I tried cd $(/bin/ls -t1 | head -n…
Mohit Arora
  • 327
  • 5
  • 18
-1
votes
1 answer

I managed to get the command prompt to open, now how do I get it to write lines?

Basically, I want the command prompt to type and execute the command "cd/" by itself. Here's the code I used to open the command prompt: (Windows Form Application Visual c#) private void button6_Click(object sender, EventArgs e) { …
-1
votes
1 answer

basic shell - ls command after chdir()

I'm trying to create a basic shell, but I have a problem. The shell changes directory just fine, and outputs an error if the user inputs an invalid directory. The shell also has an internal command for "pwd" and prints out the new working directory…
-1
votes
1 answer

cd command in IPython vs. Spyder

I know that many of the working directory prompts that work in IPython also work in Spyder as long as they're prefaced by %. For example, pwd and ls work in IPython, but to run the same commands in Spyder they need to be prefaced with a % such as:…
Ryan Chase
  • 1,894
  • 3
  • 19
  • 29
-1
votes
1 answer

In ksh how do I iterate through a list of directories and cd to them using a loop?

Basically I have a flat file that is setup like so: /this/is/a/log/directory | 30 /this/also/is/having/logs | 45 /this/logs/also | 60 What I'm trying to do is extract the first column of this flat file which is the directory path and check if it has…
Indeciski
  • 23
  • 2
-1
votes
1 answer

Bash - Write a function that opens the closest directory with a certain name

I want to create a Bash function goto that takes 1 argument If the current directory contains a directory by the name of the argument, cd to it If any of the directories of the current directory contains it, cd there etc... if all paths stemming…
Cyoce
  • 252
  • 2
  • 14
-1
votes
2 answers

Changing the current directory in Java to implement "cd" command in linux

I'm trying to build a command line interpreter that implements "cd" command in linux. I don't know how the function that suppose to do that shoud work. I know that this question has already been answered here: Changing the current working directory…
dili
  • 31
  • 8
-1
votes
1 answer

How to open a file without typing its entire name?

I want to be more comfortable with CLI, so I need practice. :D I have a directory and within it I have more of them. I use ls to find their name, but the one I want to change into has a very long name. Is it possible to change to that directory…
Bacchus
  • 473
  • 8
  • 17
-1
votes
1 answer

How to execute command by python?

I want to give a directory from raw_input of user and have cd to that directory by python I used that code but it doesn't work for me: a=raw_input("Enter The Dir :") import os os.system("cd "+a) but it doesn't change the current directory of the…
-1
votes
1 answer

Does Arch Linux save configuration data?

I'm setting up the OS via VirtualBox but I have yet to install Grub so I can't boot off the hardrive. If I restart my computer and boot my Arch Linux cd will everything I've done be saved.
user3081791
  • 11
  • 1
  • 1
  • 2
-1
votes
3 answers

Issues with `cd` after `alias`

I read this command somewhere on Twitter and executed it in my Terminal and it seems it removed the cd package completely from the OS. alias cd="say -v cello" What does this command do? Can you breakup the explanation of this command? How do I…
Govil
  • 1,976
  • 18
  • 20
-1
votes
1 answer

Change to xth directory terminal

Is there a way in a unix shell (specifically Ubuntu) to change directory into the xth directory that was printed from the ls command? I know you can sort a directory in multiple ways, but using the output from ls to get the xth directory? An example…
Benjamin Kaiser
  • 1,927
  • 21
  • 23
-2
votes
1 answer

bash script cd command affecting tee command

I've a script to perform git operations. Parse the file for the repo, source and new branch Clone the repo check if the new branch already exists. skip this repo if it does create new branch: cd into the folder git branch new_branch git checkout…
RockyK
  • 1
  • 1
1 2 3
44
45