Zen Cart Logo
Forums / General Questions / Developers' Tool Kit: Why does it limit root-directory files?

Developers' Tool Kit: Why does it limit root-directory files?

Views: 945

Results 1 to 4 of 4
21 Feb 2015, 2:47 PM
#1
lat9 avatar

lat9

Administrator

Join Date:
Sep 2009
Location:
Stuart, FL
Posts:
14,065
Plugin Contributions:
56

Developers' Tool Kit: Why does it limit root-directory files?

After spending about an hour yesterday trying to find the .php module that included a particular text string using the Developers' Tool Kit, I finally located that file going through the store's file-system by hand.

The file was part of an update I'd provided to the store, present in the store's root directory. Looking through the DTK code, the only .php files that are included in an "all-file" search in the root directory are those provided by the Zen Cart distribution itself.

Is there a reason for this? It seems like limiting that search somewhat cripples the DTK.

21 Feb 2015, 6:32 PM
#2
rodg avatar

rodg

Deceased

Join Date:
Jan 2007
Location:
Australia
Posts:
6,263
Plugin Contributions:
4

Re: Developers' Tool Kit: Why does it limit root-directory files?

lat9:

Is there a reason for this? It seems like limiting that search somewhat cripples the DTK.

Good question, but this limiting isn't one that really bothers me much. Although I do use the DTK at times I find it rather impractical for the reasons I use it. I tend to use the search functions in my IDE far more than the DTK 'cos when it finds what I'm looking for the file(s) are ready for any edits.

Until now I wasn't even aware this limitation existed, which probably goes some way to explaining why I don't use it much. :)

Cheers
RodG

22 Feb 2015, 4:44 AM
#3
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
177

Re: Developers' Tool Kit: Why does it limit root-directory files?

I believe the limitation was in order to prevent endless (or out-of-control due to massive size) loops through files that could be completely unpredictable. And ostensibly therefore also protect from a security perspective.

I can see the value of using a server-side tool like DTK instead of an IDE ... such as when working on a client site, especially before a copy of their filesystem is made (or is even deemed necessary).
I suppose another enhancement could be yet-another-switch to allow for out-of-control-boundless search on everything under the sun, use-at-own-risk mode. Not real fond of putting that kind of control in a novice storeowners' hands though.

22 Feb 2015, 5:31 PM
#4
rodg avatar

rodg

Deceased

Join Date:
Jan 2007
Location:
Australia
Posts:
6,263
Plugin Contributions:
4

Re: Developers' Tool Kit: Why does it limit root-directory files?

DrByte:

I can see the value of using a server-side tool like DTK instead of an IDE ... such as when working on a client site,

Aye. And this is where I tend to use it most.

DrByte:

especially before a copy of their filesystem is made (or is even deemed necessary).

As for deeming it necessary, when possible I always make a full backup of any site before working on it, even if what I need to do is quite minor. (OK, sometimes I'll only backup only the folders I know I'll be working on), but I never ever leave myself in a position where I can't restore things to the state they were before starting on it.

DrByte:

I suppose another enhancement could be yet-another-switch to allow for out-of-control-boundless search on everything under the sun, use-at-own-risk mode. Not real fond of putting that kind of control in a novice storeowners' hands though.

I can relate to that :)

Cheers
RodG
PS. Thanks for the reasoning behind this limitation, even though I wasn't actually aware of it, it does explain why sometimes it didn't find the things I was searching for.