Thinking out loud

Find out what’s on our minds and tell us what’s on yours.

Fred Boyle // January 25, 2012

EE upgrade script

It’s not a magic bullet and still requires some manual intervention to complete an upgrade/update.

So what does this little script do?

It will back up some of your current installation’s files, create a new system folder, copy the new and backed-up files to the new location, and link your system folder to this new location. This will save you time and hassle, and keep it easy to roll back to the previous version if something goes wrong.

Before I get into all the technical aspects of the script, a bit of warning: Using this script does require shell access to your hosting environment and the ability to create folders above your public folder/document_root. You should be comfortable navigating the shell and command line.

I also want to give some credit to Mark Huot since the folder structure used is based on content in his Securing ExpressionEngine 2 book.

The folder structure

So let’s start by looking at the folder structure that makes all this function.

  • ee – this is the symbolic link to your EE system folder, in this case the ee2.4.0 folder
  • ee_upgrate.exec – the magic script
  • ee2.4.0 – the EE system folder
  • htdocs – the public folder (document root) for this site. Depending on your host it may be named public, httpdocs, or something else
    • cp – the placeholder folder for CP access (there’s no need to use this, it’s just how we choose to do it … the admin.php file is sufficient)
    • images – the EE images folder
    • index.php – the EE index file
    • themes – the EE themes folder
  • libs – this is where I store my custom PHP classes and additional code
  • src – where I keep the ZIP files for EE and temporarily unzip them (more on this later)
  • templates – my EE template files

Using this approach, it will become easier to find what you need and keep your files separate from the EE core. Don’t forget to update your config file with the proper paths for system and template files.

This folder structure also improves security by keeping your core EE files outside of the publicly accessible folder. This helps prevent accidental access to your config files and other bits such as any custom code or SQL in your templates. To learn more about this approach and why it’s a good idea, check out Mark’s book or this article on EE Insider.

The upgrade process

So here we go, the upgrade process.

Step 0
Back up your EE database.

Step 1
Download the new version of EE and upload the ZIP file to your SRC folder.

Step 2
Log in to the shell for your site and unzip the EE ZIP file you just uploaded.

Step 3
Make sure the ee_upgrade.exec script is set to executable (chmod 755).
Run the script like so:

./ee_upgrade.exec <relative path to unzipped EE folder> <relative path to current EE folder> <name of new EE folder>

Example:

./ee_upgrade.exec src/ExpressionEngine2 ee2.3.1 ee2.4.0

This will upgrade using the new files in src/ExpressionEngine2. Copy the needed bits from the ee2.3.1 folder into the new destination folder ee2.4.0 and link the ee folder to the ee2.4.0 one.

Step 4
Follow the usual upgrade process as described in the EE docs beginning at “Run the Update Wizard”.

Step 5
Enjoy your upgraded site!

Download

NOTE: Use this script at your own risk. I make no guarantees and cannot be held responsible for any issues or loss of data.

Download the script

Also included is a simple build update script as a companion. Leave a comment with any feedback or if you run into any problems, please use Twitter (@fredboyle) to reach out to me.

Russel Quadros // January 20, 2012

Rounding Out a Dozen

It’s exciting to join a team I’ve long admired and respected. Yes, I’m the newest member, an even number 12 to be exact. How I got here is really a cliché of things just falling into place. Late last year I found myself at a turning point in my career, where I had to find a new job and figure out what path would help me grow in new ways. After a short but hectic job search, I got to chat with Carl, who let me know that the company was growing, they needed expanded capabilities and that there was a place for me. Seeing that I’ve been friends with the company and team for years, it was an opportunity I couldn’t pass up.

Prior to starting at nGen, I spent my entire full-time career dedicated to one full-service branding & advertising agency—a solid 12-year stint, working up from a Jr. Art Director to VP/Design Director, enjoying all the highs and lows that the industry and economy had to offer. During that time I wore a lot of hats and picked up a variety of skills … the main one I left with being laser-focused on visual branding—which landed me at nGen as “Concept & Executioner.”

So what’s with my title?

I get to make up my own title! So I know what you’re asking yourself, “Why didn’t I call myself ‘Super Awesome Majestic Design King Of All That Is Amazing And Glorious’” … well, for starters, it’s too long. :-) But seriously, I found that given the chance to give myself my own title, I was stumped beyond belief. As a designer, I know my skills and what I’m capable of, but how do you sum it up in a couple of words? There are tons of Art Directors, Senior Designers, etc., out there … but their titles don’t necessarily reflect who they are or what they really do. So needless to say, it wasn’t about coming up with a cool name, but instead a little introspection.

Sooooo, again, what’s with my title?

Like a lot of designers, I’m a little OCD when it comes to design. Not just the practice of crafting and creating, but more so the process that leads up to it. At a time where design struggles with being considered a commodity, it’s crucial to me that we place more emphasis on unique solutions that tell an honest story. Not just creating a logo, a website, a package, but instead understanding the challenge a client faces and producing ideas to rival the issue. The beauty of being a designer is that you can immerse yourself in your client’s business and industry. I equate it to being a method actor, molding your perception to that of the audience you’re trying to reach. That kind of research and understanding is what really inspires good ideas and produces work that fits the client’s brand. From there, the creating comes naturally. And I’ll always be a designer—a maker of things—but how I achieve those things is only half the story. So, that process, in its simplest form, is “Concept & Execution.”

Now what?

Now it’s about living up to the hype. Getting the job is one thing. Keeping it is another. I guess that’s where I can really even things out.

Rachel Gertz // January 13, 2012

Well Lookie Here, Another nGeneer

Greg Aker knows how to make leather look good.

It’s a new year and a chance to do great things. Time to beef up our nGen a little with a brand-new teammate.

Introducing Greg Aker, our latest nGeneer! 

A talented back-end developer and ExpressionEngine heartthrob, Aker comes fully loaded. He’s got a firm appreciation for Python and PHP, has worked with the industry’s best—including being on the ExpressionEngine development team—and he plays a mean jazz saxophone. What more could a distributed team ask for? 

We just hope Greg realizes that by default he’s officially nGen’s new Gofer. Thank god, I was getting sick of shipping coffee halfway across the continent.

It’s great to have you aboard, sir!

Older posts »