Viewing 15 replies - 1 through 15 (of 16 total)
  • Plugin Author Andy Fragen

    (@afragen)

    Clifford,

    Thanks for the video. I’m not certain that search as you did in the Finder will identify hidden files/folders.

    In the Finder use the Command-Shift-. command to toggle the view for hidden files/folders. Please let me know what you find.

    Andy

    Plugin Author Andy Fragen

    (@afragen)

    Also, plugins/themes that have a vcs directory are not saved anywhere. They are determined at runtime and passed in the Init class constructor to the other class constructors.

    Thread Starter Clifford Paulick

    (@cliffpaulick)

    PhpStorm and Finder both show hidden files on my system. Really flabbergasted about why this is happening. It’s like it’s cached but like you said it’s not. So weird.

    Here’s a GIF showing no .git in the plugin folder even though appearing as such: https://share.getcloudapp.com/X6uoey0e

    Plugin Author Andy Fragen

    (@afragen)

    Is there a mu-plugin or something else that is loading the plugins in the _temp-git directory?

    Thread Starter Clifford Paulick

    (@cliffpaulick)

    Nope. And even removing that directory out of WP has the same result.

    Obviously you haven’t had report of this before so I will dig further myself. No worries. I’ll report back if/when I find out.

    Thanks, mate!

    Plugin Author Andy Fragen

    (@afragen)

    No I haven’t had this report before. I’m trying to re-create locally but I don’t seem to be able to. I did find another error to fix though ??

    Can you step through the code in Init::get_vcs_checkouts() and see if you can figure it out from there?

    https://github.com/afragen/local-development/blob/develop/src/Local_Development/Init.php#L55-L76

    • This reply was modified 4 years, 8 months ago by Andy Fragen.
    Thread Starter Clifford Paulick

    (@cliffpaulick)

    7min video without success but maybe your more familiar eyes will see something of importance: https://share.getcloudapp.com/mXuArE4y

    Plugin Author Andy Fragen

    (@afragen)

    Thanks Clifford.

    The -1 is the when the plugin is under VCS and the checkmark automatically appears and is not modifiable.

    What I’m really curious about are the valued from the following line.

    https://github.com/afragen/local-development/blob/3dcd6524f4339843890dbcbfd3c92677fa1bb8c1/src/Local_Development/Init.php#L66

    When that line and $is_vcs evaluates to true the saved value in $config will be -1, if false it won’t be in the $config unless it was checked in the Settings prefs. It is worthwhile to see what the value of $config is passed to the function.

    The question I have is why does this seem to evaluate to true on your system? It should only evaluate to true if there is a VCS directory in the specific plugin’s root directory.

    Keep the videos coming. They are helpful.

    Plugin Author Andy Fragen

    (@afragen)

    There is no entry in $config for non-VCS plugins/themes.

    Thread Starter Clifford Paulick

    (@cliffpaulick)

    Thanks for sticking with me on this.

    I figured it out: the Settings correctly got saved with Event Tickets, for example, as a -1 (has VCS), then I replaced the Event Tickets folder in-place where it is the final release/zip version, no longer the VCS version. And the Local Development plugin had already saved its site options so just keeps returning its value.

    Therefore, I’d recommend updating the code to use a transient or otherwise only store the manual checkboxes not the detected checkboxes.

    6min demo: https://share.getcloudapp.com/z8u8Oxq4

    Plugin Author Andy Fragen

    (@afragen)

    Well, I’m glad it’s sorted out. Only the manually checked options are saved, not the VCS checks. It seems from the video that something cleared after you check the additional plugin to test and saved the settings.

    I wonder if previously there was something saved that didn’t clear when upon exchanged a VCS for a non-VCS folder or vice versa. There isn’t a way in the code to store the VCS data.

    Thread Starter Clifford Paulick

    (@cliffpaulick)

    OK, maybe I checked them in the past at a time I had swapped out VCS with non. Thanks again for working through this with me. Really appreciate you!

    Plugin Author Andy Fragen

    (@afragen)

    Anytime Clifford. I appreciate all the Modern Tribe peeps. ??

    Thread Starter Clifford Paulick

    (@cliffpaulick)

    ?? likewise

    Plugin Author Andy Fragen

    (@afragen)

    @cliffpaulick I just added a function in the develop branch that should remove any options that haven’t been manually checked. Hopefully this will solve the issue you had just by re-saving Settings.

Viewing 15 replies - 1 through 15 (of 16 total)
  • The topic ‘incorrectly detecting some plugins as Local Development’ is closed to new replies.