NiklasGollenstede / re-style

A user style manager for Firefox 57+ which can load local files and apply UI styles
https://addons.mozilla.org/addon/re-style/
Mozilla Public License 2.0
38 stars 4 forks source link

Messenging client and extension not talking to each other #4

Closed GreenWoodie closed 6 years ago

GreenWoodie commented 7 years ago

Can I suggest you add something to the extension? I use other extensions that use (different) messaging clients and each of those has a test button. It easily and quickly flags if the extension has a problem talking to the client.

As it happens the client for this extension fails to install on my Windows 10, Nightly v59.0a setup. It looks like some kind of bin folder gets installed in the client directory as a folder junction going nowhere. Anyway the two ain't talking.

I am thinking synchronizing browser extensions with messaging clients is not going to be easy. I have four different messaging clients registered for Firefox so far. That's four extensions I have to install then install a client (or is it the other way around, nobody is actually saying?) In this case I wasn't even aware that the extension needed a client until after I had installed it. So it goes.

It all generates a whole lot of traffic for GitHub though.

NiklasGollenstede commented 7 years ago

Can I suggest you add something to the extension? I use other extensions that use (different) messaging clients and each of those has a test button. It easily and quickly flags if the extension has a problem talking to the client.

Jeah, I know the current setup guide isn't very user-friendly. A test button would be one way to optimize it. I simply didn't have the time to do it yet, but I think it'll be the next thing I'll work on.

bin folder gets installed in the client directory as a folder junction going nowhere

That shouldn't happen. The installation should only symlink (create a NTFS junction) when installed from sources. Did you use the native-ext-v0.2.1-win-x64.exe installer and is your main Windows drive called C:\?

GreenWoodie commented 7 years ago

Thanks for your response.

I doubled checked and I am using native-ext-v0.2.1-win-x64.exe to install the client. It definaly creates bin as an NTFS junction. reports installation sucsessfull. and the command console shows a message saying Now allowing 0 Chrome extensions and 0 Firefox add-ons

native-ext-v0.2.1-win-x64.exe
MD5: 36c3f3c5fdda8d2158980fa082822e00
GreenWoodie commented 7 years ago

Opps Sorry, wrong button

NiklasGollenstede commented 7 years ago

The checksum matches mine (which works fine on Win10 x64).

I'll try to track this down as soon as I find the time. For now, I can only suggest you install from sources (which the installer seems to think it is doing anyway):

Now you actually should have that symlink called bin pointing at the downloaded folder (which you can't delete).

SavageCore commented 7 years ago

My symlink points to C:\snapshot\native-ext\ which does not exist

Succesfully installed native-ext from source though. Win 10 x64

$ npm -v 5.4.2

$ node -v v8.7.0

Let me know how I can help debug

NiklasGollenstede commented 6 years ago

Ok. I think actually debugging this would be very hard, because it works just fine on my systems. I know where things go wrong, I just don't get why. I'll need to update native-ext to use a completely different mechanism to distinguish between normal and from-source installations. Hopefully I find the time to do that soon.

NiklasGollenstede commented 6 years ago

I've packed a new version with a different detection mechanism. It would be great if one of you could test if that works:

native-ext-v0.2.2b1-win-x64.exe.zip

GreenWoodie commented 6 years ago

I downloaded the zip file and installed the client successfully. I did have to manually uninstall the client first, the uninstall script failed but that's not a big problem. There is no longer a symbolic bin folder, now there is a bin executable,

I still can't get re-style to work, This is because I'm not really sure how you are supposed to load a style rather than a programmatic problem.

So, as far as I can tell, the new installation of the client worked. Now all I have to do is figure out what to do with the extension.

GreenWoodie commented 6 years ago

OK I have re-Style working. The interface is a little clumsy and takes a while to figure out.

I seemed to have to restart Firefox a couple of times before it found my local styles. I don't really know how to point to a remote style yet.

I usually get a message saying I have to restart because there has been a change, right after I have restarted to implement a change.

Enable and Disable individual styles doesn't always work for some reason. It's easier just to remove or add a the .css file from the re-Style local folder.

The style editor within the Firefox Browser Toolbox is a little gem, with Real-time updates.

**Sorry if this is not the forum for a re-Style discussion. It does seem the message client works.

NiklasGollenstede commented 6 years ago

I downloaded the zip file and installed the client successfully. [...] There is no longer a symbolic bin folder, now there is a bin executable,

Thanks for verifying that. I'll publish a (non beta) version with the fix soon.

The interface is a little clumsy and takes a while to figure out.

Yeah, I already added a few additional hints for new users and improved the error messages when NativeExt is not installed properly.

I usually get a message saying I have to restart because there has been a change, right after I have restarted to implement a change.

That generally shouldn't happen, but ...

Enable and Disable individual styles doesn't always work for some reason.

Local styles are always enabled on restart. Now it says that next to the button. This is probably also the reason for the repeated restart prompt.

It's easier just to remove or add a the .css file from the re-Style local folder.

Either that or you can add it to the Exclude files RegExp in the options.

The style editor within the Firefox Browser Toolbox is a little gem, with Real-time updates.

Glad you got it working even though most of the instructions are still missing. Just as a not here: reStyle can only map your changes back to the local files if you edit the rules within a @-moz-document block. Changing the include patterns, rearranging the block or adding and removing blocks won't be recognized.

Sorry if this is not the forum for a re-Style discussion. It does seem the message client works.

I'll close this issue then, but we can continue talking here. I don't have a better place for it. Do you have any more questions or suggestions?