Skip to content
← Back to Community
Student accidentally deleted code - any way to get prior version of program?
Profile icon
kmcleod

Hi! One of my students just emailed me that they were working on their final project and they accidentally deleted 100 lines of code from their program. Is there any way for them to access prior versions of their code so that they can reconstruct what they deleted?

Thanks!
Kate

Answered by hyperupcall [earned 5 cycles]
View Answer
Voters
Profile icon
BraydenVanDeGra
Profile icon
HiddeStruck
Profile icon
GerasimS
Profile icon
AyatiShah
Profile icon
K0dingKid
Profile icon
ArshSharma1
Profile icon
DianaLopez2
Profile icon
jackierama
Profile icon
joelwillams
Profile icon
HaydenMcLeary
Comments
hotnewtop
Profile icon
hyperupcall

Not sure if you found the solution, but the button can be hidden away. It might also be called "saved".

This file cannot be displayed: https://storage.googleapis.com/replit/images/1558311511282_fd58de0a18aad0fd333b271adbe57db2.pn

Once you click on it, then you can access the history mode. On the left sidebar, there's some "change file" text.

This file cannot be displayed: https://storage.googleapis.com/replit/images/1558311666416_d6e551b57318971fcf7e223620373e88.pn

Once you click on that, then you can restore a specific file to a specific point in time. I don't think you revert the whole repl though - only a specific file.

Profile icon
[deleted]

Thats easy to solve, thanks to repl.its history feature. tell your student to click on it, he can there go back in the code-timeline. If this answer helped you, i would appreciate if you amrk it with answered.

Profile icon
Vandesm14

@enigma_dev How come your comment has 0 upvotes? This happens to some other comments that you have. You might want to contact the replit team about this.

Profile icon
[deleted]

@Vandesm14 Thats is myself removing my upvote. It is a psychological thing, might explain that later on discord.

Profile icon
[deleted]

@Vandesm14 Thats is myself removing my upvote. It is a psychological thing, might explain that later on discord.

Profile icon
kmcleod

Is this feature available for a classroom assignment as opposed to a regular repl?

Profile icon
MikthePlug

@kmcleod IS THERE????

Profile icon
a5rocks

There should be "history" button on their repl, with a bunch of versions which you can back up to.

Profile icon
JamesHope1

@a5rocks is this there for the classroom assignments?

Profile icon
pattmax

They should be backing up their code on Github in the future.

Profile icon
Masy

@kmcleod

Refer to what our lovely friend @eankeen said and mark his answer as correct.

Profile icon
Masy

Or who ever was first