Creating repository in shell

PLEASE AM HAVING ISSUES WITH THIS QUESTION

Write a script that prints the absolute path name of the current working directory.

Example:

$ ./0-current_working_directory
/root/alx-system_engineering-devops/0x00-shell_basics
$

Repo:

  • GitHub repository: alx-system_engineering-devops
  • Directory: 0x00-shell_basics
  • File: 0-current_working_directory

root@67436ac34fab:/# cd
root@67436ac34fab:~# ls
0x01_emacs 0x02_vi alx-zero_day README.md school_is_amazing
0x02_emacs 0x03_vi new_school school tmp
root@67436ac34fab:~# mkdir alx-system_engineering-develops
root@67436ac34fab:~# cd alx-system_engineering-develops
root@67436ac34fab:~/alx-system_engineering-develops#
root@67436ac34fab:~/alx-system_engineering-develops# cd
root@67436ac34fab:~# rm alx-system_engineering-develpos
rm: cannot remove ‘alx-system_engineering-develpos’: No such file or directory
root@67436ac34fab:~# rmdir alx-system_engineering-develpos
rmdir: failed to remove ‘alx-system_engineering-develpos’: No such file or directory
root@67436ac34fab:~# ls
0x01_emacs 0x03_vi new_school school_is_amazing
0x02_emacs alx-system_engineering-develops README.md tmp
0x02_vi alx-zero_day school
root@67436ac34fab:~# rmdir alx-system_engineering-develpos
rmdir: failed to remove ‘alx-system_engineering-develpos’: No such file or directory
root@67436ac34fab:~# cd
root@67436ac34fab:~# mkdir 0x00-shell_basics
root@67436ac34fab:~# cd 0x00-shell_basics
root@67436ac34fab:~/0x00-shell_basics#
root@67436ac34fab:~/0x00-shell_basics# mk 0-current_working_directory
bash: mk: command not found
root@67436ac34fab:~/0x00-shell_basics# echo 0-current_working_directory
0-current_working_directory
root@67436ac34fab:~/0x00-shell_basics# ls
root@67436ac34fab:~/0x00-shell_basics# echo ‘i’ > 0-current_working_directory
root@67436ac34fab:~/0x00-shell_basics# ls
0-current_working_directory

This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.