Fenrir ID:
shell-setup
Branch:shell-setup
Points:20
You have to create a file setup.shell which configures the bash startup process. The setup script will be executed under a non-sudo user.
|
Caution
|
We recommend using fenrir env when solving this task.
|
The
[folder] ...
├─ [folder] shell-setup
│ ├─ ..
│ └─ [file code] setup.shell
└─ [folder] .gitSince rm command cannot be undone, we want to replace it with a more error-tolerant command. When executing rm FILE, the file must be moved to the /tmp/trash directory. Thus, it can be restored when someone has done something wrong.
|
Note
|
You don’t have to support all `rm’s flags. |
Set up bash autocomplete for the cow command:
cow say [-a|--aggressive] hi|bye
cow run <DIR>
cow eat <FILE>
cow sleepYou must use complete -F _cow cow command when registering the autocomplete algorithm.
Assume you have already installed cow utility into the /opt/cow folder. However, its execution fails with an error bash: cow: command not found…: fix it. Moreover, the command expects an environment variable MILKA_TYPE to be LU.
-
What happens with aliases during non-interactive shell sessions?
-
How does bash resolve commands?
-
What is the difference between
.bashrcand.bash_profilefiles?
The project is licensed under the terms of the Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License.
© 2026-present Iwan Kalinin <koefic.cien@gmail.com>