quiz bu lëkkale ak tegtal · Diggante Niveau
How to Write Shell Scripts with AI Quiz
Checks safe prompting, dry-run review, shell quoting, platform differences, and practical safeguards before running AI-drafted scripts.
Laaj 1 de 8
Laata ngay bàyyi ab script cleanup buñu defaree IA mu efaase fichier yi, lan mooy njëkka def li gëna wóor?
Xoolaatal laaj bu nekk8 laaj
Sooy def quiz bi, tontu yi ak leeral yi dañuy feeñ.
- Laata ngay bàyyi ab script cleanup buñu defaree IA mu efaase fichier yi, lan mooy njëkka def li gëna wóor?
- Use a dry run on a temporary folder and inspect every proposed path
- Run it as administrator to avoid permission errors
- Remove all error handling so failures are obvious
- Run it from the system root so relative paths are predictable
- Lan moo waral ñu wara jox tur wu leer Bash wala PowerShell?
- Both shells use identical variables but different colors
- Their syntax and command behavior differ
- AI cannot draft code without a shell name
- The operating system chooses one shell for all scripts
- Lan mooy jàppale ci moytu joxe argument yu ndaw yi ci limu?
- All program errors
- The program from reading files
- A filename being interpreted as shell syntax when no shell is invoked
- The need to check exit codes
- Script biñ defar dafay tabax ab string komand ci tur fichier bi jëfandikukat bi joxe. Lan ngay njëkka saytu?
- Whether the filename is long enough
- Whether comments use full sentences
- Whether the script has a logo
- Whether the value can be parsed as shell metacharacters
- Ban detay ci laaj bi moo gëna baaxal script biy kopie fichier bi?
- The operating system, shell, source and destination behavior, and overwrite rule
- The user's favorite editor
- A request to make the script clever
- A request to omit assumptions
- A test reports success even though one copy failed. Which improvement best addresses this?
- Print a longer completion message
- Check command exit status and report partial failures
- Run the same command twice
- Hide standard error
- Why use the least privilege needed for a script?
- It makes scripts shorter
- It prevents all syntax errors
- It limits the damage if a command or path is wrong
- It guarantees the AI used official documentation
- After a script changes files, what is a useful verification step?
- Assume the dry run guarantees the result
- Delete the log to save space
- Immediately rerun it with broader permissions
- Compare changed paths with the preview and inspect sample outputs