User-Style-Manager
User-Style-Manager copied to clipboard
Support Sync through in-built sync engine of Firefox (Weave) by adding another engine for Styles
Syncronize local changes.
For example: If you install an style from Userstyles.org called "Better Scrollbar", but you don't like the color that this style gives to the scrollbar and you modify it, that change will not be synchronized. Would be greatly appreciated if you can add a way to syncronize your custom styles without needing to upload them to Userstyles.org, something like Stylish Sync does.
Many thanks for your time and for your efforts!
- In content is not default. When it will be I will support it.
- Will fix.
- I use Firefox's Sync, so I cannot really control it Even though I try to make it fast, it is still dependent on your Network speed.
- This is not even possible with Stylish Sync, because for this, we would require to host the whole content of the file on a server. Maybe I will provide this feature using a Pro Plan (paid) and use my own server to sync the files. That way, I could sync even the local files that you created yourself. UPDATE: It is possible.
- It does.
- Again, it is not possible to know when the other computer has received the synced files. Firefox does not provides this feature.
Thanks for your concern, But I already know the whole source code of Stylish Sync :) I have reviewed it a couple of times.
When I was using Stylish with the Stylish Sync addon, every change that I do to an style was synced. I also noticed that Stylish Sync adds an user styles quota. That's what I'm saying, the way that USM sync styles is different to the way that Stylish Sync does it.
If I create a new style under Stylish Sync, it's automatically synced, and if I do the same under USM, the styles that I create will not be synced.
Let me look into it. Btw, how much is this quota ?
Stylish Sync Settings: http://www.dropmocks.com/iBlle4 Stylish Sync Quota: http://www.dropmocks.com/iBlW7h
Stylish stores all the styles into an .sqlite file, so I think that is the principal difference.
The total Stylish Sync quota is around 425kb, but I have installed 10 styles and they are too large, because I use a CSS editor (here Stylish) to modify the Firefox interface, and into that 10 styles is the browser.css Firefox stylesheet file.
Okay, now I have the idea. Lets change the bug name to represent what it should do.
Many thanks!
Do you want I open the first issue (%20) on a new issue?
I already fixed that :)
When you check the "Sync Immediately" option and then you close and reopen the Manage window, the option appears unchecked.
I don't know if now this is intended, but I can't see the "User Styles" item quota and syncing is not working, at least for me. I want to show you a bug that I saw when I was testing this: http://www.dropmocks.com/iBmLjg The first sync labels appears to dont't work sometimes. This is always tested on a clean Firefox instalation using the Nightly channel.
I have a big commit tha ti have not pushed. I know its not working right now, syncing is fine, USM is not adopting to data. will let you know by closing this issue
Ok, thanks.
It's really incredible how you are converting this addon in something that doesn't have words to describe it, i'm really grateful. But (sorry, i can't stop asking you for every thing i think it's irregular, at least for me) i can't get the first sync bar disapear by clicking on any button (merge, wipe, disable) under Firefox 17.0b3 in a clean installation.
Thanks
Shit, I didn't mean to close it by that commit message ..
Anyways, the notification bar is not closing for you, even if you click the close button, or any button any number of times ?
If you click on the close button it closes, but clicking on any other button doesn't make it disappear. Sync appears to work normally because i have all my styles synced, even if i don't select any option.
EDITED: Cliking all buttons (except the close button) any number of times doesn't close the bar.
Oh, atleast Sync is working fine. I still need to do more testing to confirm and close this bug. Sync will work as I have a timeout of 60 seconds, if no button is clicked until then, the notification box should automatically close, chosing the merge option as default.
That looks great. I think also would be useful if you can implement the "User Style" checkbox even before you setup sync, something like Stylish Sync does: http://www.dropmocks.com/iBmYw1. It's a little detail, but it let you choose if you want to sync styles before starting sync.
Can you check now if the notification box closes properly ?
Great, now it closes! A little detail (no a problem), is that the bar opens using a slide effect that's not applied when closing. That's just an estetical detail.
Many thanks for giving this addon an "off road" sync! :)
I want to tell you some "break points" of actual sync:
- When you unselect the "Sync styles" pref it should clear the sync quota, like other Sync elements (Addons, Preferences, Bookmarks, etc.)
- When unselecting the "Sync Styles" pref, the "Sync Immediately" option should also be unchecked.
- I can't explain it better now, but if you use two diferent Firefox profiles and in one of them you delete an style, in the other profile that style appears duplicated.
- The "Keep deleted styles" preference should be removed, because if you want to keep your styles deleted you can choose that option at first sync (Merge, Wipe, Disable). For me, this is causing the duplicated styles and also that when deleting styles the Sync Quota increases instead of decreasing.
Would be more simple and non-confusive for users that you can give only two options:
- Sync Styles (with a tooltip saying "Unchecking this preference will clear the server quota") and
- Sync Immediately
Thanks
- I think the quota clearing part is managed by Mozilla itself. As there might be other computers still connected to the server.
- They should get disabled, not unchecked.
- Yeah, I should improve the keep deleted setting, so that atleast it does not create double.
- It should be disabled by default for sure. I am not sure about deleted yet..
Here you have some images to describe the duplicated files better:
This is the normal USM styles that i have on my default profile: http://www.dropmocks.com/iBmZST And this happens when I use sync in other profile: http://www.dropmocks.com/iBmJAL
Like you can see, there are many styles duplicated. The problem appears to be that the styles i remove from USM are not removed in the server and, when i use sync, it downloads all the styles located in the server to the Firefox profile. Also, if you see the duplicated styles date, in some cases they are older and newer versions of the same style.
Can you test a little now. Beware, since there are .jsm file changes, you will require a browser restart after installing this instance of USM
I can't get the User Styles quota to 0 bytes. I have created a new sync account, bacause maybe my account was corrupted, but it's the same. I start creating one style (we're going to call it "style 1"), at this point all it's ok (the style is synced to the other profile also). I create one more style (called "style 2"), but now, this style is synced and in the other profile the style 1 was removed. If i remove all the styles in both profiles the sync quota gets freezed in 374 bytes when it should be 0 bytes.
Have you tried a clean install, with deleting everything, resetting all engine.userStyles pref, deleting the user styles folder, and on the first run, choosing Wipe Server option ?
On Tue, Nov 6, 2012 at 5:47 AM, Alopepeo [email protected] wrote:
I can't get the User Styles quota to 0 bytes. I have created a new sync account, bacause maybe my account was corrupted, but it's the same. I start creating one style (we're going to call it "style 1"), at this point all it's ok (the style is synced to the other profile also). I create one more style (called "style 2"), but now, this style is synced and in the other profile the style 1 was removed. If i remove all the styles in both profiles the sync quota gets freezed in 374 bytes when it should be 0 bytes.
— Reply to this email directly or view it on GitHubhttps://github.com/scrapmac/User-Style-Manager/issues/85#issuecomment-10094263.
Girish Sharma B.Tech(H), Civil Engineering, Indian Institute of Technology, Kharagpur
Now, yes. I was always testing with a clean install, but no the other things. Now, i did all of that and the quota doesn't decreases from 374 bytes.
Weird. When I do Wipe Server, Quota becomes 0 bytes.
On Tue, Nov 6, 2012 at 5:28 PM, Alopepeo [email protected] wrote:
Now, yes. I was always testing with a clean install, but no the other things. Now, i did all of that af the quota doesn't decreases from 374 bytes.
— Reply to this email directly or view it on GitHubhttps://github.com/scrapmac/User-Style-Manager/issues/85#issuecomment-10108014.
Girish Sharma B.Tech(H), Civil Engineering, Indian Institute of Technology, Kharagpur
I'm getting no positive results. If you see, under Stylish Sync you can clear the sync quota when the "Enabled" checkbox is disabled in the merge and in all modes: http://www.dropmocks.com/iBmpWP. I'm stuck in the first bug that i told you, because if i sync one style all is ok, but creating one more style in any of the profiles deletes the previous style that i synced. The idea is:
- You create a new style, so this style is synced and the sync quota increases (it should be in all modes, except disabling)
- You delete an style and this style would be also removed from the server so the quota decreases.
You are not getting the point, you have 5 synced devices, you disable the add-on on one device, now do you want your synced styles on the server to get deleted ?
The 2 points that you are requesting are already happening ..
No, if you disable the addon, the server should keep their styles and i think this is working fine. Sorry, you're right. I'm going to give you a more clear idea:
How does sync should work?
Merge:
- Creating a style from any device should add it to all other devices.
- Deleting a style from any device should remove it from all other devices.
Wipe Server:
- The styles from the server should be replaced with the styles from an specific profile.
Wipe Styles:
- The styles from an specific profile should be replaced with the styles from the server.
Now, what's the problem?
Problem 1: Steps:
- Create two Firefox profiles (with synchronization enabled) and install USM in both profiles.
- Create an style in one of them and sync it. It should also appear in the other Firefox profile.
- Create on more style and sync it. In the other profile, the style that was previously synced disappears.
Problem 2 I can't tell you the specific steps to reproduce this bug, but many times the styles appears duplicated and that's because i said you the problem with sync quota. I'm thinking that, as USM can't manage the server quota more precisely, that is causing the problem. Another posible reason is that i was testing sync with the "Delete Hard Disk styles" option disabled, so USM was also syncing the styles from the "User Styles" folder. I've tried it with the preference enabled and, for now, there's no change.
NOTE: I've tested the wipe mode, but i'm doing a more intensive test under the merge mode because it is used for more people.
Conclusion: I don't want to give you more problems and i know you want to finish this feature as soon as possible, but there are important problems that have to be solved before finishing. Maybe my English is causing understanding problems, but i'll do everything i can.
Thanks for your patience.