Live data from Hacker News

Looking Forward: Support for Secure Shell

blogs.msdn.com

341–350 of 404 posts

Re: Looking Forward: Support for Secure Shell

#341
post #266
post #216

Earlier quoted context omitted.

I'd guess that almost all corporations would be on your 'hate' list. This is a popular position, yes. But Microsoft in particular have tried to make Linux impossible on a number of occasions over a period of decades, so it'll take a while for the guerillas to come out of the jungle and stop fighting them. But now they're in competition with the platform that want to annex all your personal data and the platform that…

Linux survived because commercial vendors poured in over a billion dollars into making it a viable UNIX alternative. Microsoft's feeble attempts to sabotage it are pretty much irrelevant in that regard.

It's easy to call it "feeble" because it lost, but the worst-case outcome would have ruled the POSIX API was copyright SCO (funded by Microsoft), making it infringement to distribute Linux.

Linux could have survived in peaceful co-existence without the corporate billion. It would have been smaller and more hobbyist. It could not have survived if all the judgements had gone the wrong way.

Re: Looking Forward: Support for Secure Shell

#342

Earlier quoted context omitted.

Lots of people keep saying this on this thread, but why would you want GNU tools on Windows ? Have you ever wanted to put Apple's runtime on your Linux box? Or MSVC runtimes on your Linux machine? Weirdly, everyone wants the opposite.

I'm not interested specifically with GNU's tools, just standard Unix tools in general; Microsoft could easily use Cygwin (for example) as a reference point for porting/packaging the BSD userland to/for Windows, for example. > Have you ever wanted to put Apple's runtime on your Linux box? Not in that sense, but a Linux + BSD userland would be neat. Apple's runtime is basically that minus Linux plus Mach/XNU plus Cocoa…

Out of interest, what's wrong with MSVC runtimes? Plenty of software has been written using it.

Doesn't Wine basically implement MSVC runtimes?

Re: Looking Forward: Support for Secure Shell

#343
post #320

Earlier quoted context omitted.

This is really cool (and unfortunately I know nothing about powershell, I'm young and dumb) but I'm pretty sure this is replicable line for line with bash (and curl, maybe awk too idk). Am I wrong?

Probably not. In my experience it's not so much about things being impossible elsewhere, just that PowerShell can often be better at fiddling in a REPL until you got the results you wanted, in a way. The point where you need (or want) to upgrade to a more powerful language is IMHO earlier in bash than in PowerShell². PowerShell handles objects like Unix utilities handle text. You get a lot more orthogonality in comma…

Your comment was useful, so not totally in vein :-)

Just incited me to have a little look at powershell (read through [0], useful intro). It looks nice, I can definitely see the utility in have a simple object model for transferring information between processes. In nix land you get pretty good at extracting data from simple text forms, though sometimes it's harder than it should be.

One thing that jumped out at me there is the overhead of the commands.

    430ms: ls | where {$_.Name -like "*.exe"}
    140ms: ls *.exe
    27ms : ls -Filter "*.exe".
Not so much the absolute numbers but the fact that there are 3 different ways of doing it and the more flexible choice is over a magnitude slower.

What happens when you add another command to the pipeline? Do they buffer the streams like in linux?

I guess the situation will improve over time but how complete is the eco-system at the moment? One area nixes will always shine is the total ubiquity. Everything can be done over commands and everything works with text.

[0] https://developer.rackspace.com/blog/powershell-101-from-a-l...

Re: Looking Forward: Support for Secure Shell

#344

Earlier quoted context omitted.

I think homebrew and MacPorts are niche though. Your "normal" OSX user wouldn't install them. Heck, I ran Linux for years and years and I haven't even installed them under OSX because if I wanted to run BSD or Linux, I'd have installed BSD or Linux. It's like installing all those GNU tools on Windows to make it more like Linux, and putting Homebrew etc. on OSX to make it more like Linux. Why not just use Linux or BSD…

I think the key point here is this: you're right that regular users don't need homebrew; developers certainly do. By having an analog of homebrew for Windows, Microsoft can attract more developers, which then would translate into a better app infrastructure for Windows. This would then clearly benefit regular users as well. I haven't used Windows in a very long time, but whenever I sit by a friend's computer, I find…

I'm a developer (I develop on OSX and Windows every day for my day job and at home for myself) and I do not use homebrew. There is not anything I am really missing, but I write C++/Obj-C and you might write something different.

It is interesting regarding the state of app design as most of the BSD or Linux software looks odd to me! I agree that Windows has some odd looking software but they do typically offer more features - you don't get MDI under OSX.

Re: Looking Forward: Support for Secure Shell

#345

Earlier quoted context omitted.

Couldn't agree more. As a die hard Unix guy and ex Slashdot-esque zealot (colloquially a bit of a twat). Yet I'm knocking out PowerShell all the time now and dread having to log into the pile of CentOS kit I have lying around. It is arcane. Even after 15 years I spend most of my time in the manpages or working out another damn config format. Literally did a two liner to scrape a web page, parse it and call a REST end…

