Upgrades made easy with Laravel Shift

Ascend
4 min readAug 20, 2023

--

https://laravelshift.com

With Laravel’s annual release of a new major version, some can be forgiven for struggling to keep up. If all of a sudden they find themselves a couple of versions behind, updating and upgrading goes from being a time-consuming task to something they don’t even want to consider.

Each new iteration though offers richer functionalities, optimisations and security enhancements. Failing to update not only starves the application of these benefits but the developers powering the solution too.

We recently had a customer come to us with a number of Laravel applications, 5.8 being the furthest back (some 6 versions old), and another one being Laravel 7.0. Part of their brief to us was to upgrade these applications as-they-were (functionality wise) but running on PHP 8.1 and Laravel 10.

Where do you start?! Not only is there Laravel considerations to make but PHP ones too. ^7.1.3 was the PHP version denoted in the composer.json file of Laravel 5.8.

Enter Laravel Shift: a tool that markets itself as alleviating upgrade headaches. We thought it worth a try, here’s our review.

Understanding the upgrade challenge 😰

Before evaluating Laravel Shift though, it’s worth addressing at a basic level why Laravel upgrades can be challenging for some.

Sidebar: We have always found every Upgrade Guide accompanying new Laravel versions consistently proves informative and beneficial. The guides thoughtfully categorise changes based on their potential impact and even provides a time estimate upfront for the entire upgrade process. Certainly for us, there’s no reason to view the manual upgrade process as intimidating.

Deprecations

Over time, some methods and functions get deprecated. An upgrade means ensuring your application doesn’t rely on these deprecated functionalities.

Compatibility checks

Each Laravel version might come with its own set of server requirements and extensions or packages that might not always be compatible with your set-up out of the box.

More recently, these changes have also involved directory movements too that need to be considered.

Missed features or changes

Manual upgrades means taking the time to go through Laravel’s upgrade guide. It’s easy to overlook a subtle change that might impact your application or view that as too time consuming when also developing other features that qualify as paid-for work.

Laravel Shift to the rescue 🛟

Laravel Shift is an automated platform that upgrades your Laravel applications. It reviews your project’s source code and provides a pull request with all changes necessary for the upgrade.

How does this automation help?

Efficiency

Automation inherently speeds up processes. In our look ahead article for digital trends, Artificial Intelligence (AI) and Machine Learning (ML) feature at number one for us of things to look for.

What might take a developer hours, days or even weeks to complete, Laravel Shift accomplished for us in less than an 40 minutes.

Accuracy

As humans, we’re prone to error. We might miss something simple — a deprecated function or overlook a change in the documentation. Laravel Shift’s automation minimises these oversights on your behalf.

Insightful comments

Along with code changes, Laravel Shift provides comments explaining the changes its made, ensuring developers aren’t left in the dark about why a particular modification was made.

How many previous Laravel version updates have we seen one large pull request entitled simply “Upgrade to Laravel X.X”, with almost little to no context.

Cost-effective

If you consider the billable hours saved with such a small investment asked for, using Laravel Shift is a cost-effective solution in our mind over the long term.

It reduces the time developers spend on upgrades, allowing them to focus on more intricate work, feature developments or other pressing tasks.

Shift over to other tasks

Laravel Shift isn’t limited to Laravel upgrades. There are shifts for upgrading Laravel packages, for Vue.js and Tailwind.

A human touch is still needed 🤖

While Laravel Shift is a formidable tool, and one we’re now completely sold on, it doesn’t negate the need for developer input and review.

Review code changes & pull requests

Always review the pull request provided by Laravel Shift. Your developers need to understand the changes that have been made and ensure they align with your application’s specific needs.

Don’t forget, Shift doesn’t grasp your application’s context or wider requirements and expectations.

Thorough testing

Post-upgrade, your developers have to conduct rigorous tests. While Laravel Shift addresses the Laravel upgrade itself, it’s essential to ensure that your application’s unique features and functionalities remain operational after the upgrade and changes have been made.

Our summary

Ascend’s mantra is to “work smarter, not harder”. Tools like Laravel Shift embody this ethos.

By automating the tedious and involved process we were otherwise faced with — of manual upgrades going back many versions — Laravel Shift offered our developers a smoother, more efficient path to realising our client’s goal of getting their software up-to-date.

One thing we did take away from this though is that it’s essential to support and partner this automation with diligent reviews and testing, ensuring the applications themselves continued to function flawlessly.

--

--

Ascend
Ascend

Written by Ascend

We're Ascend - a digital transformation agency - and in just a few short years we have defied expectations and are emerging as a true leader in our sector.