Version untracked files with PhpStorm

Another very handy use for PhpStorm's Local History feature

Joel Clermont
Joel Clermont
2023-11-16

I've talked about PHPStorm's local history feature before, and how useful it can be.

Recently, I bumped into another use case where it helped me out: untracked files in your git repository.

For example, I was working on a project hosted with Laravel Vapor, and there's a command to both push and pull environment variables for a specific Vapor environment. These files are ignored in the Git repository to prevent committing secrets.

But I wanted to see what had changed since the last time I pulled down the environment variables. I can't use git for this because the files are ignored, and therefore un-versioned.

Here again, PHPStorm local history comes to the rescue! It even differentiates between changes I make in the editor, and changes made by an "external tool", like the vapor env:pull command.

Here to help,

Joel

P.S. Keeping a security-focused mindset is important when developing a Laravel application. Download our free book 7 Steps to Securing Your Laravel App.

Toss a coin in the jar if you found this helpful.
Want a tip like this in your inbox every weekday? Sign up below 👇🏼

Level up your Laravel skills!

Each 2-minute email has real-world advice you can use.