Earlier today, Juan Treminio sent out this tweet, and I injected myself into the conversation.

The short and the long of it was Windows hampering web developers because of some lacking functionality, namely Linux file permissions, a proper CLI, tooling, etc. Linux and OSX have great tooling and setups that are familiar to developers, and Windows falls short.

I respectfully disagree with Juan on this. I've been working as a web developer on Windows for years, though I will gladly admit that there are things that I miss from Linux and OSX (and I'd even go so far as to say I'd rather just use Linux than OSX for general web development). Of course, I run Linux servers and am a Linux sysadmin, and I have a MacBook Pro. I don't consider myself a fanboi of any OS (and not that I think Juan is one either).

In an effort to show that Windows doesn't really have as many shortcomings as it seems, I'll document my setup and pitfalls that there are.

The Command Line - Powershell

I spend most of my time in Powershell. It's always open. Now, I'll admit that Powershell is not anywhere near as nice as an actual Unix terminal, but most of that is because of the way that it handles text selections, and it's inability to actually go full screen. This does not hamper my ability too much and there are ways to make it better, which I've done.

First and foremost, I install git from http://git-scm.com/ and let it add itself to my path. I don't add the full GNU toolset, just git and it's associated stuff. Now I can use git from Powershell just like Linux and OSX. git clone and all the git functionality is there.

I usually add the bin directory of git to my PATH after, this way I can get ssh access directly from Powershell. You may get some weirdness SSHing some servers since Powershell (and CMD) act slightly different than a traditional shell, so keep that in mind. I've seen apps like vim or screen not behave correctly as Powershell doesn't handle resizes or screen clears properly through SSH. It's minor, but it can happen.

Part of the reason OSX and Linux have such a great command line experience is not completely because of the terminal itself, but because of the tools behind it. Unix operating systems tend to ship with either a BSD or GNU suite of tools like grep, sed, awk, etc, that make working with text files and the system much nicer. Powershell does have some of these same things built in, they just aren't named the same. They also work a bit differently than GNU/BSD toolsets, so I normally install GnuWin32.

There is also cygwin. I have a love/hate relationship with cygwin. Most of the time I end back up at Powershell. You might try it out, but don't think it's the end-all-beat-all of terminals on Windows.

I would also recommend learning Powershell in general. It can do many basic things that are found in the GNU/BSD tools, like grep. The commands are just different. When in doubt, google for it and you'll probably get something back. Worse case, use GnuWin32.

As for other Powershell goodies, look into extensions like posh-git. This makes working with git in Powershell much nicer. There's a ton of extensions available for PsGet, so I would browse it's directory for things you might find useful.

Using PHP

There is a lot of things we do as PHP developers that are just glorified PHP scripts. PHP has had native Windows builds for a long time, and it generally works just fine. Head over to http://windows.php.net/, download the latest Non Thread Safe version, extract it somewhere (like c:\php56), and append it to your PATH. You now have PHP available in Powershell.

If you need to modify it, copy a version of the php.ini that the download has and enable different extensions that PHP comes with by uncommenting them.

If you need an extension that doesn't ship with PHP... you might be out of luck. If you need to compile extensions on Windows manually you're going to need Visual Studio, all the correct libraries, and some crossed fingers. Most of the projects I work on generally do not cause me to need to install extensions in Windows directly, most of them are running in vagrant.

Most PHP scripts work just fine in Powershell using PHP. I use Composer all the time, and even the Sculpin phar works. drush used to have some issues but it's rare whenever I'd run that directly under Windows. Your mileage may vary.

IDEs and Text Editors

Time to start the flame wars.

For Windows, my two go-two things to write code are PhpStorm and Sublime Text 3.

I use PhpStorm only because it works well for what I do. Getting xdebug to work with a vagrant box is normally easy, and it has a lot of conveniences that work for me. There isn't anything wrong with other IDEs like Zend Studio, I just like PhpStorm better.

Sublime Text does have a release cycle that is outpaced by glacial movements, so I've also been looking into Atom and Visual Studio Code. Atom is OK, but I find it stalls pretty frequently and is very CPU heavy no matter what I'm doing. Visual Studio Code is nice but exists in this weird area where it's more than a text editor but not a full IDE for PHP, so it lacks. Neither handle huge files well, so I keep coming back to Sublime Text.

