Very Expensive Typo

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • UserNameGoesHere
    FFR Veteran
    • May 2008
    • 1114

    #1

    Very Expensive Typo

    gcc -o myprogram myprogram.c
    ./myprogram
    ...errors at blah blah line numbers ...
    ...fix those errors...
    rm myprogram
    gcc -o myprogram myprogram.c
    ./myprogram
    ....errors at blah blah line numbers...
    .
    .
    .
    ...(hours of this later)...
    rm myprogram.c
    gcc -o myprogram myprogram.c
    No such file or directory

    FUUUUUUUU
    Originally posted by Crashfan3
    Man, what would we do without bored rednecks?
  • dAnceguy117
    new hand moves = dab
    FFR Simfile Author
    • Dec 2002
    • 10097

    #2
    Re: Very Expensive Typo

    rip source code

    Comment

    • Fluvs
      FFR Veteran
      • Sep 2009
      • 674

      #3
      Re: Very Expensive Typo

      Messed up

      Comment

      • FissionMailed1
        FFR Player
        • Feb 2012
        • 1267

        #4
        Re: Very Expensive Typo

        Why aren't you using a makefile so this kind of thing doesn't happen, lmfao. Even if you only have one source file, it is a good habit to get into.


        YOUR THROBBING MULTIFARIOUS LUSTFUL DESIRES ARE COMPLETED N YOUR HYPER-ORANGE SELF, YOU MAKE ME LOVE AGAIN, YOU'VE CHANGED MY HEART, MY MELANCHOLIA DISAPPEARS WHEN YOU ARE INSIDE OF ME, MY HUMAN RAGE IS TEMPERED WHEN I AM INSIDE YOU, THE SECRET IS COMMUNICATION, LONGEVITY, STAMINA, REPETITION, FURY, SOULFUL KISSING, EARPLUGS. YOU FUCKING CORPORATE COCKS AND CUNTS.

        MY ANXIETY COMPLETE, MY DESIRE REPLETE, THE TASTE OF ORANGE BLOOD AND CUM AND GREENBACKS RUNNING DOWN MY FACE. THE STREETS WILL RUN ORANGE WITH YOUR MIXTURE OF CHEETOS AND HUNDRED DOLLAR BILLS REGURGITATED AND EATEN AND SHIT OUT AGAIN AND EATEN AGAIN.

        YOU ARE MY SCULPTURE, MY SCULPTRA, MY SELF-DEFINITION. MY DEFINITION OF HUMANITY, MY HARMONY. MY HEART AND MY MIND.

        YOU ARE SO ORANGE. SO CRUNCHY. SO CONSUMABLE.

        THE NEW ORANGE UNDERGROUND IS THE ORANGE UP MY ASS. AND YOUR ASS.

        I LOVE YOU CHEETOS.

        Comment

        • UserNameGoesHere
          FFR Veteran
          • May 2008
          • 1114

          #5
          Re: Very Expensive Typo

          Originally posted by FissionMailed1
          Why aren't you using a makefile so this kind of thing doesn't happen, lmfao. Even if you only have one source file, it is a good habit to get into.
          Yeah if it was something bigger I would. And you're right that I probably should.

          I dunno -- I get sloppy sometimes when I'm just trying to throw something together.

          Finished what I was doing, but that oops did set me back a bit. :-P
          Originally posted by Crashfan3
          Man, what would we do without bored rednecks?

          Comment

          • Izzy
            Snek
            FFR Simfile Author
            • Jan 2003
            • 9195

            #6
            Re: Very Expensive Typo

            I'm confused what you were trying to type in the first place that was similar to "rm".

            Comment

            • UserNameGoesHere
              FFR Veteran
              • May 2008
              • 1114

              #7
              Re: Very Expensive Typo

              Originally posted by Izzy
              I'm confused what you were trying to type in the first place that was similar to "rm".
              rm wasn't the typo

              the .c on the end was.


              Basically- compile code, test executable, fix code, delete executable, compile code,etc..
              Except one time an accidental delete source.
              Originally posted by Crashfan3
              Man, what would we do without bored rednecks?

              Comment

              • Izzy
                Snek
                FFR Simfile Author
                • Jan 2003
                • 9195

                #8
                Re: Very Expensive Typo

                But wouldn't recompiling already overwrite the preexisting executable?

                Comment

                • UserNameGoesHere
                  FFR Veteran
                  • May 2008
                  • 1114

                  #9
                  Re: Very Expensive Typo

                  Originally posted by Izzy
                  But wouldn't recompiling already overwrite the preexisting executable?
                  It does. But, ... habit. It was more to ensure I had a "clean" environment in the off-chance it for some reason didn't get overwritten, as unlikely as that might be. Probably a tad OCD like double or triple checking your house door to make "sure" you locked it.

                  I'm very thorough, but sometimes a bit too thorough.

                  While this over-thoroughness bit me here, it is quite handy for things like finding and fixing bugs though.
                  Originally posted by Crashfan3
                  Man, what would we do without bored rednecks?

                  Comment

                  • qqwref
                    stepmania archaeologist
                    FFR Simfile Author
                    • Aug 2005
                    • 4092

                    #10
                    Re: Very Expensive Typo

                    Why didn't you use the up arrow (or similar) to copy the command you previously used? That should make it very hard to make a mistake like this.
                    Best AAA: Policy In The Sky [Oni] (81)
                    Best SDG: PANTS (86)
                    Best FC: Future Invasion (93)

                    Comment

                    • UserNameGoesHere
                      FFR Veteran
                      • May 2008
                      • 1114

                      #11
                      Re: Very Expensive Typo

                      Originally posted by qqwref
                      Why didn't you use the up arrow (or similar) to copy the command you previously used? That should make it very hard to make a mistake like this.
                      With a bunch of miscellaneous commands, it's usually easier to just type stuff out than search through command history unless it's a particularly involved command (lots of options used/etc...)

                      Again, more force of habit. I would be issuing other commands in the between time and don't really feel like sifting 5 to 10 commands back to find what I want when it's easy enough to just type it out. That said, costly typo. :-P

                      One other thing I could do though to avoid this particular problem in the future is just allow the default name of a.out for the executable, for testing purposes, and only rename it once finished. It'd be pretty hard to accidentally delete a source code file that looks nothing like "a.out" and if I tried to remove a.out.c that file wouldn't exist and wouldn't matter.
                      Originally posted by Crashfan3
                      Man, what would we do without bored rednecks?

                      Comment

                      • FissionMailed1
                        FFR Player
                        • Feb 2012
                        • 1267

                        #12
                        Re: Very Expensive Typo

                        The thing about makefiles is that you can just make a template one that is universal for simple directory structures (i.e. everything is in the same directory as the makefile). It isn't a big deal to just reuse it, just change GCC args and whatnot. Also, in your makefile, you can add a label to delete all object files, so you can do something like this:

                        make
                        make clean

                        If you don't want to set up source control, you could just work out of Dropbox. That way, you have rudimentary housekeeping, should you make this mistake again.
                        Last edited by FissionMailed1; 06-2-2013, 11:56 PM.


                        YOUR THROBBING MULTIFARIOUS LUSTFUL DESIRES ARE COMPLETED N YOUR HYPER-ORANGE SELF, YOU MAKE ME LOVE AGAIN, YOU'VE CHANGED MY HEART, MY MELANCHOLIA DISAPPEARS WHEN YOU ARE INSIDE OF ME, MY HUMAN RAGE IS TEMPERED WHEN I AM INSIDE YOU, THE SECRET IS COMMUNICATION, LONGEVITY, STAMINA, REPETITION, FURY, SOULFUL KISSING, EARPLUGS. YOU FUCKING CORPORATE COCKS AND CUNTS.

                        MY ANXIETY COMPLETE, MY DESIRE REPLETE, THE TASTE OF ORANGE BLOOD AND CUM AND GREENBACKS RUNNING DOWN MY FACE. THE STREETS WILL RUN ORANGE WITH YOUR MIXTURE OF CHEETOS AND HUNDRED DOLLAR BILLS REGURGITATED AND EATEN AND SHIT OUT AGAIN AND EATEN AGAIN.

                        YOU ARE MY SCULPTURE, MY SCULPTRA, MY SELF-DEFINITION. MY DEFINITION OF HUMANITY, MY HARMONY. MY HEART AND MY MIND.

                        YOU ARE SO ORANGE. SO CRUNCHY. SO CONSUMABLE.

                        THE NEW ORANGE UNDERGROUND IS THE ORANGE UP MY ASS. AND YOUR ASS.

                        I LOVE YOU CHEETOS.

                        Comment

                        • dAnceguy117
                          new hand moves = dab
                          FFR Simfile Author
                          • Dec 2002
                          • 10097

                          #13
                          Re: Very Expensive Typo

                          I email myself code periodically. #ghettolyfe

                          Comment

                          • leonid
                            I am leonid
                            FFR Simfile Author
                            FFR Music Producer
                            • Oct 2008
                            • 8080

                            #14
                            Re: Very Expensive Typo

                            Check your recycle bin :twisted:



                            Proud member of Team No

                            Comment

                            • dAnceguy117
                              new hand moves = dab
                              FFR Simfile Author
                              • Dec 2002
                              • 10097

                              #15
                              Re: Very Expensive Typo

                              oh u..........

                              Comment

                              Working...