Slashdot Mirror


Developer Accidentally Deletes Three-Month of Work With Visual Studio Code (bingj.com)

New submitter joshtops writes: A developer accidentally three-month of his work. In a post, he described his experience, "I had just downloaded VScode as an alternative and I was just playing with the source control option, seeing how it wanted to stage -- five thousand files -- I clicked discard... AND IT DELETED ALL MY FILES, ALL OF THEM, PERMANENTLY! How the f*uk is this s*it possible, who the hell is the d******* who made the option to permanently delete all the files on a project by accident even possible? Cannot even find them in the Recycle Bin!!!! I didn't even thought that was possible on Windows!!! F*ck this f*cking editor and f*ck whoever implemented this option. I wish you the worst.'

5 of 765 comments (clear)

  1. Re:Version Control = Good by Z00L00K · · Score: 4, Interesting

    He was from I understand trying out a revision control system that was pretty buggy.

    In general I have found out that source control systems related to the Microsoft environment are tricky. They used to have something called Source Safe, it was fine until the repository disk was full, then you lost everything.

    --
    If builders built buildings the way programmers wrote programs, then the first woodpecker would destroy civilization.
  2. Commodore 64 in 1983... by MindPrison · · Score: 3, Interesting

    ...taught me to back up my stuff.

    I remember when I spent my first "programming" hours, at the tender age of 12, painstakingly typing in the program examples in the manual, just to withness the power cord glide out of the mains plug entirely without my help. It happened twice in a row (I got a new computer later on, it was a factory defect).

    But that taught me to always back up my stuff. I remember often making 5-10 backups of my machine language experiments on the C64, this is a habit that has followed me into the modern age.

    I think that's testimony to our times, things work so well that people don't experience losses before it's too late, so they don't feel the natural need to protect their stuff.

    --
    What this world is coming to - is for you and me to decide.
  3. Re:Version Control = Good by F.Ultra · · Score: 5, Interesting

    I don't think that Source Safe ever works fine for any definition of the word. Back some 12-15 years when I was working at a "Omg we can only use Microsofts products" place it was common to see our dev chief roll back the entire Source Safe repository from backups. Some times I saw him do this on a daily basis. Another fine touch where when some dev checked out some files and went on a 5 week vacation leaving the file locked in Source Safe, not the good old days :)

  4. Re:Just tried it by PmanAce · · Score: 3, Interesting

    He never did an original commit so all changes since "last" commit is everything, just like you said.

    --
    Tired of my customary (Score:1)
  5. Re:Git by swillden · · Score: 5, Interesting

    Fortunately he can just retrieve his files from his Git repository, right? Or... he just learned a painful lesson of why you always use a code repository.

    I have to take this opportunity to tell my favorite oh-shit story.

    Some twenty-odd years ago, I was working on an embedded system project which had about 60 person-years of development effort into it (20 developers, three years). We worked on HPUX workstations with our home directories NFS-mounted on a big Network Appliances NFS server. The server was pretty cool tech for the day, making use of RAID for redundancy, with nifty snapshotting features, including automatic snapshotting that created a set of hidden subdirectories in each directory with your files as they were an hour before, two hours before, etc. Getting back any old version was super easy. Plus we all used CVS, and the CVS server also used NFS storage.

    So... all of our eggs were in one basket, but it was a highly-reliable and flexible basket and, of course, the sysadmin made nightly backups, rotated the tapes offsite, etc. The backups even included the snapshots, providing quite fine-grained history from any point in time. So not bad.

    Well, one day something went wrong, and the NFS server lost everything. I don't know if it was hardware failure, if the sysadmin accidentally did something like "rm -rf /", or what. But it was all gone. All of the developers' home directories, with their working copies, and the central CVS repository. Every Single Line Of Code, all of the design documents other that what happened to be laying around in hardcopy, everything. 60 person-years.

    Oh shit.

    But, backups, right? No.

    Not one.

    The sysadmin had never tested his backups, and it turned out that his backup script didn't have permission to read any of the directories where the important data lived. The backup tapes were all useless. He had dozens of methodically-archived off-site copies of the NFS server system binaries. You know, the ones that come on the installation media.

    OH SHIT!

    Luckily, we had one major customer that was so big, financially, and so influential in the relevant industry, that when they signed their contract to buy our product, they made us commit to keeping a developer on-site, full-time. So we all took turns spending a couple of weeks at a time living in a hotel and working in their facility, on the other side of the continent. And, most importantly, there was a development workstation there. With a local copy of the code that was updated via FTP as needed.

    Now, for you young'uns that only know about distributed version control systems, CVS wasn't (isn't) such a beast. In CVS there's one central repository which has all of the versioned history, all of the branches (not that there were many, because working with branches was a pain in the ass), all of the tags, etc. When you check out the code, you get only the current head revision of the one branch, no history at all.

    That's what this one remote workstation had. A checkout of HEAD, as it was a couple of weeks before the disaster. We carefully copied that, and FTP'd it back home, and used it to start a new, fresh, CVS repository. All of the commit history was gone, and a couple of weeks of work by 20 or so people, but we had nearly-current code. All of the design docs and other bits and pieces were gone, but we had code.

    You may be wondering if, at this point, the sysadmin got canned. He did not. He was called onto the carpet and told that we HAD to have good, tested backups going forward. He agreed that it would be his top priority. A couple of weeks later, he reported back to senior management that we had good backups.

    My boss decided to test it. He disabled snapshotting of his home directory, created a file, put some stuff into it, waited a day (so it would get backed up to tape), then deleted it and walked over to ask the sysadmin to recover it for him.

    The backups still didn

    --
    Note to ACs: I usually delete AC replies without reading them. If you want to talk to me, log in.