I will say that, while I love vim, it's not so great on Windows, so I don't use it there. I use it all the time on Linux and OSX though, but the Windows experience isn't there. Sublime Text is miles ahead.

Development Stacks

It's vagrant. There's nothing special there. Since I have git and SSH available through Powershell I can use vagrant ssh, but vagrant has always worked well for me under Windows. My only complaint is only having SMB mounting support for shared volumes. NFS doesn't work, and I've never gotten vagrant to recognize when I have rsync installed.

Install Virtualbox and vagrant like normal. Develop like everyone else. When you have stuff that needs to run under Linux, SSH into the VM and do it there. This is not any different than when I work on Ubuntu or OSX. I do almost everything for my project inside the VM, even if I have everything installed in the host OS.

If you really want to, you can install your database locally and use IIS Server. There is nothing wrong with that, especially since IIS 7. PHP works great with it. I don't deploy to Windows though, and vagrant is pretty much the standard nowadays.

Don't use a *AMP stack like XAMPP or WAMP though. They won't replicate developing on a Linux machine and can have their own weird quirks. Just use vagrant.

Other Random Stuff I use

The above takes care of almost everything I do day to day. I use HexChat for IRC, which connects to a ZNC server sitting on an Ubuntu box. I use the venerable PuTTY when I need a better SSH client than Powershell. Slack has a Windows client now, so I'm connected through the various Slack teams I'm in. I still use FileZilla (the version without all the crapware) when I need a graphical interface for FTP or SFTP.

And I'm Happy

That's about it. I spend almost all day in Powershell, PuTTY, and PhpStorm and I get all my work done without any hassle. It's not Linux, and I'd rather run Linux 24x7 if I could, but I don't. I can, and sometimes do for short periods of time. When I travel, I take a Macbook Pro with me because it has way better batter life than most of the Windows laptops that I've had.

I know many PHP developers that happily use Windows as well. It doesn't make us any less productive as developers. It doesn't make us any better as developers either. Every developer finds a toolchain and workflow that works for them. This is my Windows toolchain. I hope whatever toolchain you use works well for you.

In honor of the 20th birthday for PHP, my good friend Ben Ramsey has been asking people for stories of how they first got into PHP. It's hard to think that I've been doing PHP for more than ten years at this point, and that is only half of the lifetime of PHP itself.

I myself got into PHP development when I was working for a local ISP in Northwest Ohio. I'd been doing HTML for many years before that since middle school, and had been doing static websites for friends and family up until that point. I'd dabbled a bit in Perl when I had to start working on a shopping cart/ordering system for a family friend for his business. Suffice to say, I wasn't terribly happy with Perl. Deploying was a nightmare.

I was introduced to PHP by Matt Wiseman, who was a coworker. He had me take a look at phpSlash and suggested that I look at this PHP thing. While I never actually did anything substantial with phpSlash, I did start looking at PHP more closely.

Since then I've obviously managed to make a career out of using PHP. I've made countless websites and applications, built so many horrible frameworks and libraries, and made many mistakes along the way. I've also made friends with so many people in the PHP Community, and I wouldn't be here without all of my friends and the family that is the PHP Community. I get to work with a language I love, on projects that I find challenging, and with people that are awesome.

Here is to 20 more years.

When I started working with PHP, it was because I was fed up with Perl. I had been building HTML websites for quite a while at that point, and I had already been interested in programming in general. Perl worked, but as anyone who has done work with Perl knows that the syntax is, well... it's Perl. I was working at a local ISP at the time and one of my coworkers, Matt Wiseman pointed me to PHP, so I started to look into it. I liked what I saw.

Like many developers I worked in a bubble for many years after that. I stuck around at the ISP for about two more years before moving on to a job that was dedicated to web development full-time (well, mostly). While it was an insurance company, they were one of the few smaller ones that had a dedicated development staff. Insurance has a history of continuing education, so one of the perks was attending training. Northwest Ohio itself is pretty technologically devoid, so I had to look around. I attended a SANSFire conference in 2007 since we used SANS for much of our security training, and LinuxFest Ohio that year as well.

