Load OS Ubuntu examples batch 2

This commit is contained in:
Timothyxxx
2024-01-26 00:15:04 +08:00
parent b9ae4174b1
commit 64594701ae
14 changed files with 324 additions and 124 deletions

View File

@@ -4,15 +4,60 @@
"instruction": "Could you please help me to set Bash as my default shell on the current Ubuntu system?",
"source": "https://superuser.com/questions/46748/how-do-i-make-bash-my-default-shell-on-ubuntu",
"trajectory": "trajectories/",
"config": [],
"config": [
{
"type": "execute",
"parameters": {
"command": "echo password | sudo -S apt-get install zsh -y",
"shell": true
}
},
{
"type": "execute",
"parameters": {
"command": "echo password | sudo -S chsh -s $(which zsh)",
"shell": true
}
},
{
"type": "execute",
"parameters": {
"command": "echo password | sudo -S loginctl terminate-user user",
"shell": true
}
},
{
"type": "sleep",
"parameters": {
"seconds": 10
}
},
{
"type": "execute",
"parameters": {
"command": [
"python",
"-c",
"import pyautogui; import time; time.sleep(2); pyautogui.press(\"enter\"); pyautogui.type(\"password\"); time.sleep(2); pyautogui.press(\"enter\");"
]
}
}
],
"related_apps": [
"os"
],
"evaluator": {
"func": "",
"result": {
},
"expected": {
}
"func": "exact_match",
"result": {
"type": "vm_command_line",
"command": "echo $SHELL",
"shell": true
},
"expected": {
"type": "rule",
"rules":{
"expected": "/bin/bash\n"
}
}
}
}