I did find an open source implementation here: http://pash.sourceforge.net/ Don't know if it's any good --- never tried it; it says it's about half complete, but I don't know if it's a useful half. After looking at the docs, you could do a lot of what Powershell does with Unix shells; you'd need a different set of conventions, where instead of using unformatted text as an intermediate format you used a streamable tab…

> Don't know if it's any good --- never tried it; it says it's about half complete, but I don't know if it's a useful half.

There are at least two parties working on it who have interest in certain features to be working: It's the NuGet shell within MonoDevelop, so custom PowerShell hosts need to work as well as a bunch of things needed by NuGet. Then one of the more prolific developers actually gets paid to work on Pash to support features related to PowerShell add-ins and a few others. (My own efforts so far were mostly bits and pieces, missing cmdlets (there are still a lot of those), test cases, and weird parser behaviour, mostly due to my history of golfing in PowerShell – golfed code makes for some fun tests of edge cases.)

Re: Looking Forward: Support for Secure Shell

#346

Earlier quoted context omitted.

TBH I couldn't find a decent book or resource and sort of hacked my way around for a year or so. It had a good build in manual (get-help). This is a good poke at the fundamentals of my example: Scrape a page: $flight = " LH3396" $url = "http://bing.com?q=flight status for $flight" $result = Invoke-WebRequest $url $elements = $result.AllElements | Where Class -eq "ans" | Select -First 1 -ExpandProperty innerText Hit a…

This is really cool (and unfortunately I know nothing about powershell, I'm young and dumb) but I'm pretty sure this is replicable line for line with bash (and curl, maybe awk too idk). Am I wrong?

Don't use awk for parsing XML/JSON, there are excellent tools like html-xml-utils or jq that already do that well:

    $ sudo apt-get install html-xml-utils jq

    $ curl 'https://duckduckgo.com/html/?q=cake' | hxclean \
       | hxselect  .web-result:first-child .snippet

    $ curl apy.projectjj.com/listPairs | jq .responseData[0]

Though I'd typically use Python's BeautifulSoup for anything major with html, there's just too much bad html out there ;)

Re: Looking Forward: Support for Secure Shell

#347
post #321

Earlier quoted context omitted.

> OpenGL on Windows desktop continues to suffer greatly from Microsoft's lack of support In what way? I write graphics code for a living and from what I've seen opengl is basically fine on windows. They could do more, sure, but I never felt like they were getting in the way. I have mixed feelings on the directx thing. In principle I'm not a fan of directx, but in terms of API quality it's vastly better than opengl. A…

> They could do more, sure, but I never felt like they were getting in the way. If you would try to ship OpenGL game you'll find out that Windows 8+ shipped with crippled AMD Legacy driver (HD2XXX-4XXX) that don't have OpenGL support in it and can't be really replaced using AMD Catalyst installer until user manually install new driver via Device Manager using extremely tricky way. There was also crippled Intel driver…

You'd have to take that up with the hardware manufacturers, I guess. It's not like Microsoft writes said drivers and if AMD chooses to submit a DirectX-only driver for inclusion in the OS then where's MS's fault?

Re: Looking Forward: Support for Secure Shell

#348

Earlier quoted context omitted.

Couldn't agree more. As a die hard Unix guy and ex Slashdot-esque zealot (colloquially a bit of a twat). Yet I'm knocking out PowerShell all the time now and dread having to log into the pile of CentOS kit I have lying around. It is arcane. Even after 15 years I spend most of my time in the manpages or working out another damn config format. Literally did a two liner to scrape a web page, parse it and call a REST end…

I did find an open source implementation here: http://pash.sourceforge.net/ Don't know if it's any good --- never tried it; it says it's about half complete, but I don't know if it's a useful half. After looking at the docs, you could do a lot of what Powershell does with Unix shells; you'd need a different set of conventions, where instead of using unformatted text as an intermediate format you used a streamable tab…

> And if I never have to parse the output of ls -l using cut again, I will be a happy person.

Try stat instead, e.g.

    $ stat -c 'NAME: %n; OWNER: %U, SIZE: %s' * 
also supports --printf (see man stat).

Re: Looking Forward: Support for Secure Shell

#349

Earlier quoted context omitted.

Why? I assume that "private VLAN" means it isn't exposed to potential external attack.

It must be great to know no-one within your environment will ever do anything wrong. Or download anything that will do anything wrong. Or visit any websites than can hijack your browser into doing anything wrong.

a) Human error is a possibility but that's not something that can be eliminated.

b) They won't download anything wrong. There's no route to the internet for this machine.

c) They won't visit any web sites. There's no browser on the machine. This is a core profile windows server installation.

Don't assume that we don't know what we're doing. We have 500ish Windows Server machines floating around.

Re: Looking Forward: Support for Secure Shell

#350

Earlier quoted context omitted.

It already was. In the NT days.

Yes, they even had a slogan "Windows NT is a better UNIX than UNIX". Which never rang really true, but NT had promise.

Could you be mixing this up? There was a heavil-used phrase, "OS/2 is a better Windows than Windows" during the Windows 3.0 era, because the OS/2 Windows subsystem was far more stable than Microsoft's Windows (and also - as it happens - a good deal more stable than the rest of OS/2 also).
Post reply on HN