Boy, is the shell powerful.


 
Thread Tools Search this Thread
The Lounge What is on Your Mind? Boy, is the shell powerful.
# 8  
Old 05-08-2013
Hi figaro...

Quote:
I also think that shell programming is underrated.
Absolutely. I am new to it, and it probably shows too, but try and do even half of what the Scope does in a Windows, (TM), Command Prompt.
It is possible but it is seriously difficult.

Quote:
But when it comes to serious application layers running on top of large databases, shell will quickly be abandoned.
Ah, but as an amateur I see it differently. How many coders like me are interested in single file sizes 100's or 1000's of MegaBytes in size?

Hi DGPickett...

Quote:
Since GCC is free and open, it has been the first language out of the box for many CPUs.
I have veered away from ANSI C and C++ and base most of my non-shell scripting time in Python. I try to write code that works on version 1.4.x to current on Classic AMIGAs, (usually a stock A1200), Linux, Windows and now OSX. Most of it is on code.activestate.com but some is on AMINET...
This I find a mental challenge as there is so much to know and learn about the various platforms.
# 9  
Old 05-09-2013
Quote:
Originally Posted by wisecracker
try and do even half of what the Scope does in a Windows, (TM), Command Prompt.
Isn't that supposed to be the purpose of Windows Power Shell?

I've never used it, I'm genuinely wondering.
# 10  
Old 05-10-2013
Hi verdepollo...

I have been experimenting with Powershell and it is still highly limited.
Commands are one thing but manipulating text on screen is something else again...
(Unless of course I have missed something.)

What the *NIX family of OSes take for granted is not possible inside a defauilt 32 bit Windows command prompt...

The Escape sequences - such as multicolors per text line and plotting at any point within the command window.

Even HW problems when _refreshing_ the CLI window at _high_speed_ causes a pseudo-flicker inside the CLI window...

There are workarounds for some aspects but to generate the same image for the Scope project is not possible as you cannot have more than 2 colours from a CMD.EXE window.

i suspect you know this already though...

It surprises me that the Classic AMIGA can use many of the *NIX escape codes and works inside its default CLI but that Windows is oh, so, backwards...
# 11  
Old 05-10-2013
Well, PERL and JAVA are pretty transparently portable including Windows, or you can get CygWin and bash away.
# 12  
Old 05-10-2013
Code that will work fine in UNIX may have problems in windows. Something that crops up often enough in cygwin is failed fork() calls... UNIX will let you create thousands of short-lived processes without complaining, windows will hiccup once in a while. I consider this a bug in windows. It's not 10,000 live process after all, or even 10,000 dead ones, it's 10,000 processes that have already died and been reaped, but there's still some buffer or queue deep inside windows which it hasn't bothered to clear, and instead of doing so it gives you the occasional inexplicable error. You can reorganize your code to make less processes and it "usually" works but there's no way to be sure it always will.
These 2 Users Gave Thanks to Corona688 For This Post:
# 13  
Old 05-13-2013
Yes, CygWin fork/exec is slow at best. I have not had fork failures, but I keep my VM tuned to accomodate unexpected big. And I script to get the most out of every fork. No grep shell out just to examine the contents of a variable from every line. On UNIX, fork() is remarkably quik, and they have special cut down fork for exec immediately cases. The exec takes 10 times as long as fork, so what people call fork time is really exec time.
Login or Register to Ask a Question

Previous Thread | Next Thread

3 More Discussions You Might Find Interesting

1. Solaris

dd - imaging drives. Oh boy!

Hello, Yes, it's me again. Running around getting this done! My current problem is I'm trying to image one drive 0 (/dev/dsk/c1t0d0s0) to drive 1 (/dev/dsk/c1t1d0s0). I know that drive1 came out of a Sun Server and it is a Sun drive. Solaris 10 recognized drive1 after the devfsadm command. The... (8 Replies)
Discussion started by: adelsin
8 Replies

2. Shell Programming and Scripting

Any way to make scp more powerful?

Hello, I'm writing a script to automate the delivery of our code to different target environments and I was wondering if there's any way to cut down on the number of authentications that are needed. The script has to deliver to three different boxes (two directories on two boxes and one... (11 Replies)
Discussion started by: pallak7
11 Replies

3. OS X (Apple)

Is Mac OS X Server Really Powerful?

Look We all know that Linux is almost BulletProof and about 40% faster than Win2K3 Server, When running Oracle DB, Right? Now my Question is can OS X run just as Well as Linux as a Server being PowerPC and Whatever, Can it be just as stable? Now You Tell me, Which is most Practical: Linux... (3 Replies)
Discussion started by: RedVenim
3 Replies
Login or Register to Ask a Question