35 ms·
PowerShell is open sourced and is available on Linux
- hussnainm92 10y agoopen this link http://www.24gag.com/?p=2912 http://www.24gag.com/?p=2912
- 2close4comfort 10y agoThat is awesome. Truly an inspired set of changes at Microsoft lately.
- qjighap 10y agoI am pretty excited about this as I have few cross-platform languages that I can use (due to conditions at work). I am wondering how many distros will adopt it into their repos.
- otoburb 10y agoMicrosoft is projecting that the .NET ecosystem will become a main revenue driver, regardless of the underlying operating system.
- ihsw 10y agoWell they certainly have the resources to grow and support the .Net tech stack, that's for sure. I'm finding myself stuck in it more and more. TypeScript was my gateway drug. Linux is still my daily driver for getting work done but I can't help but enjoy breakpoint debugging Node applications in VS Code.
- satysin 10y agoWhich is why I have no doubt the Universal Windows Platform will become the Universal Platform and be a true desktop/tablet/mobile/server/etc Java competitor on all major OS (mobile, traditional and server). It must be rather frustrating for Microsoft to look back a decade or more and see they were sitting on the exact technology a hell of a lot of people said would be their future had they made it cross-platform from the start. I remember using C# for the first time around 2004 and thinking "god damn if this were cross-platform like Java it would kill Sun". Back then Microsoft couldn't see past the tip of their nose though.
- gcr 10y agoBut that's what .NET wanted to be. That's what Silverlight wanted to be.
- wvenable 10y agoUntil now they didn't do what was necessary to make that a reality -- actually fully embrace other platforms.
- vvanders 10y agoYup, I've been playing around with C# more lately and it's such a good language. Things like embedding with native code is trivial compared to Java. Want to call a delegate(with extras) from a C function pointer? Sure thing, just specify some syntax and away you go. Marshalling strings? Just works. Totally a breath of fresh air compared to the mess that is JNI.
- Analemma_ 10y agoPowerShell is my guilty pleasure of the computing world. Once you've piped strongly-typed objects around between your shell commands, text scraping seems barbaric by comparison. The problem, of course, is that you can't use all that power for much, since the pool of PS-compatible tools and utilities is much shallower than it is for Unix shells. I'm really hoping this will help spur a new wave of PowerShell-compatible tools. Come to the dark side, we have (strongly-typed) cookies.
- kevan 10y agoI really hope this drives a new wave of experimentation and development in shell interaction. Text as the lowest common denominator will never go away but having more powerful constructs available will be great for a lot of use cases.
- otabdeveloper 10y agoCheck out the language I wrote for that exact use case: http://tkatchev.bitbucket.org/tab/ http://tkatchev.bitbucket.org/tab/
- htor 10y agoStrongly typed cookies you say.. Maybe we all can just write our scripts in Haskell and eat some delicious type cake!
- amenod 10y agoIs this really so useful in practice? I have never used PowerShell before (nor do I have plans to do so in the near future), but I would imagine the downside is complexity, both for user and especially for developers. With text you just read and parse, while with objects you need to know the object type, its fields,... Whatever happend, I hope text stays here (and I have a bad feeling about it ever since I met systemd).
- UK-AL 10y agoObjects are discoverable in powershell. Enter the object, and lists the object out as text.
- wineisfine 10y agoGreat. I wonder what Steve Ballmer is thinking.
- RankingMember 10y agoBallmer's long gone, so he's probably thinking about the LA Clippers (he's the owner).
- dozzie 10y agoHe gets his share of evilness with Windows 10 wreaking havoc in users' privacy. Microsoft doesn't seem to have changed that much.
- jaytaylor 10y agoProbably "<something>, <something>, developers". I'd love to know his reaction to and thoughts surrounding this move.
- purplejacket 10y agoSteve who?
- beachstartup 10y agohe's thinking about an nba championship.
- tombert 10y agoI'm always in favor of things being open-sourced, but I do kind of wonder in what universe I would use PowerShell when Bash is readily available.
- xyzxyz998 10y agoWhat do you know about Powershell? (The answer will depend on that)
- UK-AL 10y agoHonestly, I prefer the object based approach compared to the text wrangling approach.
- larrik 10y agoAs a full-time Linux user, I have to say that bash is overrated. For instance, on Windows I could press the up arrow through my history 20x to find a group of commands I want to run, press Enter, then press DOWN for the following command, then enter, then DOWN until I run them all. In Bash, I need to press UP 20x every single time. Yes, you can customize it a lot, and you can script it but default bash isn't that special to me.
- jupiter90000 10y agoI've been hoping for a fully-featured Linux version of Powershell for a while, very awesome. I've used various Linux distributions for a long time and find bash very practical usually, but when I started learning Powershell when working in Windows environments I've been impressed with how easy it was to do some powerful stuff, and felt conflicted since I wanted to be able to use similar functionality and scripts across Linux/Windows.
- electricEmu 10y agoIt's been such a difficult road. The consistency that PowerShell provides makes discovering things simple. There's no referencing a MAN page to see which parameter switch it is for _this_ tool. Yet, there's been no power. No ability to harness OSS tools in that way. Now, maybe I can have both.
- heywire 10y agoPowershell really became interesting for me recently. I was working on diagnosing a production issue where one of our win32 applications failed on loading a .net assembly (dll). The error messages weren't terribly useful, and I wasn't getting a good stack trace. While Googling around, I found out that you can randomly instantiate .net objects from the PS command line. A few commands later and I had a full stack trace indicating the problem.
- uep 10y agoPowershell isn't competing with bash, it's competing with Python. So then, how does it compare against Python? While plenty of small scripts are still done with bash, I think Python is pretty common for serious production needs. I use it for virtually all scripting these days. I had a recent experience where a developer spent a day and couldn't get Powershell's webrequest library to do what he wanted. I was able to accomplish the goal in 15 minutes with Python on a Debian system.
- jupiter90000 10y agoSure, there are different ways to do various things, especially depending on what one is familiar with and what the task at hand is. It sounds more like you knew how to get something done with your tools faster than the other guy/gal in this case. :)
- electricEmu 10y agoFinally! I love the methodology behind PowerShell. It's more verbose than bash, and that's OK to me. The readability and _consistency_ far outweigh the extra characters. Now, I get that coupled with all the flexibility of *nix tooling. It's going to be a long road to hook everything up, but this has the chance to finally standardize command parameters. I'm sorry. This is truly amazing to me and I'm quite excited!
- cbaleanu 10y agoI Can Only See One Problem With PowerShell :)
- ghostly_s 10y agoIt's happy to gobble up whatever improperly-capitalized cmdlets you throw at it, heck you can even forget some letters ;). And with a little tap on that tab key it will helpfully fix your laziness so there's no trace of it in your shell history.
- electricEmu 10y agoSo, that's kind of the beauty to me. For long lived scripts I can always type out `ForEach-Object { ... }`. When I'm ad-hocing there's always `%{ ... }`. Bash is a strange beauty, but part of that beauty is how arcane it can be. Generally, people use the smallest parameter possible in scripts instead of the full name. While this can definitely continue with PS, the community has decided on "alias for ADHOC and Full-Name for scripts". This helps the readability tons if someone hasn't memorized all the command parameters.
- noveltyaccount 10y agoPowershell is case-insensitive, so feel free to avoid that shift key if you're so inclined :)
- cbaleanu 10y agoBeen using PS for a long time and I had no idea about this. Thanks !
- lanestp 10y agoI'm glad that Microsoft is doing stuff like this. But, I can't imagine a lot of Linux users are going to want to use it. As a former Windows developer I always found Power Shell to be lacking in nearly everything I wanted to do on the command line, in fact, I mainly did shell commands on a remote Ubuntu server.
- mercer 10y agoWould you mind elaborating on Power Shell's lack? I've never used it so I'm curious to know more.
- Spivak 10y agoI think the most succinct way of describing it is that UNIX tooling is scatterbrained and at times a little ugly, but each command exits because it solved someone's real-life problem. PS by comparison is a set of tools that try to be all encompassing and solve problems MS devs think people will have. Our PS repository is full of scripts that do nothing but abstract PS into useful high-level actions.
- micro_softy 10y agoGates pioneered copyright protection for source code. Ballmer said Linux is cancer. This company has betrayed its own values. Actually it hasn't. The strategy is always the same: destroy the competition. Undersell. Even give away software for free. Whatever it takes. Money to burn. What's interesting is that they see the UNIX shell, which has long been open source and free, as competition.
- bmer 10y agoJust like Google, Apple, IBM, etc. etc. etc. I'll join in on the Microsoft bashing club when every other major corporation gets bashed the same way by devs. The day that will happen is when socialism makes more sense to people than capitalism, and it becomes a pervasive idea, but sadly, I think that day won't be coming around any time soon. Until then, let's enjoy the fruits of capitalism.
- micro_softy 10y agoI've been enjoying the fruits of Bell Labs and UC Berkeley. I'm not a "dev" or even a Linux or Bash user. I like the simplest Bourne shells the best. Plan 9's rc is also good. I've never enjoyed using Microsoft Windows. (But if they gave away the source for NT kernel I might find use for it, after a lot of work trimming it down to size.) Maybe the size and power of UNIX has spoiled me. MS obsessively focuses on their competition to the detriment of users and software quality.
- floopidydoopidy 10y agoThey see all things that flourish outside their control as competition.
- the_mitsuhiko 10y ago> Ballmer said Linux is cancer He more or less said that the GPL is cancer which is pretty accurate. The entire quote is "Linux is not in the public domain. Linux is a cancer that attaches itself in an intellectual property sense to everything it touches. That's the way that the license works" Not very nice but not entirely wrong either.
- deleted 10y ago[deleted]
- Nelkins 10y agoPowerShell is an improvement on Bash, but I'll still be using F# .fsx files for my .NET scripting needs. That said, the real reason I'm excited about this release is that there's finally a great example of a very large project based on .NET Core [1]! Most other examples I'd seen were pretty small, so this is really helpful. [1] https://github.com/PowerShell/PowerShell https://github.com/PowerShell/PowerShell
- giis 10y agoCan you share advantages or powershell improvements over Bash ? or is it kind of over-statement?
- Secretmapper 10y agoWow. I've been very impressed with Microsoft lately. They could have easily set themselves up as the next IBM, in the sense of being a monolithic corporation relying on corporate practices, but they've been spewing some crazy fun things that shows they're not out of the league yet. Might just be MY miscontrued perception that microsoft was becoming old/monolithic, but really excited with the direction they are heading.
- vvanders 10y agoVery much so. They're returning to their roots(winning over developers with world-class tools) and it's really refreshing to see. Between this, VSCode and .NET Core it really is an impressive effort.
- nitrogen 10y agoLet's hope the awesomeness they are showing on the developer relations side finally leaks into the Windows side and they stop their shenanigans with W10 and Android and VFAT patent threats. It's so disappointing to see this kind of split-brained behavior.
- Sylos 10y agoNah, why should they? Developers are pretty much the only demographic that might realistically switch operating systems, so they only really need to cater to them. The rest, they can pretty much treat however they want, and they won't lose them as customers.
- Grishnakh 10y agoExactly. The developers they can get to work for them are "useful idiots", whose work they then use to further screw over their main customers, who aren't going to abandon them no matter what, and also bring in more developers to their platform and away from the competition. As long as these developers are easily and naively wooed by a bunch of BS talk about "the new Microsoft", they get to help MS with their evil shenanigans.
- shadowmint 10y agoIs this actually useful? I always thought powershell was largely just for interacting with windows components, like installing an msi or talking to active directory. What would you actually practically use this for on a linux box?
- hirsin 10y agoScripting. While I typically use Bash on Windows to use grep to interactively test my webserver, I'm much happier using Powershell ISE (which I don't know was ported [1]) to write standard tests with multiple parts, particularly ones that require e.g. checking cookies on the response. 1. Looks like they ported a service that does the same. https://github.com/powershell/powershelleditorservices https://github.com/powershell/powershelleditorservices
- shadowmint 10y agoCan you be more specific? Powershell instead of using grep? Or as a testing framework? Or an embedded interactive REPL? I mean, just broadly, with basically zero knowledge of powershell, what I see is a custom scripting language with a set of common 'macro' commandlets that do little tasks. ...but, I don't see how that's useful? How do you import a package to upload a file to S3? I can't just install https://aws.amazon.com/powershell/ https://aws.amazon.com/powershell/ right? ...because that's not ported? So...? etc. etc. for other practical tasks. Not trolling; just genuinely curious what actual tasks are actually supported that you could actually use this for, beyond trivial stuff like 'check if file exists'?
- UK-AL 10y agoSince it's only come out not all 3rd party scripts are going to available straight away. but there are standard http post/get/put commands so you can write your own.
- steveataws 10y agoWe are currently performing final validation on our new AWSPowerShell.NetCore module and hope to publish it to the PowerShell Gallery in the next couple of days. Blog post to the announcement: http://blogs.aws.amazon.com/net/post/TxTUNCCDVSG05F/Introducing-AWS-Tools-for-PowerShell-Core-Edition http://blogs.aws.amazon.com/net/post/TxTUNCCDVSG05F/Introduc....
- voltagex_ 10y ago>We will be extending the PowerShell Remoting Protocol (MS-PSRP) to use OpenSSH as a native transport. Users will have the option to use SSH or WINRM as a transport. Is possibly an even bigger announcement (this means there's actual momentum behind https://github.com/PowerShell/Win32-OpenSSH https://github.com/PowerShell/Win32-OpenSSH)
- arca_vorago 10y agoThis is what I have been waiting for right here!
- new_hackers 10y agoyup, me too!
- qrmn 10y agoI think it might have rolled out already. Turn on Developer Mode in Windows 10 Anniversary Edition, and ssh to port 22 with a valid l/p? Doesn't look like you even need to install WSL.
- loarabia 10y agoIt looks like they're a little different for now. See the note under here. https://msdn.microsoft.com/en-us/windows/uwp/get-started/enable-your-device-for-development#ssh https://msdn.microsoft.com/en-us/windows/uwp/get-started/ena... Full Disclosure: I am a MSFT employee.
- newman314 10y agoMore specifically, I don't want to SSH from a Windows box. I want to SSH into a Windows box (and say figure out a way to easily install a LE cert)
- 10y ago
- autoreleasepool 10y agoExcellent news. Now I might actually learn PowerShell
- knocte 10y agoStrongly-typed scripting is nice, but I think PowerShell has horrid syntax. I would rather take .fsx scripts any day.
- knocte 10y ago(.fsx scripts are F#, so also strongly typed)
- andschwa 10y agoI've been working on this for some time now, and am ecstatic to share this project with the world!
- RubyMyDear 10y agoPeople laugh at me when I tell them I switched "back" to Windows after decades of Unix and Mac programming. But it's a really good, productive platform. Microsoft really seems to be heading in the right direction now. I hope .NET starts taking off on other platforms, too, because it really is a much better system than Brand "J".
- clebio 10y agoIf only they resolve the privacy leakage concerns in a reasonable manner.
- oblio 10y agoIn the Windows 10 thread someone posted this hilarious comic: http://www.bonkersworld.net/organizational-charts/ http://www.bonkersworld.net/organizational-charts/ We just have to hope that "our" guys (OSSers) have bigger guns than "those" guys (privacy destroyers).
- UK-AL 10y agoConsidering most OSS devs slam analytics on literally every website. Really there isn't much difference. That's what windows is sending. Analytics information. Yet I can guarantee every major website developed by open source using devs is sending the same information for their apps. Yet no one complains.
- oblio 10y agoLook at the comic. I'm talking about divisions inside Microsoft. I doubt it very much that Scott Hanselman (for example), who is in the camp that pushes Microsoft to open up, is the kind of person that designed the privacy controls (or their lack) in Windows 10.
- GrumpyYoungMan 10y agoAmen. Having used Windows Server and various Unixes, I much prefer Windows.
- deleted 10y ago[deleted]
- ilurkedhere 10y agoFinally! It's exactly what we need since there are currently no scripting languages available in Unix user-land for when you need to do something beyond /bin/bash
- jshevek 10y agoPoe's law
- sdegutis 10y agoCool. https://powershell.org/ https://powershell.org/ needs some work though. It screams WordPress 2008 website, and I'm not given any idea how to install or use it, or what it's good for, just by looking at the front page.
- erk__ 10y agoIt is not a Microsoft website.
- yumaikas 10y agoPowershell is the first language where I managed to save time by writing a program for a task. Needless to say, I'm thrilled at the prospect of using it on Linux. The only thing that I hope they will need to work on is startup time making sure it performs well on low-spec servers (It can be a bit slow starting cold on older laptops). ls -Recurse | ? { $_.Name -match ".+docx" }
- ratboy666 10y agoI am not sure what your example does. How does it differ from find . -name ".docx" ls -Recurse | ? { $_.Name -match ".+docx" } And, if these are the same, why type in twice as many characters as a command? Actually, ls -R | grep "\.docx$" is, I think, closer in spirit. Now, the issue is things further in the pipeline, I imagine. The find solution allows selection on type name, type, date, depth, mounts, properties, file system type, ownership, relative age, inode, symbolic link. find actions include delete, exec, print, quit. This can pass on needed information to further pipeline commands. However, an interactive shell is meant to allow expression of commands with a reasonable minimum of keyboarding (thus ls and not dir). I could argue that the "Unix" command should be find . -n ".docx" (because the most common -n... option used is -name). I think, to be fully reasonable the find command you want is find . -regex ".*\.docx$" which is still shorter than the PS example. I am not sure that for most interactive tasks, PS is a win. It does appear to be more elegant, but only usage over time will show if it is indeed more productive. I am looking for academic productive studies to be done, now that both bash and PS are available on common platforms.
- Analemma_ 10y agoIf you're just talking about ls/dir, then PowerShell isn't really a win. The advantages are clearer when you start talking about lots and lots of commands. A lot (but not all!) Unix tools have flags to control their output format or input filters, but that means you have to memorize different flags for all of them. OTOH, in PS you just pipe to where/sort/select and they work for everything. IMO PowerShell has better separation of concerns.
- yumaikas 10y ago
- BooneJS 10y agoI've got this embarrassingly ugly perl-inside-cygwin to automate something with a GUI tool that happens to have an even worse scripting plugin. I suspect Powershell would allow me to take the whole process native?
- 131hn 10y agoPowershell is an old tech, so browsing the source tree on github should show some of MS internal practices & guidelines in the old times. Yet the github project start in feb 2015. Where is the source code before that ?
- dboreham 10y agoOn some interal MS RCS.
- vmarsy 10y agoGreat! So I can now run bash on windows (with WSL), open tmux, and open powershell prompts in each tab: the loop is complete! I wish powershell's documentation was a bit more clear about what's powershell 1.0, 2.0, 3.0... Etc. A lot of time I'd find a verbose and tedious way to do one thing because the code was written in "old powershell", when the latest version had a much more elegant solution (either because of new language features or simply more cmdlets were added, removing the need to fall back to some C# syntax) On stack overflow it often means read more than the chosen answer, somebody would have added a newer way to do it. I wish Microsoft "hey script guy" blog had some versioning info (this post was last updated in 2016, using powershell 3, see powershell 2 version here)
- cptskippy 10y agoI agree, there's been a lot of churn in the PS versions and it makes it hard. Especially when you're new to it and trying to learn.
- ianai 10y agoYep, in my experience the documentation for Python and really anything OSS far outstrips powershell
- artursapek 10y agoDoes tmux work well on Windows? Everything Microsoft has been doing recently with bash on Windows has made me consider buying a surface pro as my next machine.
- floopidydoopidy 10y agoHow much does astroturfing pay?
- deleted 10y ago[deleted]
- sctb 10y agoWe detached this subthread from https://news.ycombinator.com/item?id=12313389 https://news.ycombinator.com/item?id=12313389 and marked it off-topic. Baseless accusations of astroturfing are not allowed on HN. If you believe this is happening and you have evidence, please email us hn@ycombinator.com and we will happily investigate.
- floopidydoopidy 10y agoHow could I possibly prove that? You guys should ban all comments that look like astroturfing. By banning accusations of astroturfing, you endorse it, because there is no way to discuss it on your forums. I'd have to organize an anti-astroturf astroturfing movement just to balance it out.
- aidos 10y agoCool! I'm having a play with it and it seems to work really nicely. Does anyone know why the following commands don't produce the same output? get-childitem | ConvertTo-Csv get-childitem | ConvertTo-Json | ConvertFrom-Json | ConvertTo-Csv It seems like, if there's a perfect underlying data model doing what's effectively an identity conversion shouldn't change anything. Edit oooo, and all the linux stuff is available within it too. So you can run this to just augment your linux experience. ls | grep '_' | ConvertTo-Json
- ygra 10y agols is an alias for Get-ChildItem. However, grep is the native command in this case. While such things work to some extent, it has the problem of turning your objects into plain strings. Effectively the same as if you had run (ls | % Name) -match '_' The fact that the file's name is its default string conversion can be pretty annoying when dealing with results, e.g. from gci -recurse where it's quiet important to retain the path to the file. So, careful with such things. On Stack Overflow I tend to scold people who reduce PowerShell objects to strings without good reason ;-)
- philsnow 10y agoI don't have a powershell handy, but one thing that might be causing changes is that json dictionaries usually don't have a defined order (parsing libraries are free to render the keys of a dictionary in any order); are the changes you're seeing just ordering changes?
- trevorsullivan 10y agoIf you have a Docker Host, you can simply run: docker run --rm -it trevorsullivan/powershell To clean up the image after you're done: docker rmi trevorsullivan/powershell
- new_hackers 10y agols and grep are aliases in powershell, so not exactly the same, but pretty close For your first question: you have converted types. When you did a ConvertTo-Json, you serialized the System.IO.DirectoryInfo type into JSON compatible data. When you ConvertFrom-Json you have a PCSCustomObject. The conversion to CSV is different for the System.IO.DirectoryInfo than the PSCustomObject. This has to do with the sub-types (converting from objects into serializable JSON objects). It also appears to handle time strings differently as well.
- williamjackson 10y agoAnd now PowerShell on Bash on Ubuntu on Windows is a thing. (Spoiler alert, it doesn't work very well right now. The cursor keeps jumping to the top of the console and overwriting existing text.)
- Delmania 10y agoI was just about to try that exact series of steps to see how things went.
- aruggirello 10y agoNo, PowerShell on Bash on Ubuntu on a Windows VM on a Linux host is a thing :)
- sixothree 10y agoAnd soon Windows VM's will be able to run inside of other Windows VM's so..... VM's all the way down.
- AndrewGaspar 10y agoIf you run it inside of tmux, that issue seems to go away for some reason.
- duiker101 10y agoI like Microsoft's move here. They first made available bash on Windows and then PowerShell on Linux. So no one is going to cry. And now they will improve PowerShell and win over users with a good tool rather than just because that's the only one available.
- perlgeek 10y agoCan I write tools that use PowerShell and .NET objects in non-.NET languages, like Python or Perl (using the C implementations, not a .net python)? Like, is there an API that I can implement to interact to implement PowerShell-like "native" tools?
- zhengyi13 10y agoIt's not the most efficient way to do it, but if you just want to get it done, Powershell has had e.g. ConvertTo-Json since version 3, I think? You can serialize pretty much anything at that point, and just hand that off to your target language. If you're talking an FFI though, not so much, I think.
- denfromufa 10y agouse pythonnet to interact with .NET dlls from CPython: https://github.com/pythonnet/pythonnet https://github.com/pythonnet/pythonnet
- SwellJoe 10y agoI bought a new laptop recently, and used Windows for a little while (I didn't have time or a USB drive handy for installing Linux for a couple of weeks). I was pleasantly surprised at PowerShell. Not because of all the stuff people normally like about PowerShell; all the PS things are still confusing as hell, to me. But, because MS has embraced compromise and meeting developers where they are in ways that I have never seen from MS until recently. PowerShell now accepts most of the common UNIX shell commands (this feature could have come at any point in the past decade, or so, as that's how long it has been since I last tried PowerShell, when it was new). The changes that resulted from that change of mindset has made it so I could actually stay in PowerShell long enough to learn other things. Having to re-train my muscle memory away from using stuff like ls, cp, cd, was just a bridge too far, and so in the past I'd revert to cmd (as truly awful as it is) until I could get bash installed from Cygwin. They seem to have, somewhere along the way (again, it may have been a decade ago, for all I know) given PowerShell a reasonable UNIX shell facade. Sure, it's not quite shell, but bash/POSIX shell isn't flawless; I'm OK with changes, as long as I don't have to think every time I want to do basic stuff that I've been doing for 20+ years with a POSIX or bash shell. PowerShell has some Long-Ass-Command-Names, and I still find them difficult to stomach, but at least all the common sh equivalents (except which, for some reason) already have aliases. Anyway, the change from a company that tells developers how to work (and for whom the command line takes a back seat to GUI tools and most developers live in the Visual Studio environment, I guess) to one that looks at what's working in all sorts of developer communities and borrows liberally from the best of them, means that having to work on Windows is no longer the worst possible thing I can imagine (I'm even considering porting our products to Windows, which is a suggestiong I have laughed at numerous times over the years). PowerShell, as it is today, reflects that change, and open sourcing so much stuff lately seems to prove it is sincere rather than merely aping the most visible traits of these OSS communities without actually embracing the single most important facet of them. I still have an old OSS nerds suspicion of Microsoft, and I will probably never choose Windows as my favorite desktop OS (and I can't even imagine it for server usage...how would you even do that without a decent system package manager?), but my most recent experience with Windows was almost entirely positive. Interoperability has gotten pretty good. SSH is a normal thing, rather than a complicated setup process. It's interesting, to me, that Apple seems to have been retreating on these fronts. They seem to be less interested in participating in OSS than they were in the early days of Mac OS X. That may be my own ignorance of the platform, but I don't see Apple making these kinds of overtures to Linux/UNIX developers on such a regular basis. Maybe they figure the community is taking care of it for them, because so many devs use Apple laptops even while deploying to Linux servers, so the ecosystem is still pretty strong even without Apple doing much of the work.
- jasonjayr 10y agoHaving powershell + bash on linux lets me compare this way: powershell, 14 pids(threads?), 3119M Virt size, 80160kb Resident. bash, 1 pid, 22068kb Virt, 3976kb Resident. And this is simply starting the process to an idle prompt. This is on a Debian 8 64bit system. (using their Ubuntu 14.04 binary)
- UK-AL 10y agoPowershell is essentially running a JVM stlye virtual machine in the background though.
- riskable 10y agoI'm not a huge fan of PowerShell but you're not really making a good comparison here. Bash is "just a shell" that executes commands with a few bits of syntactic sugar here and there to make it easier to string those commands together and perform some primitive logic. PowerShell is basically an interpreter that works more like a Java Virtual Machine. Consider the hypothetical example that you need to lookup 100 users in an LDAP directory from Bash: You run the openldap command 100 times in a loop. That's 100 processes that need to fork and quit in a serial fashion in order to perform the task at hand. To do the same thing in PowerShell you'll be calling a native PowerShell LDAP API which will execute all 100 lookups without having to fork any separate process resulting in a vastly faster execution. It's better to think of PowerShell like the Python or Ruby interpreters. IMHO, PowerShell is a vastly superior improvement to cmd.exe as a shell but on a Unix host it will be inferior to bash for day-to-day tasks.
- jasonjayr 10y agoI fully agree -- they're two different animals. IMHO, it's a symptom of the two different paradigms of running a process on Windows vs Unix. I worry about getting out of the habit when scripting on Linux of forking off a new process for each iteration of a loop, rather than pushing the loop into powershell, for better execution.
- Grishnakh 10y agoSo I wonder how it compares to having the python interpreter open. According to my machine, running the python interpreter results in 1 PID, 129M virt, 4.6M res.
- trevorsullivan 10y agoYou can run PowerShell Core inside of a Docker container quite easily as well. https://channel9.msdn.com/Shows/msftazure/Run-PowerShell-Natively-on-Linux-with-Docker https://channel9.msdn.com/Shows/msftazure/Run-PowerShell-Nat...
- drux 10y ago"If Microsoft ever does applications for Linux it means I've won." - Linus Torvalds
- leoc 10y agoIf PowerShell on Linux takes off properly, then that will lead to one of the biggest improvements in the general computing ecosystem in a long time; roughly comparable to the adoption of DVCS, maybe.
- erikb 10y agoBut why? It's like if VW invents doors that can be connected to BMW cars. (spoiler: BMW cars already have doors)
- lottin 10y agoThis might come across as a little rude, but I really wish Windows developers stayed away from Unix. I moved away from Windows a long time ago because I didn't want anything to do with Windows or Microsoft, and I went to great lengths to avoid their software and their proprietary file formats. Now we had command-line interfaces, desktop environments, running on top of an incredible, powerful Unix-like OS. It was free software, and it was Microsoft-free. Please, don't ruin it.
- 2bitencryption 10y ago"Um excuse me, but I really like dogs. However, I don't like you, so I don't want you making movies about dogs. Dogs are my thing. Stay away from the concept of dogs."
- NovaS1X 10y agoI have to agree. I can only feel like this is pollution or another EEE attempt.
- Delmania 10y agoTell me how well EEE works with an optional application released on Github with an MIT license will work.
- xigency 10y agoGitHub is just the distribution here, and software licenses are subject to change. That's the embrace portion. Hypothetically, Powershell becomes widely used on Unix, and Microsoft releases Powershell 2, which extends Powershell. This version only runs on Windows and contains killer features. These new features can't be implemented from the GitHub source either technically or because of intellectual property. That's the extinguish step.
- Delmania 10y agoSo then you switch back to another shell?
- gargravarr 10y agoPowerShell is one of Microsoft's better offerings, it runs rings around Batch, thank heaven. However, it has its own quirks. Loads and loads of stuff done implicitly (unwrapping arrays as parameters when constructing an object?) and the .Net integration can be annoyingly flaky. Add in the bizarre syntax, some kind of halfway house between Bash and C#, and you quickly end up writing enough code to hang yourself. My favourite: defining functions more or less like any other C-inspired language: function abc([string]$param1, [string]$param2) { #do stuff } ...but if you CALL that like any other C-inspired language: abc("string1", "string2) PowerShell mashes the two strings together and ignores the second parameter. Drove me mad when I started out. Incredibly inconsistent. I like Microsoft's effort here, and the design is a lot better, working with objects, but not on my Devuan box!!
- hubert123 10y agoPowershell is a horrible abortion, what the hell do people see in it? I mean that on a language level, I cant speak for Windows specific features. I have once written a simple script to copy a folder recursively to a fileshare, rename some stuff, edit some files. Took me 4-5 hours. I then did it with julia in 30 minutes and I never did anything in either language before that. It's insane the kind of weird language crap you have to deal with, the weird options that some functions need and worst of all: That the functions have weird problems, like I dont remember the specifics but I'm pretty sure that the folder copy function had no option to actually recursively copy all of them. I had to work around that. Then I had to work around some more specifics around file/folders. In a normal language you would just call something like "copyFolder(srcPath, dstPath, recursive: true)" nope.
- reactor4 10y agooh man I agree with you so much. You can't do anything data intensive with powershell, it is too slow.
- mastry 10y agoI wouldn't go so far as to call it a "horrible abortion" - but it can be painful to use at times. I manage several Azure environments with PowerShell and not a day goes by that I don't wish there was something better. Especially on those days when I have to dig into Azure's JSON templates. There is an SDK for Python, but I haven't had an opportunity to try it. If anyone has used it I would love to hear about your experience.
- discordance 10y agoThere are the Azure REST APIs that you can curl. Or the Azure-CLI on Linux and Windows. That said, I've noticed that powershell seems to get priority with Azure support before the azure-Cli client, so there are a few gaps here and there. I've been told that the Azure REST APIs are all in step with Powershell support, but sometimes go in documented unfortunately.
- 10y ago
- partycoder 10y agoPiggybacking on this thread, I wonder if there's a robust PowerShell profiler out there.
- joeblau 10y agoIs there anything preventing Microsoft from putting a Linux shell natively on Windows? I'm sure PowerShell is awesome, but the DevOps person in me is not excited at all.
- jaykru 10y agoNot quite what you're looking for, but arguably better: https://msdn.microsoft.com/en-us/commandline/wsl/about https://msdn.microsoft.com/en-us/commandline/wsl/about Been playing with it ever since I got a new Windows laptop for college (I usually would have installed Debian but I prefer OneNote to notetaking apps on available on Linux). The interesting part is that it's not a VM; the LoW subsystem translates Linux syscalls to Win32 ones
- guitarbill 10y agothis x100. i wish they'd work on chef/puppet/ansible/salt support instead. probably never going to happen though, so much functionality in windows isn't available from the command line.
- jodrellblank 10y agoYeah, probably never happen. You'd never see J. Snover the 'father of PowerShell' at ChefConf last year talking about PowerShell Desired State Configuration (DSC) and its support for Chef (https://www.youtube.com/watch?v=Gh9zfm5gVEg https://www.youtube.com/watch?v=Gh9zfm5gVEg) or two years ago the PowerShell team announcing a DSC Cookbook for Chef (https://blogs.msdn.microsoft.com/powershell/2014/07/29/chef-with-powershell-dsc-now-public/ https://blogs.msdn.microsoft.com/powershell/2014/07/29/chef-...) or last year announcing Puppet's announcement of support for PowerShell DSC ( https://blogs.msdn.microsoft.com/powershell/2015/10/06/desired-state-configuration-puppet/ https://blogs.msdn.microsoft.com/powershell/2015/10/06/desir... ) You know that the entire point of PowerShell is to make Windows functionality available from the command line, for centralised management and configuration, for automated provisioning on Azure, right?
- guitarbill 10y ago
- treebeard901 10y agohttps://en.wikipedia.org/wiki/Embrace,_extend_and_extinguish https://en.wikipedia.org/wiki/Embrace,_extend_and_extinguish
- riboflava 10y agoThis could really be used as the default reply for a lot comments here that don't get why people are still a bit antsy about MS apparently doing things for the good of others besides MS. But it's probably an argument only worth having in one thread. I can't really add much to the argument, other than I think my feeling matches a lot of others in the OSS world: ever since Nadella took the helm I've been cautiously optimistic that we're not just part of a very long embrace+extend cycle that will end with a crushing extinguish, additionally as the years go by without an attempt at extinguishing but even more embracing+extending instead, with MS having lost so much of its former power and weight in the industry as a whole, I think even an extinguish attempt wouldn't be all that successful. It's not enough for me to actually use these offerings, but I'm not going to go on a rant that no one should use them or distros should avoid packaging them. (e.g. Stallman once had a Mono+Banshee rant that was probably justified at the time but it's hard to argue the position now.)
- qwertyuiop924 10y agoPowerShell is interesting, and I don't consider it evil. I know some people swear by it, and I am not one of those people - I'll take my AWK with a side of Ruby/Python, and a helping of SCSH, thank you very much. It does seem a bit out of place in a UNIX system, though. In Windows, PowerShell ties to a ton of strongly typed databases (SysReg, &c) and windows APIs together into a nice package. But on UNIXes, those APIs are already well exposed elsewhere, and that data doesn't exist. UNIX data is typically stored as text, or can be extracted as such easily. We don't tend to do a lot of binary object munging. I mean, maybe if it integrated with databases, it could at least be handly for dealing with RDBMS scripting, but those bindings are available elsewhere - ruby, perl, python, etc. And MS could build bindings to POSIX, so you'd get a PowerShell version of tools like PS that returned objects, but what are you going to do if you want to munge /etc/fstab, and, say, generate user accounts for all your boot filesystems? I could do that with a line of bash and a few lines of AWK. I don't know why I'd want to, but I could. So to conclude, PowerShell seems like a neat tool, but it was designed for an ecosystem that doesn't exist on the *nixes.
- allendoerfer 10y ago> In Windows, PowerShell ties to a ton of strongly typed databases (SysReg, &c) and windows APIs together into a nice package. […] > UNIX data is typically stored as text, or can be extracted as such easily. They could ally with the systemd folks in their mission to change that.
- kuschku 10y agoWhich I’d be very happy about – see also the discussion about getting the ip for an interface above.
- qwertyuiop924 10y agoAre you out of your mind? Or do you just not understand what you're saying? Adding an interface to PS to get this info natively is good. But Lennart has a magic ability to get everything wrong, and he's NOT messing with my fstab any more than he already has.
- rvern 10y agoComing soon to Debian: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=834756 https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=834756.
- henry_flower 10y agoFor Fedora 24 users: So some reason, the rpm that Microsoft provides doesn't list all the dependencies that it actually requires. What is even worse, the compiled binaries inside, require quite outdated versions of icu & openssl that are not available in Fedora 24 any more. What I've come up w/ to force poweshell to run: # dnf install icu lldb lldb-devel lttng-tools lttng-ust To view what we're still missing: $ find /opt/microsoft/powershell -name \*.so -type f | xargs ldd 2>/dev/null | grep not\ found libcrypto.so.1.0.0 => not found libicuuc.so.50 => not found libicui18n.so.50 => not found (libcypto* is openssl-libs package, libicu* is libicu.) Now, you need to manually download: http://archives.fedoraproject.org/pub/archive/fedora/linux/releases/17/Everything/x86_64/os/Packages/o/openssl-1.0.0i-1.fc17.x86_64.rpm http://archives.fedoraproject.org/pub/archive/fedora/linux/r... (Yes, it's Fedora 17 == 2012 (!), which is ridiculous.) http://archives.fedoraproject.org/pub/archive/fedora/linux/releases/19/Everything/x86_64/os/Packages/l/libicu-50.1.2-5.fc19.x86_64.rpm http://archives.fedoraproject.org/pub/archive/fedora/linux/r... and extract usr/lib64/* files from both rpms to, say, /opt/tmp/lib64. Then finally run: $ LD_LIBRARY_PATH=/opt/tmp/lib64 powershell PowerShell Copyright (C) 2016 Microsoft Corporation. All rights reserved. PS /home/hf> $PSVersionTable Name Value ---- ----- PSVersion 6.0.0-alpha PSEdition Core PSCompatibleVersions {1.0, 2.0, 3.0, 4.0...} BuildVersion 3.0.0.0 GitCommitId v6.0.0-alpha.9 CLRVersion WSManStackVersion 3.0 PSRemotingProtocolVersion 2.3 SerializationVersion 1.1.0.1 It's a very strange feeling to see "Copyright (C) 2016 Microsoft Corporation" in xterm, if you ask me.
- tux1968 10y agoThank you for taking the time to share all that work you did to get Powershell running. Your instructions work for Fedora 23 as well.
- voltagex_ 10y agoThe build scripts for PowerShell right now require an existing powershell binary to work. If I can untangle this and work out what's required to build from scratch, then that'll probably help you build a proper Fedora RPM. (I'm looking into it for Debian, but the work will help other distros, too).
- jijji 10y agoPowershell released in 2016 still isnt as powerful as Stephen R. Bourne's shell released in 1971.
- grobaru 10y agoMicrosoft is surely trying hard to get rid of its past. And they are doing it well. What I wish they would also do is that they would provide a minimal OS as a dev platform.
- l3m0ndr0p 10y agoOMG - Why? They should have kept this god awful language/environment to themselves. MS should just fork GNU/Linux and port all of their stuff over. Back to PS. Awful environment over all. It is better than CMD.exe. The language out of the box is limited and the syntax is verbose (those short cuts are crap too), compared to bash or any other Unix/Linux shell/languages. Remote execution of scripts is a pain in the BOOTY. YOu have to configure windows remote on the server you want to work on (pain in the booty). Unlike setting up .ssh and running commands. Handling error codes or error returns from scripts is also a nightmare and not consistent. Plus the naming of some of those functions is awful. GCI? Get-ChildItem, WTF does that mean? Oh... traverse a file/registry system? Some of the Excel like function are a nice to have. But when you have to parse strings and such I've run into issues where, the string shows up on the screen, but trying to Select-Object | select-String, only to return empty results, because I didn't get-member or something to see if I'm getting a generic object or a string. Pain in the ass. Bye - Peace.
- atmosx 10y agoI am still trying to understand if there are any tangible benefits on learning powershell over bash/zsh.
- sidereal1 10y agoI wouldn't think of it as a replacement for bash/zsh or other shells. Those are meant to control the OS and run programs where powershell is an environment to programatically interact with API's. They can both fill similar roles but their not the same.
- jitix 10y agoIn the fifth paragraph: "But this is a new Microsoft". They are acknowledging that they made mistakes in the past due to which the missed out big on the server market. As much as .NET is popular, it would have been a lot more popular (vs Java ecosystem) if they were OSS from the beginning. As primarily a Java developer, C# seems more elegant to code in. As they say - the first step to fixing a problem is admitting that you have a problem.
- tgarma1234 10y agoWindows can have a neat-o shell all they want but when you open powershell on a windows computer you still get the following when you try to ssh... so, not really seeing the point here: ssh : The term 'ssh' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the spelling of the name, or if a path was included, verify that the path is correct and try again. At line:1 char:1
- jaykru 10y agosee: https://github.com/PowerShell/Win32-OpenSSH https://github.com/PowerShell/Win32-OpenSSH. ssh is coming, likely in an official capacity in the future (this is an official MS group on github)
- hoverbear 10y agoWow your comment is bafflingly low quality and stupid. Perhaps you shouldn't have submitted it.
- guitarbill 10y agohe's not wrong though. ssh is the quickest way of accessing remove machines, not to mention secure (i have never seen remote desktop done with priv/pub key in practice). it also makes automation and transferring files easy. putty is terrible compared to ssh on linux. what i would have given for good ssh on windows back when i was still doing C#...
- jodrellblank 10y agohe's not wrong though. ssh is the quickest way of accessing remove machines Invoke-Command -ComputerName $ListOfComputers -Command {#code...}
- guitarbill 10y agoyes, yes, well done. how does this work with public/private keys again?
- tgarma1234 10y agoStill need something other than powershell to access a linux server from a windows machine, which seems ironic... ssh : The term 'ssh' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the spelling of the name, or if a path was included, verify that the path is correct and try again. At line:1 char:1
- ygra 10y agoWhat would a shell have to do with the existence of a userland program? ssh isn't exactly a bash built-in either ...
- KirinDave 10y agoPowerShell's object-passing approach ultimately is a heck of a lot more composable and reusable than the "blobs of text with AWK and SED magic" approach that its predecessors took. It's somewhat surprising to see people here arguing that the pure text methodology is superior. It's difficult for me to imagine a technically motivated scenario that is improved by having everything dump out inconsistently formatted and specialized plain text. Great example, ifconfig and netstat. Regular interfaces and an object model over these under the covers is a whole universe better than the ad hoc tabular formats they present.
- bitwize 10y agoGet-CobolFingers -Variant=Microsoft -Payoff=MuchLessThanAdvertised
- Senji 10y agoIt's better than reading regex linenoise.
- jodrellblank 10y agoGet-Cob{tab}{tab} -v{tab} M{tab} -P{tab}{tab} M{tab} cmdlet long parameter names both a) work if you type "the shortest non-clashing prefix", and b) tab complete. And if a parameter takes an enumeration you can tab complete those, too. Which is incredibly nicer than usage: somecmd -umhcglsrfmh line noise and man page lookups.
- NetStrikeForce 10y agoActually, you can ctrl+space in latest versions to get a list of parameters (or values if the parameter takes an enumeration) you can scroll around with the arrow keys :)
- elchief 10y ago`cat youCantBeWorseThanCmdRight.utf8.txt > openMeAfter.txt` in PowerShell and cmd, and tell me how good posh is now go tail a 1GB file in posh and bash and tell us your results
- ygra 10y agoPowerShell defaults to UTF-16 encoding, indeed. It's a design choice on a system that uses UTF-16LE as its character encoding and one from the early 2000s. UTF-8 wasn't nearly as prevalent back then. However, the text in both files is still the same. Get-Content -Tail some1gbfile.txt works quite well, by the way.
- elchief 10y agowell, enjoy typing Get-Content -Encoding utf8 .\utf8.txt | Out-File -Encoding utf8 out.txt and manually removing the BOM, for the rest of your life
- ygra 10y agoIt's still the same text. Not all of us have to deal with tools that can't handle Unicode or require exact byte-for-byte round trips. Yes, it bugs me too, from time to time, although less so than the extra line break at the end. In that case I have to go through [IO.File]::ReadAllText and ::WriteAllText and thus deal with full paths again. There are a few gotchas. However, by now we can actually fix that issue. The encoding parameter that the file system provider adds to a bunch of cndlets is an enum and we can add a new value there.
- NetStrikeForce 10y agoParsing text is unfortunately not one posh's strenghts... but one of the beauties of posh is that you can very easily include .NET classes, so you could e.g. use the System.IO.StreamReader class https://rkeithhill.wordpress.com/2008/03/02/nothings-perfect-including-powershell/ https://rkeithhill.wordpress.com/2008/03/02/nothings-perfect... On the other hand, with posh I could ingest a json file and convert it into an object (or an array of) with ConvertTo-JSON. Once I've got the object, I can query/navigate it instead of parsing it. I'm not sure it is that easy with bash, but then again they are not mutually exclusive, so it's great to have both now on Linux and on Windows.
- Pxtl 10y agoI just spent all day trying to figure out why Invoke-SqlCmd only works in certain extremely convoluted ways. I'm going to assume this has more to do with the Sql Server team than it does to do with the powershell team, but still: I cannot be excited about anything to do with Powershell since I'm now up to like 10 Googles per line.
- coldtea 10y agoA lot of people seem to be missing the point of PowerShell. The concept is far more poweful than the unix shells, because it's a superset of them. It's like Haskell and Haskell-without-types. We could only dream we had something like strongly-typed pipes in Unix -- and that various tools supported it too.
- tossaway42 10y agoI dreaded this day would come. As a recent ex-Microsoft alumnus, and with years of System Center insanity behind my back, I saw this coming, and even heard faint echoes of it in the hallways as I left. I have deep respect for Jeffrey and what he's accomplished (there's a great video of Jeffrey talking to Linux sysadmins and explaining the genesis of PowerShell, including the insane amount of money we burned before he wrote the bits that actually worked over Christmas break), but the grand (corporate) motivation for sponsoring something like this is more driven towards making sure the MS datacenter management tooling (which comprises trendy things like OMS and System Center) attain minimal mindshare in both the on-premises datacenter and on Azure. That is not something most people would care about, but Enterprise IT likes having a single hammer for all its nails, and PowerShell's promise is to be the one thing that your garden variety IT sysadmin would love to use to automate every single system in your company. Ironically, PS is effectively lousy at automation because of its inconsistent error handling and incredibly hard to maintain over time due to constant changes and updates, so I'm curious to see how it will evolve to manage all the different abstractions in the UNIX world (knowing my former colleagues, it will likely follow the OMS route of "Windowzifying" those abstractions and making them "uniform" - i.e., Windows-like). The underlying issue where it regards PowerShell is not the language itself (although yes, something better, more coherent and with an actual standard library would have been nice, like Ruby or Python). It's Windows. Windows (the enterprise platform) has always been a hectic patchwork of multiple components (AD, SQL, IIS, etc.) that evolve at their own pace, and PowerShell grew to encompass them not merely because basic automation was an actual checkbox we had to have to be able to sign some hefty deals, but, technically because _none of it had open APIs_. Nor would it be feasible at the time to go back and re-do any of it with proper language-agnostic APIs. It's very nice to iterate over AD entries and set some fields with a couple of lines of PowerShell, yes. But it's also fundamentally impossible to do so with just about anything else. Tying it all to the .NET stack (which is still prevalent in everything done internally, because that's what customers invested in) turned out to be a lazy-ass way to ensure we could check all the boxes in terms of automating new things as they came along (mostly - WMI is still iffy). Effective and "scriptable", but essentially still proprietary. And right now, since my former colleagues are betting the farm on Azure, I expect PS for Linux to become the de facto scripting language for managing Linux on it (it already is, to a degree, since PowerShell DSC already lets you "manage" Linux VMs). For interactive use, PS was a pain to learn (I was a VMS guy, originally), but, most importantly, it was a nightmare to maintain, because cmdlets would pop up and disappear between releases, change semantics, and were quite often inconsistent among themselves. I shudder at the level of technical debt would-be adopters will be buying into, and wish them luck.
- codeulike 10y agoThe initial release is an “alpha” and is community supported. In the future, we will deliver an official Microsoft released version of PowerShell based on open source to anyone running a supported version of Windows or nix. The timing of the official Microsoft version will be based upon community input and business needs. We hope all of you will help us get it right! 'Based on business needs' = if there's ever enough demand. Still, pretty cool.
- prewett 10y agoI don't understand Microsoft any more. They are making all their proprietary lock-in stuff open source, and they are alienating their user base. I've heard a number of long-term Microsoft users express frustration the user experience (not to mention the Windows 10 upgrade shenanigans). It was bad enough that my dad, a long-time lover of Windows NT (he liked its VMS legacy) switched to a Mac and loves it. I feel like Microsoft might be pulling a Sun here. However, I'm sure a lot more likely to use Microsoft stuff if I'm not tied in to Windows.
- snaky 10y agoThe main fallacy is to think someone can 'understand' any big corp. Especially Microsoft - http://www.bonkersworld.net/organizational-charts/ http://www.bonkersworld.net/organizational-charts/
- Frondo 10y agoAs a counterpoint, I've been a full-time Linux user (desktop and server) for well over 10 years, with server use for 20. (I'm 40, so while others have used Linux/unix longer than me, this is the entirety of my adult working life.) With the open-sourced .NET stuff, I've been active in pushing for projects I touch to use it. And, I now dual-boot Windows 10 and Linux, actually using Windows for daily work for the first time in a decade. Open source C#? Sign me up. And I really do like the Windows 10 interface. The telemetry stuff just doesn't bother me. I think it's largely a red herring. (And, furthermore, I think privacy stuff really has to get nailed down in laws and society, not just with technology. Going just for a technical solution means you'll always be chasing the answer. Encoding it in laws, and setting people's societal expectations, means you get to set the answer instead of follow behind.)
- herbst 10y agothey just try to get some developers back on board. Did not sork out so well so far i guess.
- deleted 10y ago[deleted]
- randyrand 10y agoIt's amazing what happens when a company starts to lose market share, isn't it?
- be5invis 10y agoOK, so you can finally fix the bug that breaks non-ASCII, LF line endings and binary redirection. Link: https://github.com/PowerShell/PowerShell/issues/1908 https://github.com/PowerShell/PowerShell/issues/1908
- MichaelMoser123 10y agothe Unix shell has been quite static in recent decades; its a sign of success, sharing unstructured text through a pipe is good enough for most administration tasks and people got used to the many command line options of grep/sed/ps and friends. is this really the best of all possible worlds? I think that its good that the shells get some new competition in the form of PowerShell - maybe some new ideas will come out of it (maybe like passing s-expressions or json around the pipe - something more structured so that we could do with fewer command line options - maybe) doing structured data 'right' is difficult (right meaning uniform and expressive ways of handling it); historically it was easier to stick with unstructured text - but maybe there is a better way that would be easier to learn and handle. (Well a major problem of structured data is that there are many possible ways of structuring - leading to more problems for the consumer of the data; maybe it was not adopted in system administration because there is not common/agreed upon culture of how to structure things).
- brbsix 10y agoAn (unofficial) PowerShell AppImage is now available for anyone interested in trying out PowerShell. No installation necessary. https://bintray.com/probono/AppImages/PowerShell#files https://bintray.com/probono/AppImages/PowerShell#files
- youdontknowtho 10y agoI have to admit, I just came here to read the hate. I've gotten to where I almost always hide Microsoft related posts because people are so emotional about them.
- gsmethells 10y agoHaving lived around the Windows world since Win 3.1, I cannot get over the sneaking suspicion that somewhere deep down Microsoft is working towards an attempt to "embrace and extend" Linux. Maybe it's just me, but they've gotten rather interested in Linux lately and they are reaching out to it in seemly innocuous ways. I hope I am wrong.
- puppetmaster3 10y agosymbolic soft link yet?
- pagade 10y agoIts not clear to me what this means to Powershell SDK? (https://technet.microsoft.com/en-us/library/ff458115.aspx https://technet.microsoft.com/en-us/library/ff458115.aspx). Will I be able to write applications (not scripts) in say C++ to communicate to say SCVMM?
- ed_blackburn 10y agoI'm something of an OO zealot and I'm a C# developer so I'm familiar with PS and probably it's target audience so to speak. PS is a fantastic product but I just find it too verbose. When everything is expressed as an object with properties you need to reference the object and the appropriate property. I know there are alias' for common Bash operations and idiomatic PSallows shortcuts but most people who use PS for short spells to automate something are unlikely to be adopting idiomatic styles. For PS to gain traction I feel like it needs to be a superset of Bash and offer an easier, intuitive gateway. I know it has enormous potential, I know it has massive capabilities but still I only reach for it as a last resort. I don't think I'm alone in the matter :/
- coding123 10y agoOn the Java side here I tend to use groovyConsole when I need to do crazy one off stuff like open excel files which then require a DB query, and maybe to run regexs for little things. I use bash for running docker commands in a specific sequence.
- xyzxyz998 10y agoI don't want to be that smug ITT guy but it has to be said: Bash != Readline and Bash != coreutils and Bash != (what gives your machine the ability to do ssh) Bash is the stupid if for while syntax You have Readline in powershell and you can use coreutils binaries in Powershell. No problems there.
- gbraad 10y agoI made a Docker container running PowerShell on CentOS7: http://github.com/gbraad/docker-mono http://github.com/gbraad/docker-mono Have fun with it...
- Corrado 10y agoI think PS is miles above CMD but there are still things that bug me. For one, loading scripts into the current session is super confusing to me. Sometimes they are automatically available, other times I have to load them, still others aren't available at all. I'm guessing there is some way to "install" scripts so that they become cmdlets but I don't know what it is. Another big problem I've had is backgrounding commands. There are multiple ways to do it and I always seem to pick the wrong one. For example, I want to install a bunch of things with Chocolate so I do a lot of Start-Process commands, but they seem to run serially and not in parallel. It's just very difficult to manage jobs in PS, or at least I haven't found any good information on how to do it properly.
- garaetjjte 10y agomilek7: ~$ time powershell exit real 0m3.323s user 0m4.140s sys 0m0.507s Seriously?
- garaetjjte 10y agoPropably bit unfair comprasion, but...: milek7: ~$ time bash -c exit real 0m0.009s user 0m0.007s sys 0m0.000s