Hacker News new | past | comments | ask | show | jobs | submit login

I asked ChatGPT “Let’s say I want a program to delete unused files. Can you write a detailed specification that a developer could use?”. I was as vague as possible on purpose.

Here’s what it gave me:

“Program Name: FileCleaner

Overview: The FileCleaner program is designed to identify and delete unused files from a specified folder or directory. The program scans the directory for files that have not been accessed for a specified period of time and prompts the user to delete them. The program is intended to free up disk space and improve system performance.

Requirements:

The program must be able to scan a specified folder or directory for files that have not been accessed for a specified period of time.

The user should be able to specify the time period after which a file will be considered unused.

The program should prompt the user to delete the identified unused files.

The user should have the option to select which files they want to delete.

The program should permanently delete the selected files from the system.

The program should log all deleted files, including their ___location and name, in a separate file for future reference.

The program should have a user-friendly interface that is easy to navigate and understand.

Functional Specification:

The user launches the FileCleaner program.

The user is prompted to select the folder or directory they want to scan for unused files.

The user is prompted to enter the time period after which a file will be considered unused (e.g., 30 days).

The program scans the specified folder or directory for files that have not been accessed for the specified time period.

The program displays a list of unused files, including their ___location and name. The user is prompted to select which files they want to delete.

The program permanently deletes the selected files from the system.

The program logs all deleted files, including their ___location and name, in a separate file for future reference.

The program displays a message indicating that the selected files have been successfully deleted.

The user can choose to exit the program or scan another folder or directory.

Non-Functional Specification:

The program must be designed and implemented using a high-level programming language, such as Python or Java.

The program should be able to handle large files and directories without crashing.

The program should have a user-friendly interface that is easy to navigate and understand.

The program should be able to run on multiple operating systems, including Windows, MacOS, and Linux.

The program should be secure and not pose a risk to the system or user data.

The program should be well-documented, with clear and concise instructions for use and troubleshooting.

By following these specifications, a developer can create a FileCleaner program that efficiently identifies and deletes unused files from a specified folder or directory.”

This could be improved even more by having it ask questions to narrow down exactly what is needed




Consider applying for YC's Summer 2025 batch! Applications are open till May 13

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: