Michiel
Michiel

Reputation: 709

Delete unused files and folders in an existing project

I recently started working on this php project that had some previous developers.
These dev's made a bit of a mess of things, resulting in a huge amount of different files, in PHP as well as javascript files and stylesheets.
I'd like to reduce the amount of files and folders, since they're now over 17k and 5.4k respectively.

Is there a way I could flag unused files for deletion?
Perhaps while navigating the site, e.g. whitelisting files that are being used?

Any help would be greatly appreciated!

Upvotes: 4

Views: 623

Answers (1)

Zgr3doo
Zgr3doo

Reputation: 1855

I think sometimes its quicker to write things from scratch rather than work with "Megamoth" but if you need to keep it running you probably need to put it into some kind of version control system.

I recommend Git

http://en.wikipedia.org/wiki/Git_%28software%29

https://git-scm.com/

and just start refractoring it.

Version control system will keep your old code so you will be sure that you don't loose anything while deleting or changing your code and you will be able to jump from one version to another very quickly.

Upvotes: 1

Related Questions