When I advise people about upgrading their PHP version, I say things like "just run your test suite with the new version" "just grab the new version and try your site with the built-in webserver". A couple of people recently have asked for more detail on how to actually achieve these things so here's a quick primer on getting new PHP without touching anything to do with your existing PHP installation. Continue reading
Like most PHP developers, I'm polyglot. My PHP project builds with phing, but uses a bunch of npm tools along the way to minify assets and those types of things. When I introduced TravisCI into my project, I was instantly confused by the requirement to specify the technology I was using ... all of them, surely?
In need of wisdom and advice, I turned to the best source I know:
How do people use @travisci with multiple languages? Project uses PHP and nodejs tools but I can't seem to configure both. Any links/advice?
— Lorna Mitchell (@lornajane) May 7, 2014
I am delighted to announce that I have new video titles available! I'm delighted for two reasons: selfishly, because these things take a lot of prep and I am pleased they are done; but also because I think it is very good news that a key industry player such as O'Reilly recognises PHP's place in the world and works hard to publish new content in this area.
There are two videos available: PHP Web Services and Intermediate PHP (subtitle: a bunch of things Lorna thinks will make developers' lives and applications better!), you can click through (disclaimer: affiliate links!) to get more information and a detailed chapter outline for each course. I hope that either or both of them will be useful to you. Continue reading
I have been doing more screencasting lately, so I thought I'd share some recipes here, for my own future use and in case anyone else wants to use them. I capture my videos using Kazam on Ubuntu, usually by resizing my second monitor to 800x600 and then capturing that. Kinda eye-bleeding to record but looks good in playback and also works well either in tiny web view or on a big screen. I also screencapture my android device and for that I use Screen Recorder.
We've started using Travis CI on one of my projects to run some build processes to check that everything looks good before we merge/deploy code. One thing I ran into quite quickly was that I wanted to install phing in order to use the build scripts we already have and use elsewhere, but that it isn't provided by default by Travis CI.
Right now I'm working on an application which is experiencing lots of interest - and therefore lots of load! We needed to look at ways of trying to bring down the pressure on the servers, and decided to use a CDN (Content Delivery Network) for our image files. It was surprisingly painless to implement once I got into it so here it is in case it's helpful. Continue reading
When working with curl, it can give lots of excellent and detailed information, but sometimes it is too much! Today I'm fiddling with the caching headers on a client's application, so I'm only interested in seeing the headers and not the body of the response. Making a
HEAD request changes the output I get, so I really do want to
GET and then only see the headers.
Handily, when you use the
-v verbose flag with curl, it sends the output to stdout as usual, but the extra information including the headers goes to stderr. This means that I can therefore view the headers only throwing away stdout completely:
curl -v -s http://awesome-site.com 1> /dev/null
(you need the
-s to stop curl from "helpfully" printing progress bars as well)
Here's a little demo video that I put together to explain pushing/pulling with multiple remotes and how tracking branches make this easier. It's one of the chapters from my "Git Adventures" talk, but it didn't make it in to the talk in Amsterdam last week since we chose a different adventure that time - sharing it here in case it's helpful to anyone else, and so I can find it later!
I also blogged about the tracking branches in a bit more detail if you're interested.
Here's a topic that took me a while to understand in git, and now (I think!) I do, I thought I'd write it all down while I can remember!
Some branches in git (such as your origin/master branch) will usually track the remote branch that they are related to. But what if you want to create a relationship between local and remote branches? Or stop them from tracking? Here's some pointers Continue reading
The joind.in projects are set up so that the build process runs on pull requests when they are opened, which is great! It means that contributors don't have to wait for one of the maintainers to look at it, only to reject the contribution on something that could be picked up automatically. I've had a few questions about the setup so I thought I'd share how it works. Continue reading