Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

Python

how do you delete commands in the console

how do you delete commands in the console

1 Answer

Jeff Muday
MOD
Jeff Muday
Treehouse Moderator 28,720 Points

Which console are you thinking of? The Python REPL or Treehouse Workspaces?

With a Python REPL, there is no deleting a command that has been issued. In the Workspaces console, it is a normal Linux shell that is dependent on use of the keyboard or STDIN stream. There isn't an undo or delete command per se unless you are talking about file and directory deletion.

Files are deleted with the rm command, and directories/folders are deleted with the rmdir command.

To find out more you can type rm --help or rmdir --help