In 2008 I discovered php|tek. I had never attended a conference, and I'll admit that I did php|tek 2008 wrong, just like I did SANSFire and LinuxFest Ohio. I went to the sessions, made small talk with people, but didn't really interact. I didn't know these people. I didn't talk to anyone on IRC, Twitter wasn't really a thing, and at best I matched names up to some blogs that I read.

I had a good time, don't get me wrong. I learned a lot. I attended Zendcon that year as well, and I decided to not spend as much time in my room. I met more people, with one of them being Michelangelo van Dam, not suprisingly. I'd started a programming blog, and I had began to find more people in the PHP community through Twitter and IRC.

I went back to tek the next year. There was Michelangelo again. Elizabeth Naramore, whom I had never met in real life, recognized my IRC handle from #php despite me doing nothing more than lurking there. There were other people I'd seen at Zendcon. I met more people. I got introduced to the #phpc channel on freenode, and I started following more people on Twitter.

I had unknowingly taken the advice I'd hear five years later from Yitzchok Willroth/coderabbi, which was "Do not separate from the community."

At Zendcon 2009 I was invited to my first non-official party, held by Microsoft. All because I wanted a shirt, and had managed to ask Josh Holmes for one. Michelangelo talked me into submitting to conferences. When tek rolled around in 2010 I don't think I submitted. I didn't feel like I was ready. That was actually a good thing, because my employer decided to cancel my trip to tek so I could travel Ohio and present some stuff we were working on. I started submitting with Zendcon 2010 (I think).

I didn't get accepted. I attended though, and met more people, and tried to be a bigger part of the community. I continued to blog and network with people at conferences because there wasn't anyone locally. I could already see myself becoming a better programmer because I had surrounded myself with people smarter than myself, and people that faced the same, yet different problems. I could bounce ideas off of people. I was exposed to what other people were doing, talking about, and working with.

I grew as a developer.

In 2011 I didn't get accepted to php|tek, but I did get asked to write an article by Elizabeth Tucker Long for the php|architect magazine. I really enjoyed working with her, and have been writing for the magazine ever since, and working with her on other things, but it was through the community that I began to write slightly more professionally.

It took me two years to get accepted as a speaker, but Kevin Schroeder liked one of my talks so I got to speak at Zendcon 2012. That helped boost my confidence immensely, and I also caught the speaking bug.

Since then, I've attended many more conferences. I've met many great people. I've met lots of people that I consider my friends. Going to conferences and being part of the PHP community led me to get a contracting position with The Brick Factory in Washington, D.C., because I had met John Bafford at tek one year, followed him on Twitter, and noticed him post a job. I'm assuming he didn't actually look at my Github profile before he offered me the job.

A few years later another member of the community, Chuck Reeves and I met and have become friends, and it's through meeting people through the community and conferences that this month I'm moving on from The Brick Factory to working with him. I'm chalking that career move to the delirium caused by standing in line for 8 hours waiting for hotdogs with Chuck, Jeremy Mikola, Drunk Phil Sturgeon, Sober Phil Sturgeon, Daniel Cousineau, Matt Frost, David Buchmann and Sammy Kaye Powers though. #wurstcon was a trip I would have only made with the PHP Community.

At php[world] 2014 I got to watch as new people were brought into the PHP community, all because they were standing outside when we were figuring out cars for #koshercon (and that whole inclusive, very friendly conference thing put on by php[architect], that probably helped as well).

Growing from a lone developer at a small Ohio insurance company to the developer that I am today, the PHP community has been there, helped me, and provided opportunities I never would have gotten otherwise.

I've mentioned only a fraction of the names above of the people that are a part of the community, and it would be impossible for me to list all of them. I'd thought about it, but it's easier for me to just say look at the people I follow on Twitter, and see the people that hang around in #phpmentoring, #coderabbi, and #phpc on freenode.

If you are a PHP developer, make sure you are a part of the PHP community at large. Attend conferences, attend a local user group. Meet people. Find a group standing around talking, and walk up to them. Say hi. Join an IRC channel.

In closing, I just want to say Thank You to the PHP Community at large. I wouldn't be here without you.