Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. The Lounge
  3. I (not) heart *nix

I (not) heart *nix

Scheduled Pinned Locked Moved The Lounge
learningapachedesignlinuxalgorithms
90 Posts 45 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • J Jim Crafton

    I've been given some more linux boxes to admin. Which means I've had to spend time today (well most of the day so far) randomly (re)learning the idiotic unix command line syntax needed to get things done. And I've had it up to *here* with the brain dead design and implementation of unix. Why is this system so popular? How is it possible for *multiple* generations of programmers to have their collective heads so deeply buried in the sand that virtually no real change or innovation has occurred in 30 years? Classic example, you need help, so what do you type? "man". That's right a 3 letter command (and you'd better be grateful it has a vowel, most don't), short for manual. Why not "manual", well that would be too much typing and apparently we're all still using 9 baud modems circa 1972. And to add insult to injury, it's a noun. Yes, you want to "perform" something, a verb, yet you're required to remember a noun. News break boys: it was idiotic in 1970, and *30* goddamn years later it's still stupid. Whatever. And why is it so hard to agree on a friggin file system layout and then everyone play nice? Isn't that what's supposed to be so great about open platforms? Apparently not, as genius wunderkinds at RedHat feel that they can add value by strewing random files for various common programs (like Apache) all over the place, leaving you, as the sys admin, to waste time spent randomly searching for config files. For example, if you build apache from source, the end result gets put into a standard set of directories. Binaries, configs, etc, all easy to find. If you install the apache module pre-built by red hat, thinking you'll save time, or be more "standard", or whatever goofy rationalization you're making, using their rpms, then no, we'll just randomly move shit around because we're *RedHat* and we know better. Dumbasses. And of course all the cute little techniques I've learned (again) today, will soon become forgotten because their so completely useless to what I do on a day to day basis, which is programming, most of the time. It's like you're trying to get useful work done with a bizarre 5 dimensional Rube Goldberg contraption that never really worked well to begin with, and now has so many patches, upon hacks, upon clever kludges, upon duct taped clusterfucks, that a nearby dog with a bad case of flatulence can blow the whole thing down. I hate *nix. Working with *nix makes me want to beat people with a club.

    ¡El diablo está en mis pantalones! ¡Mire, mire! Real

    Z Offline
    Z Offline
    ZombieHorde
    wrote on last edited by
    #74

    100% whole heartedly agree. What I would like to know is, why the hell such a smart guy like Linus Torvalds decided to write a system based on a system that's almost 40 years old? Why didn't he pick on a modern operating system, like OS/400 (i5/OS, if your so inclined) or hell even one that has sensible command names with some semblance of object orientation. It's like to be current these days, you have to go back to the stone age. I mean, any operating system with commands like grep, awk, sed, or ed needs to be wrapped in tin foil and shot into the heart of the sun. (It would probably not burn anyway. Some things are just to dense to burn.) Track down a copy of the Unix Haters Handbook and enjoy some of the true terrors of Unix and they're clones. Jeff

    1 Reply Last reply
    0
    • F fred_

      John M. Drescher wrote:

      The other big reason. Is no antivirus or antispyware software is needed on linux machines and so I do not have to deal with the headaches that these horrible programs cause

      That doesn't sound right to me ..... :doh:

      J Offline
      J Offline
      John M Drescher
      wrote on last edited by
      #75

      We have to run symantec products at work and I have found that these products really like to eat memory and performance. 150MB of memory used directly by the virus checker is the norm. To me that is plain ridiculous and totally kills the performance of a machine with 512MB or less RAM.

      John

      1 Reply Last reply
      0
      • T Trevortni

        Squirrel Hacker wrote:

        I would just like to add that at least you can paste stuff into the command prompt with out right clicking and selecting paste. Stupid Windows...

        :wtf: How in the world is it possible that I've never tried that until you said something?:confused:

        S Offline
        S Offline
        Squirrel Hacker
        wrote on last edited by
        #76

        Because you were raised in a Windows world ;P (to be fair, so was I, but now every time I open command prompt in Windows I get really annoyed that I have to drag the file over or select the paste option from a drop-down menu...). I love the freedom to paste into the terminal at any time (you can't even do that in cygwin). ^V... wow, useful (and shift-insert gives you a ~... that makes sense). I don't understand why the command prompt has to be so un-user friendly (user un-friendly?)! :mad: No wonder people are so intimidated by it...

        Squirrel Hacker

        T 1 Reply Last reply
        0
        • S Squirrel Hacker

          Because you were raised in a Windows world ;P (to be fair, so was I, but now every time I open command prompt in Windows I get really annoyed that I have to drag the file over or select the paste option from a drop-down menu...). I love the freedom to paste into the terminal at any time (you can't even do that in cygwin). ^V... wow, useful (and shift-insert gives you a ~... that makes sense). I don't understand why the command prompt has to be so un-user friendly (user un-friendly?)! :mad: No wonder people are so intimidated by it...

          Squirrel Hacker

          T Offline
          T Offline
          Trevortni
          wrote on last edited by
          #77

          No, I mean, how is it possible that I've never tried pasting into the Command window? I suppose that probably comes from being raised in DOS (not Windows, as you incorrectly assume ;P ) DOSKEY is natural, but the Windows GUI gets forgotten once I return to my native tongue. Though, if I recall correctly, gw-basic did have Cut-and-Paste. Of course, it also felt different than DOS, so it's every bit as impossible for stuff to carry over from there as it is for it to carry over from Windows.

          1 Reply Last reply
          0
          • J Jim Crafton

            I've been given some more linux boxes to admin. Which means I've had to spend time today (well most of the day so far) randomly (re)learning the idiotic unix command line syntax needed to get things done. And I've had it up to *here* with the brain dead design and implementation of unix. Why is this system so popular? How is it possible for *multiple* generations of programmers to have their collective heads so deeply buried in the sand that virtually no real change or innovation has occurred in 30 years? Classic example, you need help, so what do you type? "man". That's right a 3 letter command (and you'd better be grateful it has a vowel, most don't), short for manual. Why not "manual", well that would be too much typing and apparently we're all still using 9 baud modems circa 1972. And to add insult to injury, it's a noun. Yes, you want to "perform" something, a verb, yet you're required to remember a noun. News break boys: it was idiotic in 1970, and *30* goddamn years later it's still stupid. Whatever. And why is it so hard to agree on a friggin file system layout and then everyone play nice? Isn't that what's supposed to be so great about open platforms? Apparently not, as genius wunderkinds at RedHat feel that they can add value by strewing random files for various common programs (like Apache) all over the place, leaving you, as the sys admin, to waste time spent randomly searching for config files. For example, if you build apache from source, the end result gets put into a standard set of directories. Binaries, configs, etc, all easy to find. If you install the apache module pre-built by red hat, thinking you'll save time, or be more "standard", or whatever goofy rationalization you're making, using their rpms, then no, we'll just randomly move shit around because we're *RedHat* and we know better. Dumbasses. And of course all the cute little techniques I've learned (again) today, will soon become forgotten because their so completely useless to what I do on a day to day basis, which is programming, most of the time. It's like you're trying to get useful work done with a bizarre 5 dimensional Rube Goldberg contraption that never really worked well to begin with, and now has so many patches, upon hacks, upon clever kludges, upon duct taped clusterfucks, that a nearby dog with a bad case of flatulence can blow the whole thing down. I hate *nix. Working with *nix makes me want to beat people with a club.

            ¡El diablo está en mis pantalones! ¡Mire, mire! Real

            L Offline
            L Offline
            leonardo1976
            wrote on last edited by
            #78

            Stupid post I prefer short command line commands that long mouse gestures like in Windows. The Bill Geits stile of programming and administration is evil for example the VB is terrible.Windows Help system is terrible you wait 2 minutes for opening it and 2 hours for searching answer and not always you find it at all, man is exactly what sysadmin need, also remote administration with scripts is more quickly than Remote desktop mouse using or writing full size programs for small admin needs. The scripts in *nix more flexible than in in Windows the shell is better. So also in Microsoft understood this, they do Sysinternal command line tools , UNIX tools, Power Shell, so check your mind and brain and don't write holly war flames more. :mad:

            modified on Wednesday, August 6, 2008 3:05 AM

            1 Reply Last reply
            0
            • J Jim Crafton

              I've been given some more linux boxes to admin. Which means I've had to spend time today (well most of the day so far) randomly (re)learning the idiotic unix command line syntax needed to get things done. And I've had it up to *here* with the brain dead design and implementation of unix. Why is this system so popular? How is it possible for *multiple* generations of programmers to have their collective heads so deeply buried in the sand that virtually no real change or innovation has occurred in 30 years? Classic example, you need help, so what do you type? "man". That's right a 3 letter command (and you'd better be grateful it has a vowel, most don't), short for manual. Why not "manual", well that would be too much typing and apparently we're all still using 9 baud modems circa 1972. And to add insult to injury, it's a noun. Yes, you want to "perform" something, a verb, yet you're required to remember a noun. News break boys: it was idiotic in 1970, and *30* goddamn years later it's still stupid. Whatever. And why is it so hard to agree on a friggin file system layout and then everyone play nice? Isn't that what's supposed to be so great about open platforms? Apparently not, as genius wunderkinds at RedHat feel that they can add value by strewing random files for various common programs (like Apache) all over the place, leaving you, as the sys admin, to waste time spent randomly searching for config files. For example, if you build apache from source, the end result gets put into a standard set of directories. Binaries, configs, etc, all easy to find. If you install the apache module pre-built by red hat, thinking you'll save time, or be more "standard", or whatever goofy rationalization you're making, using their rpms, then no, we'll just randomly move shit around because we're *RedHat* and we know better. Dumbasses. And of course all the cute little techniques I've learned (again) today, will soon become forgotten because their so completely useless to what I do on a day to day basis, which is programming, most of the time. It's like you're trying to get useful work done with a bizarre 5 dimensional Rube Goldberg contraption that never really worked well to begin with, and now has so many patches, upon hacks, upon clever kludges, upon duct taped clusterfucks, that a nearby dog with a bad case of flatulence can blow the whole thing down. I hate *nix. Working with *nix makes me want to beat people with a club.

              ¡El diablo está en mis pantalones! ¡Mire, mire! Real

              B Offline
              B Offline
              bccgroup
              wrote on last edited by
              #79

              You cannot replace Knowledge with Howling. Ignorance is mankind's biggest enemy.

              1 Reply Last reply
              0
              • T thomas michaud

                You're not alone. However, you may find, after a time of studying Unix (including Bash / Ksh / etc) that it makes sense to you. You may, after enough time, even find that it is better than other systems. (Unix and programming go together like no other system.) However, if you REALLY want to move into the 21 century - check out Apple. They took Unix and shook it hard to get it to the 21 century. (I don't play with Apple, but that is the reports) BTW: why the hell would you build apache from source? The whole point of RedHat is that they take this source and compile it for you and put it into RPMs.

                B Offline
                B Offline
                bccgroup
                wrote on last edited by
                #80

                I think your answer it's a masterpiece. Thanks for posting this.

                1 Reply Last reply
                0
                • J Jim Crafton

                  I've been given some more linux boxes to admin. Which means I've had to spend time today (well most of the day so far) randomly (re)learning the idiotic unix command line syntax needed to get things done. And I've had it up to *here* with the brain dead design and implementation of unix. Why is this system so popular? How is it possible for *multiple* generations of programmers to have their collective heads so deeply buried in the sand that virtually no real change or innovation has occurred in 30 years? Classic example, you need help, so what do you type? "man". That's right a 3 letter command (and you'd better be grateful it has a vowel, most don't), short for manual. Why not "manual", well that would be too much typing and apparently we're all still using 9 baud modems circa 1972. And to add insult to injury, it's a noun. Yes, you want to "perform" something, a verb, yet you're required to remember a noun. News break boys: it was idiotic in 1970, and *30* goddamn years later it's still stupid. Whatever. And why is it so hard to agree on a friggin file system layout and then everyone play nice? Isn't that what's supposed to be so great about open platforms? Apparently not, as genius wunderkinds at RedHat feel that they can add value by strewing random files for various common programs (like Apache) all over the place, leaving you, as the sys admin, to waste time spent randomly searching for config files. For example, if you build apache from source, the end result gets put into a standard set of directories. Binaries, configs, etc, all easy to find. If you install the apache module pre-built by red hat, thinking you'll save time, or be more "standard", or whatever goofy rationalization you're making, using their rpms, then no, we'll just randomly move shit around because we're *RedHat* and we know better. Dumbasses. And of course all the cute little techniques I've learned (again) today, will soon become forgotten because their so completely useless to what I do on a day to day basis, which is programming, most of the time. It's like you're trying to get useful work done with a bizarre 5 dimensional Rube Goldberg contraption that never really worked well to begin with, and now has so many patches, upon hacks, upon clever kludges, upon duct taped clusterfucks, that a nearby dog with a bad case of flatulence can blow the whole thing down. I hate *nix. Working with *nix makes me want to beat people with a club.

                  ¡El diablo está en mis pantalones! ¡Mire, mire! Real

                  G Offline
                  G Offline
                  Gates VP
                  wrote on last edited by
                  #81

                  Jim Crafton wrote:

                  Isn't that what's supposed to be so great about open platforms?

                  I thought the great thing about standards was simply that there were so many to choose from. :) But hey, I work in an office when many developer (on different products) are coding in command lines and UNIX text editors. Not even Eclipse, I just keep thinking, "isn't your time valuable enough to afford something better"? Who cares that Eclipse / Visual Studio / etc. is a "memory hog", memory is cheap, time isn't... Oh well, at least the team using VS consistently rolls out new, functionality on tight schedules. Time will tell right :)

                  1 Reply Last reply
                  0
                  • J Jim Crafton

                    Gary R. Wheeler wrote:

                    Also, the application itself can't do anything to help the process along with a command line application, since it isn't even running when the user is typing the command line in.

                    Unless it's VMS :) In VMS you can simply type the command, and then the OS, in combination with template that the program has, will prompt you for options. And it's relatively easy to use and understand what it wants (in my experience). And if you give it bogus data, the errors, while not incredibly user friendly, are *light years* what you get on *nix or windows, which usually either fail silently, dump core, or spit out some cryptic error code/message that is frequently only tangentially related to what actually went wrong.

                    ¡El diablo está en mis pantalones! ¡Mire, mire! Real Mentats use only 100% pure, unfooled around with Sapho Juice(tm)! SELECT * FROM User WHERE Clue > 0 0 rows returned Save an Orange - Use the VCF! VCF Blog

                    G Offline
                    G Offline
                    Gary R Wheeler
                    wrote on last edited by
                    #82

                    That's funny. Vikram and I have been reminiscing about VMS and writing DCL command procs in another thread somewhere around here...

                    Software Zen: delete this;
                    Fold With Us![^]

                    1 Reply Last reply
                    0
                    • J Jim Crafton

                      I've been given some more linux boxes to admin. Which means I've had to spend time today (well most of the day so far) randomly (re)learning the idiotic unix command line syntax needed to get things done. And I've had it up to *here* with the brain dead design and implementation of unix. Why is this system so popular? How is it possible for *multiple* generations of programmers to have their collective heads so deeply buried in the sand that virtually no real change or innovation has occurred in 30 years? Classic example, you need help, so what do you type? "man". That's right a 3 letter command (and you'd better be grateful it has a vowel, most don't), short for manual. Why not "manual", well that would be too much typing and apparently we're all still using 9 baud modems circa 1972. And to add insult to injury, it's a noun. Yes, you want to "perform" something, a verb, yet you're required to remember a noun. News break boys: it was idiotic in 1970, and *30* goddamn years later it's still stupid. Whatever. And why is it so hard to agree on a friggin file system layout and then everyone play nice? Isn't that what's supposed to be so great about open platforms? Apparently not, as genius wunderkinds at RedHat feel that they can add value by strewing random files for various common programs (like Apache) all over the place, leaving you, as the sys admin, to waste time spent randomly searching for config files. For example, if you build apache from source, the end result gets put into a standard set of directories. Binaries, configs, etc, all easy to find. If you install the apache module pre-built by red hat, thinking you'll save time, or be more "standard", or whatever goofy rationalization you're making, using their rpms, then no, we'll just randomly move shit around because we're *RedHat* and we know better. Dumbasses. And of course all the cute little techniques I've learned (again) today, will soon become forgotten because their so completely useless to what I do on a day to day basis, which is programming, most of the time. It's like you're trying to get useful work done with a bizarre 5 dimensional Rube Goldberg contraption that never really worked well to begin with, and now has so many patches, upon hacks, upon clever kludges, upon duct taped clusterfucks, that a nearby dog with a bad case of flatulence can blow the whole thing down. I hate *nix. Working with *nix makes me want to beat people with a club.

                      ¡El diablo está en mis pantalones! ¡Mire, mire! Real

                      B Offline
                      B Offline
                      BrienMalone
                      wrote on last edited by
                      #83

                      I don't know why I'm shocked that someone hasn't jumped to the defense of *nix... I floated in here from the CodeProject insider article that featured this post, so I didn't notice that this was the .NET forum at first. I tried my first foray into *nix (in at least 15 years) with Ubuntu recently. The only reason I did this was so I could experiment with an OS that would see all 8gb of ram without costing $1500 and run VMWare Server. I load the OS and patch it up. Like you, I have to re-learn the command syntax just to get around. I download VMWare's free beta 2.0 server... and it doesn't work. I google the problem and try to decipher the fix. I figure it out... and something else bombs. Google again... "Lots of people have that problem, no one is sure why. Try these 10 things to fix it" No thanks. I load Windows Server 2003 Enterprise and patch it up. Load VMWare Server 2.0... and it works. End of story.

                      1 Reply Last reply
                      0
                      • M Mike Poz

                        John M. Drescher wrote:

                        One reason is the command line part of windows sucks forcing you to use the slow user interface and watch the silly animations while you move files.

                        Hmm... In a Windows (both client and server) CMD box this command will move files and folders without the silly UI animation: "move {source} {target}" and you can add the optional /Y to suppress overwriting prompts. Truth be told, 99% of your old DOS commands still work in Windows client and server editions without having to wait for silly slow user interface animations. You can even join domains and add domain users using the command line.

                        Mike Poz

                        A Offline
                        A Offline
                        Arterion
                        wrote on last edited by
                        #84

                        If you need something a little more robust for the command-line, use Robocopy.[^] It's in the Windows Resource Kit for 2003/XP, and comes standard on 2008/Vista. If you're looking for something a little more robust for the GUI, I can't recommend TeraCopy[^] enough. There's also a Robocopy GUI[^] if you're so inclined. But I do definitely agree that the built-in file copying for Windows is awful. (Though in fairness, I can't say the GUI file copying of any other OS is much better.)

                        1 Reply Last reply
                        0
                        • L Lost User

                          I respectfully disagree. :) Other than freshman-level engineering students, I don't know any Unix users who have to look up the syntax for the copy command. :) I find Unix being an entirely different mindset, and I find Unix to be much, much more powerful than any Windows I've ever used. I can do operations in Unix in 5 minutes that would take a whole day in Windows. A short digression: Recently for my research, I created a Unix command line tool. The source of the research's funding did not like that as they wanted a program with a graphical interface. Their reasoning being that their employees did not have the time to learn a command line program. (Now these are people who are performing IV&V on safety-critical software.) To which I replied, "You have people doing safety-critical IV&V who can't use a command line???" :omg:

                          A Offline
                          A Offline
                          Arterion
                          wrote on last edited by
                          #85

                          The JZ wrote:

                          I can do operations in Unix in 5 minutes that would take a whole day in Windows.

                          No offense, but that's probably because you don't really know how to use Windows. You have really powerful tools at your disposal, right out of the box (command line, wsh). And if they're not powerful enough, it's trivial to add more functionality like powershell or perl (though perl is just an extension to wsh). Even command line scripting is pretty powerful, and not any more complicated than *nix command line scripting. You can set variables, use conditional statements, and jump around to different labels that run different code. Not really functions, but maybe procedures. And if that's not enough for you -- or you don't want to learn it -- you probably know Javascript, right? JScript support for WSH is built right in. So you can write your admin stuff in a fully object-oriented way. (There's even a regular expression object you can use.) If you DID want a little gui frontend, it's very simple to do with an hta. As for administration, there isn't much you can't do with WMI and ADSI. You can interface either of those from really any programming language, but they've made it really easy to do from WSH scripts and from powershell. So yeah, I can't help but think you feel that way because you just honestly don't know how to use Windows. I will say that it's not your fault, though. Microsoft doesn't make all that knowledge as readily available as *nix does.

                          1 Reply Last reply
                          0
                          • C Chris Losinger

                            Jim Crafton wrote:

                            the idiotic unix command line syntax

                            oh, how i'd love it if Windows had a command line half as smart as any of the unix shells. that we can now write VBScript for batch files instead of classic .BAT, only seems like progress in light of the fact that DOS itself is barely functional. BASIC? talk about 1972! (ok, i guess you can run JScript in WSH, too)

                            image processing toolkits | batch image processing

                            modified on Monday, August 4, 2008 4:26 PM

                            A Offline
                            A Offline
                            Arterion
                            wrote on last edited by
                            #86

                            Batch files are just command line scripts. VBScript is using something called "Windows Scripting Host", or WSH. They're not designed to replace batch files, but they have done so largely because they're easier to use, and more powerful. The cool thing about WSH is that any scripting language can hook-up to it. Out of the box, you have VBScript AND JScript, and you can easily add Perl, Python, tcl, or Ruby support. Also keep in mind, when you say "unix command line" you're talking about a variety of different command lines, some of them better than Windows, some of them not. I generally concur that bash is better, with colouring and whatnot, but what significant functionality is missing from the Windows command line that you have in *nix? Bash is open-source, though. It will compile and run just fine on windows. Cygwin is a dev environment that'll do just that. So you really can have a "unix command line" running right on Windows, if that's what you prefer.

                            C 1 Reply Last reply
                            0
                            • A Arterion

                              Batch files are just command line scripts. VBScript is using something called "Windows Scripting Host", or WSH. They're not designed to replace batch files, but they have done so largely because they're easier to use, and more powerful. The cool thing about WSH is that any scripting language can hook-up to it. Out of the box, you have VBScript AND JScript, and you can easily add Perl, Python, tcl, or Ruby support. Also keep in mind, when you say "unix command line" you're talking about a variety of different command lines, some of them better than Windows, some of them not. I generally concur that bash is better, with colouring and whatnot, but what significant functionality is missing from the Windows command line that you have in *nix? Bash is open-source, though. It will compile and run just fine on windows. Cygwin is a dev environment that'll do just that. So you really can have a "unix command line" running right on Windows, if that's what you prefer.

                              C Offline
                              C Offline
                              Chris Losinger
                              wrote on last edited by
                              #87

                              Arterion wrote:

                              Batch files are just command line scripts.

                              of course. and the Windows/DOS cmd line (aka CMD) sucks.

                              Arterion wrote:

                              Also keep in mind, when you say "unix command line" you're talking about a variety of different command lines

                              also, of course. but, when you say "unix command line" usually people assume you're talking about one of the big ones - the ones which are worth using (bash, csh, etc).

                              Arterion wrote:

                              but what significant functionality is missing from the Windows command line that you have in *nix?

                              here's a simple example: given a task which takes a non-trivial amount of time, get a DOS/CMD/BAT script to time that operation. now try to do multiple timers, so you can time sub-tasks as well.

                              Arterion wrote:

                              Cygwin is a dev environment that'll do just that.

                              Cygwin brings its own issues (the Unix file system paradigm, for example).

                              image processing toolkits | batch image processing

                              A 1 Reply Last reply
                              0
                              • C Chris Losinger

                                Arterion wrote:

                                Batch files are just command line scripts.

                                of course. and the Windows/DOS cmd line (aka CMD) sucks.

                                Arterion wrote:

                                Also keep in mind, when you say "unix command line" you're talking about a variety of different command lines

                                also, of course. but, when you say "unix command line" usually people assume you're talking about one of the big ones - the ones which are worth using (bash, csh, etc).

                                Arterion wrote:

                                but what significant functionality is missing from the Windows command line that you have in *nix?

                                here's a simple example: given a task which takes a non-trivial amount of time, get a DOS/CMD/BAT script to time that operation. now try to do multiple timers, so you can time sub-tasks as well.

                                Arterion wrote:

                                Cygwin is a dev environment that'll do just that.

                                Cygwin brings its own issues (the Unix file system paradigm, for example).

                                image processing toolkits | batch image processing

                                A Offline
                                A Offline
                                Arterion
                                wrote on last edited by
                                #88

                                set START_TIME=%time% rem do some stuff set END_TIME=%time% You can do the date/time math to subtract the two, but it's admittedly messy -- and not something I feel like working out on a whim. I don't know how easy date/time math is in *nix, but I'm gonna guess it's messy there, too. Unless you're in an environment with DateAdd() or DateSubtract() types of functions, it's messy. Even if I were on *nix, I'd probably do the date subtraction in perl. Or find someone else's code that would do it for me, but you could do that on Windows, too.

                                C 1 Reply Last reply
                                0
                                • A Arterion

                                  set START_TIME=%time% rem do some stuff set END_TIME=%time% You can do the date/time math to subtract the two, but it's admittedly messy -- and not something I feel like working out on a whim. I don't know how easy date/time math is in *nix, but I'm gonna guess it's messy there, too. Unless you're in an environment with DateAdd() or DateSubtract() types of functions, it's messy. Even if I were on *nix, I'd probably do the date subtraction in perl. Or find someone else's code that would do it for me, but you could do that on Windows, too.

                                  C Offline
                                  C Offline
                                  Chris Losinger
                                  wrote on last edited by
                                  #89

                                  Arterion wrote:

                                  You can do the date/time math to subtract the two, but it's admittedly messy

                                  and that's my point. the stupid thing can't even handle subtraction gracefully.

                                  Arterion wrote:

                                  I don't know how easy date/time math is in *nix, but I'm gonna guess it's messy there, too

                                  before="$(date +%s)"
                                  long block of slow code
                                  after="$(date +%s)"
                                  elapsed_seconds="$(expr $after - $before)"

                                  bash is smart enough to allow subtraction. it's even simpler in ksh.

                                  image processing toolkits | batch image processing

                                  1 Reply Last reply
                                  0
                                  • J Jim Crafton

                                    I've been given some more linux boxes to admin. Which means I've had to spend time today (well most of the day so far) randomly (re)learning the idiotic unix command line syntax needed to get things done. And I've had it up to *here* with the brain dead design and implementation of unix. Why is this system so popular? How is it possible for *multiple* generations of programmers to have their collective heads so deeply buried in the sand that virtually no real change or innovation has occurred in 30 years? Classic example, you need help, so what do you type? "man". That's right a 3 letter command (and you'd better be grateful it has a vowel, most don't), short for manual. Why not "manual", well that would be too much typing and apparently we're all still using 9 baud modems circa 1972. And to add insult to injury, it's a noun. Yes, you want to "perform" something, a verb, yet you're required to remember a noun. News break boys: it was idiotic in 1970, and *30* goddamn years later it's still stupid. Whatever. And why is it so hard to agree on a friggin file system layout and then everyone play nice? Isn't that what's supposed to be so great about open platforms? Apparently not, as genius wunderkinds at RedHat feel that they can add value by strewing random files for various common programs (like Apache) all over the place, leaving you, as the sys admin, to waste time spent randomly searching for config files. For example, if you build apache from source, the end result gets put into a standard set of directories. Binaries, configs, etc, all easy to find. If you install the apache module pre-built by red hat, thinking you'll save time, or be more "standard", or whatever goofy rationalization you're making, using their rpms, then no, we'll just randomly move shit around because we're *RedHat* and we know better. Dumbasses. And of course all the cute little techniques I've learned (again) today, will soon become forgotten because their so completely useless to what I do on a day to day basis, which is programming, most of the time. It's like you're trying to get useful work done with a bizarre 5 dimensional Rube Goldberg contraption that never really worked well to begin with, and now has so many patches, upon hacks, upon clever kludges, upon duct taped clusterfucks, that a nearby dog with a bad case of flatulence can blow the whole thing down. I hate *nix. Working with *nix makes me want to beat people with a club.

                                    ¡El diablo está en mis pantalones! ¡Mire, mire! Real

                                    Y Offline
                                    Y Offline
                                    Yvan Rodrigues
                                    wrote on last edited by
                                    #90

                                    man is the best! It's simple it makes sense. man and you get the docs for almost every app with 99% success rate and a consistent format. Windows... F1 works for GUI apps about 40% of the time. You might get html help, chm help, a tiny dialog, or some other random command that the programmer assigned to F1. For command-line apps, try random combinations of /? /h /help =? -h --help ... Windows is my primary OS and FreeBSD is secondary/favourite. Simple Beauty. Windows does some things amazingly. It has the simplest yet most robust OS installer of any OS. FreeBSD can work as a bulletproof fast web server, firewall or file server on a 486 and 128MB of RAM. Mac OS is ... cute? :rose:

                                    1 Reply Last reply
                                    0
                                    Reply
                                    • Reply as topic
                                    Log in to reply
                                    • Oldest to Newest
                                    • Newest to Oldest
                                    • Most Votes


                                    • Login

                                    • Don't have an account? Register

                                    • Login or register to search.
                                    • First post
                                      Last post
                                    0
                                    • Categories
                                    • Recent
                                    • Tags
                                    • Popular
                                    • World
                                    • Users
                                    • Groups